Avoiding import loops in Python

Fix import errors using these tricks.

Ever run into an error about a partially initialized module likely due to a circular import? Then this Python video is for you!

― mCoding with James Murphy (https://mcoding.io)

Source code: https://github.com/mCodingLLC/VideosSampleCode

SUPPORT ME ⭐
—————————————————
Patreon: https://patreon.com/mCoding
Paypal: https://www.paypal.com/donate/?hosted_button_id=VJY5SLZ8BJHEE
Other donations: https://mcoding.io/donate

Top patrons and donors: Jameson, Laura M, Dragos C, Vahnekie, John Martin, Casey G, Pieter G, Krisztian M, Mutual Information, Sigmanificient

BE ACTIVE IN MY COMMUNITY
—————————————————
Discord: https://discord.gg/Ye9yJtZQuN
Github: https://github.com/mCodingLLC/
Reddit: https://www.reddit.com/r/mCoding/
Facebook: https://www.facebook.com/james.mcoding

CHAPTERS
—————————————————
0:00 Intro
0:26 Call-time dependencies
3:32 Type-hints
5:28 Subpackage init cycle
8:45 True import-time cycles

Source: https://www.youtube.com/watch?v=UnKa_t-M_kM

Leave a Reply

Your email address will not be published. Required fields are marked *