"Fred L. Drake, Jr." wrote: > > Neal Norwitz writes: > > mimetypes.py:405: No global (sys) found > > > > This is inside usage() which presumably should only be used internally. > > sys is imported if __name__ == '__main__'. > > So the problem can only be triggered if usage() is called > > by external source. > > > > Possible fixes are: > > sys could be locally imported in usage() > > sys could be imported at the module scope > > usage could be made _usage() to denote it's private > > I'll propose another fix, but I don't know what pychecker would > say. ;-) I'd like to move the definition of usage() into the if > __name__ == "__main__" block, in which case the problem goes away > since there wouldn't be a usage() unless sys has been imported. > I'll check it in that way. ;-) I like your fix better than my suggestions. :-) I thought pychecker would complain, but it's happy too. :-) Neal
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4