On Sat, Apr 18, 2020 at 05:57:44PM +0200, Christoph Zwerschke wrote: > Am 18.04.2020 um 17:23 schrieb Justin Pryzby: > > That didn't work. > > > > It did work to do this: > > ProgrammingError = _pg.ProgrammingError > > > > Maybe __all__ can *limits* what's visible but not extend it. ? > > If pylint still complains, then it is a pylint issue. The message "No name > ProgrammingError in module pg" is definitely wrong - it looks like pylint > cannnot interpret the "from _pg import *" statement, maybe because it cannot > process C extensions.
It works fine when I use import _pg, which is what I started doing at telsasoft before raising this issue, and what I'll plan to continue. > You can also try using flake8 instead of pylint, they have both their pro's > and con's. The pep8 style portion of flake8 is so naggy as to be useless to me. Pyflakes seems to do very little else. So far, all I could get from it was a couple rounds of cleaning unused imports. -- Justin _______________________________________________ PyGreSQL mailing list [email protected] https://mail.vex.net/mailman/listinfo/pygresql
