An unhandled exception occured, when passing bogus input to bst
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 42/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- python
- Domain
- build-system
Research direction
Start with buildstream/scriptelement.py at configure_sandbox() and buildstream/sandbox/sandbox.py at set_work_directory(), following how the relative cwd from the element configuration reaches the assertion. Done when bogus input produces a clear user-facing error instead of an unhandled exception, with regression coverage for this case.
Written by the indexing model from the issue text.
Description
See elements is not an absolute path
# File generated by convert.py
build-depends:
- freedesktop-sdk.bst:components/gtk3.bst
depends: []
sources: []
kind: script
config:
commands:
- install -m755 install-licenses.sh /usr/bin
variables:
cwd: elements
Error message:
[00:00:00][7aac01d5][ build:licence-extractor.bst ] BUG Build
An unhandled exception occured:
Traceback (most recent call last):
File "/usr/lib64/python3.13/site-packages/buildstream/_scheduler/jobs/job.py", line 350, in child_action result = self.child_process() # pylint: disable=assignment-from-no-return
File "/usr/lib64/python3.13/site-packages/buildstream/_scheduler/jobs/elementjob.py", line 81, in child_process return self._action_cb(self._element)
~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^
File "/usr/lib64/python3.13/site-packages/buildstream/_scheduler/queues/buildqueue.py", line 55, in _assemble_element element._assemble()
~~~~~~~~~~~~~~~~~^^
File "/usr/lib64/python3.13/site-packages/buildstream/element.py", line 1695, in _assemble
self.__configure_sandbox(sandbox)
~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^ File "/usr/lib64/python3.13/site-packages/buildstream/element.py", line 2681, in __configure_sandbox
self.configure_sandbox(sandbox) ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^
File "/usr/lib64/python3.13/site-packages/buildstream/scriptelement.py", line 200, in configure_sandbox
sandbox.set_work_directory(self.__cwd)
~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^
File "/usr/lib64/python3.13/site-packages/buildstream/sandbox/sandbox.py", line 149, in set_work_directory
assert directory.startswith("/"), "The working directory must be an absolute path"
~~~~~~~~~~~~~~~~~~~~^^^^^
AssertionError: The working directory must be an absolute path
One would expect only an error message (or alternatively making the path absolute relative to where bst is run from or where project.conf is.
- Dominant language
- Python
- Stars
- 151
- Forks
- 49
- Avg merge
- 3d 5h
- Merged PRs (30d)
- 6
Getting set up
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from apache/buildstream
-
logging
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
apache/buildstream#2150 · 3 comments ·
-
question
Difficulty 2/5 1-3 hours Newbie friendliness 64/100
apache/buildstream#2143 · 2 comments · 1 reaction ·
-
Difficulty 3/5 1-2 days Newbie friendliness 74/100
apache/buildstream#2196 ·
-
Difficulty 3/5 1-2 days Newbie friendliness 55/100
apache/buildstream#2194 ·
-
Modification time of an element with an open workspace propagates into consumer element's sandboxOpenbug
Difficulty 3/5 1-2 days Newbie friendliness 58/100
apache/buildstream#2186 · 2 comments · 2 reactions ·
All issues in apache/buildstream
Similar issues
-
Difficulty 1/5 Under an hour Newbie friendliness 91/100
-
Difficulty 1/5 1-3 hours Newbie friendliness 92/100
-
enhancement P2
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Toloka/tolokaforge#1776 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
TencentCloud/Octop#1622 ·
Maintainers usually reply within 1 day
-
arch area:fleet priority:p3 severity:low track:hosted-product
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
Maintainers usually reply within 1 day