https://pantsbuild.org/ logo
#general
Title
# general
a

aloof-angle-91616

04/11/2019, 11:10 PM
re #1 -- we're thinking of adding a lint for exactly that: https://github.com/pantsbuild/pants/issues/7106 (to avoid accidentally importing transitively). i wasn't sure how to write that lint yet but importing objects with
from...import
feels actually more consistent to me, and is a pattern we try to employ in the rust codebase as well, so it's quite consistent across the project and changing that would be a big step i think. it's definitely more injectable and easier to mock, i think, even if most python projects don't tend to use this style [citation needed, i'm not a pythonista yet].