victorhos/merge_requirements

Two incompatible requirements.txt files must produce an error

Opened this issue · 0 comments

Description

Two files can have incompatible requirements: (>= dependency on some version in one and <= in another).
This must produce an error.

Motivation

This is precisely why people specify concrete versions in requirements.txt file.
It will be good if the tool will provide compatibility validation on these direct dependencies.

Reproduce

req1.txt:

more_itertools==8.8.0

req2.txt:

more_itertools==6.0.0

run:

merge_requirements req2.txt req1.txt

Expected result:

Error because of incompatible lists. No file is created.

Actual result:

The bigger version wins. No error.