pybites, to python
@pybites@fosstodon.org avatar

New article:

⚠️Why you should avoid import * in Python 🐍
https://pybit.es/articles/why-you-should-avoid-import-in-python/

Covering:

  • Why modules are great and namespacing explained
  • Why import * is a problem
  • A practical example where a function gets overriden
  • The recommended way to do imports
  • What PEP8 has to say about this
  • Protection workaround, use all to define your module's public interface

  • All
  • Subscribed
  • Moderated
  • Favorites
  • megavids
  • thenastyranch
  • rosin
  • GTA5RPClips
  • osvaldo12
  • love
  • Youngstown
  • slotface
  • khanakhh
  • everett
  • kavyap
  • mdbf
  • DreamBathrooms
  • ngwrru68w68
  • provamag3
  • magazineikmin
  • InstantRegret
  • normalnudes
  • tacticalgear
  • cubers
  • ethstaker
  • modclub
  • cisconetworking
  • Durango
  • anitta
  • Leos
  • tester
  • JUstTest
  • All magazines