@@ -53,10 +53,14 @@ def main():
5353 if line .startswith ("git+" ):
5454 # The single exception...
5555 if "pulp-smash" not in line :
56- errors .append (f"{ filename } :{ nr } : Invalid source requirement: { line } " )
56+ errors .append (
57+ f"{ filename } :{ nr } : Invalid source requirement: { line } "
58+ )
5759 elif line .startswith ("-r " ):
5860 if check_r :
59- errors .append (f"{ filename } :{ nr } : Invalid deferred requirement: { line } " )
61+ errors .append (
62+ f"{ filename } :{ nr } : Invalid deferred requirement: { line } "
63+ )
6064 else :
6165 errors .append (f"{ filename } :{ nr } : Unreadable requirement { line } " )
6266 else :
@@ -66,13 +70,19 @@ def main():
6670 not req .name .startswith ("opentelemetry" )
6771 and req .name != "pulp-python-client"
6872 ):
69- errors .append (f"{ filename } :{ nr } : Prerelease versions found in { line } ." )
73+ errors .append (
74+ f"{ filename } :{ nr } : Prerelease versions found in { line } ."
75+ )
7076 ops = [spec .operator for spec in req .specifier ]
7177 if "~=" in ops :
72- warnings .warn (f"{ filename } :{ nr } : Please avoid using ~= on { req .name } !" )
78+ warnings .warn (
79+ f"{ filename } :{ nr } : Please avoid using ~= on { req .name } !"
80+ )
7381 elif "<" not in ops and "<=" not in ops and "==" not in ops :
7482 if check_upperbound :
75- errors .append (f"{ filename } :{ nr } : Upper bound missing in { line } ." )
83+ errors .append (
84+ f"{ filename } :{ nr } : Upper bound missing in { line } ."
85+ )
7686 except FileNotFoundError :
7787 # skip this test for plugins that don't use this requirements.txt
7888 pass
0 commit comments