• Kirill Smelkov's avatar
    scripts/fsrefs: Fix -v · 29f75cc6
    Kirill Smelkov authored
    For this script verbose mode was added in 57bca1f0 (Add -v option to
    control whether tracebacks are printed.) and was later broken in
    6dd809d2 (Converted to a buildout and converted externals to
    dependencies.) - the change forgot to add global specifier for VERBOSE
    variable while moving its assignment into function context.
    
    As a result currently we have
    
        $ python ./src/ZODB/scripts/fsrefs.py -v data.fs
        Traceback (most recent call last):
          File "./src/ZODB/scripts/fsrefs.py", line 155, in <module>
            main()
          File "./src/ZODB/scripts/fsrefs.py", line 104, in main
            VERBOSE += 1
        UnboundLocalError: local variable 'VERBOSE' referenced before assignment
    
    Fix it.
    29f75cc6
fsrefs.py 5.83 KB