I think I would just do something like this in %prep:
sed -r -i 's/^file:/# &/' tests/requirements.in
Thanks, that did it. Is this something broken in upstream code, or is it our parser that
needs to be adjusted? I couldn't find the relevant pip documentation about
'file:.#egg=' format.