Skip to main content

One decorator to export them __all__ :)

Project description

module-exports

Single decorator that injects __name__ of object to export into __all__.

from module_exports import export_from_module

@export_from_module
def some_public_function():
  return 4

SOME_CONSTANT = 100500

export_from_module.by_name('SOME_CONSTANT')


#  __all__ == ['some_public_function', 'SOME_CONSTANT']

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

module_exports-1.2.tar.gz (1.6 kB view details)

Uploaded Source

File details

Details for the file module_exports-1.2.tar.gz.

File metadata

  • Download URL: module_exports-1.2.tar.gz
  • Upload date:
  • Size: 1.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/39.0.1 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.7.1

File hashes

Hashes for module_exports-1.2.tar.gz
Algorithm Hash digest
SHA256 0e1080d32ac29cf5d68bca74c37991a249bc8c07ee148d8b00f127a8f8a2576b
MD5 31bbe32bb5578396df68bba1058b3b00
BLAKE2b-256 7fb69d946aea93982da21a5217e7bb551ff2300376adcef56646d1944674ad8d

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page