A
A
Artyom Innokentiev2015-10-25 19:28:37
Django
Artyom Innokentiev, 2015-10-25 19:28:37

How to properly import packages in Python?

Let's say we have several modules: foo, bar, spam.
foo uses bar's functions bar
uses foo's classes
spam uses foo's classes and bar's functions
There is a circular import of modules.
What is the correct way to import all modules without conflicts?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question