diff options
author | Chandan Singh <csingh43@bloomberg.net> | 2019-12-30 15:48:21 +0000 |
---|---|---|
committer | Chandan Singh <csingh43@bloomberg.net> | 2019-12-30 15:48:21 +0000 |
commit | 59e8a3c64822b148e5703e475b79a0812cf0b85d (patch) | |
tree | 1ea59200601cb0d08ec9d8bfbd2faeba3f293aa4 /requirements | |
parent | 598ebf33c1ed0c9a191a5e3a671c3f84330bfca2 (diff) | |
download | buildstream-59e8a3c64822b148e5703e475b79a0812cf0b85d.tar.gz |
requirements: Add dependency on ruamel.yaml.clibchandan/dependon-yaml.clib
On Python3.8, when `ruamel.yaml.clib` is not installed, BuildStream ends
up throwing a stack trace on any and all operations. This manifests
itself in the following form:
$ bst show hello.bst
Error loading user configuration:
/venv/lib/python3.8/site-packages/buildstream/data/userconfig.yaml:
Severely malformed YAML:
'NoneType' object is not callable
This is also the root cause of downstream issues like
https://gitlab.com/BuildStream/bst-plugins-container/issues/19.
The fix is simple - to add a hard dependency on `ruamel.yaml.clib`, since
we explicitly import `yaml.Cparser` -
https://gitlab.com/BuildStream/buildstream/blob/master/src/buildstream/_yaml.pyx#L298
- that doesn't come from the main `ruamel.yaml` package.
This works fine on Python < 3.8 because `ruamel.yaml` itself has a hard
dependency on `ruamel.yaml.clib` for those versions. The Python 3.8 CI
pipeline also works because our requirements were frozen using a Python
3.7 interpreter and hence already have this requirement.
Diffstat (limited to 'requirements')
-rw-r--r-- | requirements/requirements.in | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/requirements/requirements.in b/requirements/requirements.in index ce721da33..50bb523da 100644 --- a/requirements/requirements.in +++ b/requirements/requirements.in @@ -5,6 +5,7 @@ pluginbase protobuf >= 3.6 psutil ruamel.yaml >= 0.16 +ruamel.yaml.clib >= 0.1.2 setuptools pyroaring ujson |