Skip to main content

Extend Django with L10N features.

Project description

# Django L10N extensions Django L10N extensions adds some useful L10N extensions to the Django framework

The project in maintained on [github](

[Read the docs](

## Create new distribution To create a new distribution from this package follow these steps: 1) create new virualenv met python 3 mkvirtualenv -p /usr/bin/python3 django-l10n-extensions 2) install requirements pip install -r setup/requirements.txt 3) update the version in ./, otherwise you will overwrite an already existing version. 4) Make a new distribution run: python sdist bdist_wheel 5) Optional upload to pypi TEST: twine upload –repository-url dist/*

to upload to PRODUCTION remove the –repository-url argument (make sure your local ~/.pypirc is correct)

# Date and time in python CONCEPT version

Always work in UTC and use date / datetime aware instances

e.g. python 3 datetime.utcfromtimestamp(0).timestamp() –> -3600 # datetime instance has no timezone and python fallback on OS timezone

datetime.utcnow() is also timezone unaware use datetime.utc(tz=timezone.utc)

datetime.strptime(“1970-0101T00:00:00”, “%Y-%m-%dT%H:%M:%S) is also timezone unaware use datetime.strptime(“1970-0101T00:00:00”, “%Y-%m-%dT%H:%M:%S).replace(tzinfo=timezone.utc)

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

django-l10n-extensions-1.0.7.tar.gz (21.1 kB view hashes)

Uploaded source

Built Distribution

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