`test` command fails with a FileNotFoundError if `spread` is not on `$PATH`
Metadata
Current evaluation
Closed without a documented fix. A bot comment indicates the bug was synced to external Jira ticket CRAFT-4373 for tracking, suggesting the issue was deferred or handled outside GitHub.
Suggested action: —
No scores available.
Issue body
### Bug Description
We should fail better in this case.
### To Reproduce
`testcraft test` without spread installed
### part yaml
```shell
```
### Relevant log output
```shell
2025-03-25 16:37:08.426 Testing project.
2025-03-25 16:37:08.427 Setting up TestingService
2025-03-25 16:37:08.427 Processing spread.yaml.
2025-03-25 16:37:08.436 Emitter: Pausing control of the terminal
2025-03-25 16:37:08.438 Emitter: Resuming control of the terminal
2025-03-25 16:37:08.438 testcraft internal error: FileNotFoundError(2, 'No such file or directory')
2025-03-25 16:37:08.441 Traceback (most recent call last):
2025-03-25 16:37:08.441 File "/home/lengau/Work/Code/craft-application/craft_application/application.py", line 613, in run
2025-03-25 16:37:08.441 return_code = self._run_inner()
2025-03-25 16:37:08.441 ^^^^^^^^^^^^^^^^^
2025-03-25 16:37:08.442 File "/home/lengau/Work/Code/craft-application/craft_application/application.py", line 592, in _run_inner
2025-03-25 16:37:08.442 return_code = dispatcher.run() or os.EX_OK
2025-03-25 16:37:08.442 ^^^^^^^^^^^^^^^^
2025-03-25 16:37:08.442 File "/home/lengau/Work/Code/craft-application/.venv/lib/python3.12/site-packages/craft_cli/dispatcher.py", line 527, in run
2025-03-25 16:37:08.442 return self._loaded_command.run(self._parsed_command_args)
2025-03-25 16:37:08.442 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2025-03-25 16:37:08.442 File "/home/lengau/Work/Code/craft-application/craft_application/commands/base.py", line 199, in run
2025-03-25 16:37:08.442 result = self._run(parsed_args, **kwargs) or result
2025-03-25 16:37:08.442 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2025-03-25 16:37:08.442 File "/home/lengau/Work/Code/craft-application/craft_application/commands/lifecycle.py", line 473, in _run
2025-03-25 16:37:08.442 self._services.testing.run_spread(dest)
2025-03-25 16:37:08.442 File "/home/lengau/Work/Code/craft-application/craft_application/services/testing.py", line 73, in run_spread
2025-03-25 16:37:08.442 subprocess.run(
2025-03-25 16:37:08.442 File "/home/lengau/.local/share/uv/python/cpython-3.12.9-linux-x86_64-gnu/lib/python3.12/subprocess.py", line 550, in run
2025-03-25 16:37:08.442 with Popen(*popenargs, **kwargs) as process:
2025-03-25 16:37:08.442 ^^^^^^^^^^^^^^^^^^^^^^^^^^^
2025-03-25 16:37:08.442 File "/home/lengau/.local/share/uv/python/cpython-3.12.9-linux-x86_64-gnu/lib/python3.12/subprocess.py", line 1028, in __init__
2025-03-25 16:37:08.442 self._execute_child(args, executable, preexec_fn, close_fds,
2025-03-25 16:37:08.442 File "/home/lengau/.local/share/uv/python/cpython-3.12.9-linux-x86_64-gnu/lib/python3.12/subprocess.py", line 1963, in _execute_child
2025-03-25 16:37:08.442 raise child_exception_type(errno_num, err_msg, err_filename)
2025-03-25 16:37:08.442 FileNotFoundError: [Errno 2] No such file or directory: 'spread'
2025-03-25 16:37:08.442 Full execution log: '/home/lengau/.local/state/testcraft/log/testcraft-20250325-163708.235933.log'
Exception ignored in atexit callback: <function move at 0x7ba6ac2c4e00>
Traceback (most recent call last):
File "/home/lengau/.local/share/uv/python/cpython-3.12.9-linux-x86_64-gnu/lib/python3.12/shutil.py", line 867, in move
copy_function(src, real_dst)
File "/home/lengau/.local/share/uv/python/cpython-3.12.9-linux-x86_64-gnu/lib/python3.12/shutil.py", line 475, in copy2
copyfile(src, dst, follow_symlinks=follow_symlinks)
File "/home/lengau/.local/share/uv/python/cpython-3.12.9-linux-x86_64-gnu/lib/python3.12/shutil.py", line 260, in copyfile
with open(src, 'rb') as fsrc:
^^^^^^^^^^^^^^^
FileNotFoundError: [Errno 2] No such file or directory: '/home/lengau/Work/Code/craft-application/.craft-spread.yaml'
```
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| qwen/qwen3.6-35b-a3b | — | — | Closed without a documented fix. A bot comment indicates the bug was synced to external Jira ticket CRAFT-4373 for tracking, suggesting the issue was deferred or handled outside GitHub. | |
| qwen/qwen3.6-35b-a3b | — | — | Closed without a specified resolution, likely abandoned. The issue reported a FileNotFoundError when the test command runs without spread installed, but the thread only contains an auto-generated Jira sync comment with no fix or further updates. | |
| qwen/qwen3.6-35b-a3b | — | — | Closed after syncing to internal Jira ticket CRAFT-4373. No public fix or pull request was merged. The missing spread error handling remains unaddressed. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Closed without a linked pull request or explicit resolution. The bug reports a FileNotFoundError when spread is missing from PATH. An internal Jira ticket (CRAFT-4373) was created for tracking. |
Update history
No update history recorded yet.
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #703 Bad error message if 'spread.yaml' is missing | craft-application | closed | Closed without resolution. A missing spread.yaml caused an internal error during crafttool test. No fix was implemented or merged. The ticket was closed after a Jira sync comment, indicating it was abandoned. |