You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
rp flash deploy fails when requirements.txt has an inline comment #721
A requirements.txt line with an inline comment, such as requests==2.32.3 # http client, makes rp flash deploy fail during dependency vendoring. The error ends with a hint about packages without Linux wheels, which does not apply to requests. pip itself accepts the same file with pip install -r requirements.txt.
To Reproduce
In a Flash project, create requirements.txt containing:
requests==2.32.3 # http client
Run rp flash deploy --build-only:
Error: dependency vendoring failed:
ERROR: Invalid requirement: 'requests==2.32.3 # http client': Expected comma (within version specifier), semicolon (after version specifier) or end
requests==2.32.3 # http client
~~~~~~~~~~^
packages without linux wheels cannot be vendored; exclude them (they must then come from the image)
In addition, a -r extra.txt line is skipped without a warning. With requirements.txt containing requests==2.32.3 and -r extra.txt, and extra.txt containing numpy==2.1.3, the build succeeds, but numpy is not in the built artifact.
Expected behavior
Inline comments are ignored, as pip ignores them, and the deploy vendors requests==2.32.3.
A -r line is either followed, or the deploy stops with an error that names the line it does not support.
Activity