snapcraft-parser crashes when the origin-type is wrong
Metadata
Current evaluation
⚠️ This summary may be outdated — the issue content or evaluation prompts have changed since this evaluation was made.
Closed without comments or resolution. The parser crashed with a CalledProcessError when origin-type was incorrectly set to git for a local directory. Issue appears abandoned or fixed upstream.
Suggested action: —
No scores available.
Issue body
snapcraft-parser crashes when the origin-type is wrong. For example, using a simple directory as a git origin.
To reproduce, write this to index.txt
---
description: test
maintainer: test
parts: [test]
origin: /tmp/test
origin-type: git
$ snapcraft-parser -i index.txt -o out
Processing origin '/tmp/test'
fatal: '/tmp/test' does not appear to be a git repository
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
Traceback (most recent call last):
File "/usr/bin/snapcraft-parser", line 29, in <module>
wiki_errors = snapcraft.internal.parser.main()
File "/usr/lib/python3/dist-packages/snapcraft/internal/parser.py", line 94, in main
return run(args)
File "/usr/lib/python3/dist-packages/snapcraft/internal/parser.py", line 352, in run
data = _process_index(output)
File "/usr/lib/python3/dist-packages/snapcraft/internal/parser.py", line 320, in _process_index
pending_validation_entries)
File "/usr/lib/python3/dist-packages/snapcraft/internal/parser.py", line 284, in _try_process_entry
pending_validation_entries)
File "/usr/lib/python3/dist-packages/snapcraft/internal/parser.py", line 261, in _process_wiki_entry
parts_list, after_parts = _process_entry(data)
File "/usr/lib/python3/dist-packages/snapcraft/internal/parser.py", line 214, in _process_entry
handler.pull()
File "/usr/lib/python3/dist-packages/snapcraft/internal/sources/_git.py", line 76, in pull
self._pull_existing()
File "/usr/lib/python3/dist-packages/snapcraft/internal/sources/_git.py", line 55, in _pull_existing
self.source, refspec])
File "/usr/lib/python3.5/subprocess.py", line 581, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['git', '-C', '/home/elopio/.cache/snapcraft-parser/tmptest', 'pull', '--recurse-submodules=yes', '/tmp/test', 'HEAD']' returned non-zero exit status 1
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| qwen/qwen3.6-35b-a3b | — | — | Closed without comments or resolution. The parser crashed with a CalledProcessError when origin-type was incorrectly set to git for a local directory. Issue appears abandoned or fixed upstream. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Closed without resolution. Reported a crash when origin-type was set to git for a local directory, causing a subprocess error. No fix or merge details were provided. |
Update history
No update history recorded yet.
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #1606346 snapcraft-parser without git installed throw bad error | snapcraft (launchpad) | closed | Closed without resolution. The unhandled OSError when git is missing was not addressed, and the request for graceful dependency validation was abandoned due to prolonged inactivity. | |
| #1605541 snapcraft-parser doesn't work | snapcraft (launchpad) | closed | Closed as a regression without resolution. snapcraft-parser 2.13 failed to parse multi-document YAML streams, causing a parser error. The issue was abandoned with no fix or follow-up. | |
| #1744686 snapcraft local source is not a directory | snapcraft (launchpad) | closed | Closed without resolution or comments. Premature validation of local source directories blocking inter-plugin dependencies remains unresolved. |