Skip to main content

django-datetime-helpers

Build Status codecov PyPI version License: MIT

Frequently used functions and constants about datetime in Django projects

Installing

pip install django-datetime-helpers

Examples

# Quering all Users who join today
users = User.objects.filter(
    created_at__date=today()
)

# Quering all Users who join in last 12 hours
users = User.objects.filter(
    created_at__gte=secons_ago(12 * HOUR)
)

# Declaring constanst
USER_SOMETHING_TIMEOUT = 5 * MINUTE

# Waiting for something
time.sleep(MINUTE)

For more examples see source code.

Metadata

Release files for django-datetime-helpers 0.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for django-datetime-helpers 0.0.1
File Size Uploaded
django_datetime_helpers-0.0.1.tar.gz 3.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for django-datetime-helpers 0.0.1
File Interpreter ABI Platform
django_datetime_helpers-0.0.1-py3-none-any.whl Python 3 none any Details

Total release size: 6.8 kB

Release files / django_datetime_helpers-0.0.1.tar.gz

Download URL django_datetime_helpers-0.0.1.tar.gz
Size 3.0 kB
Tags Source
SHA-256 checksum
How to use checksums
9cb515665da36086f08a60512a5de716d3b37bf58feed228ae31ac18005e8ad8
BLAKE2b-256 checksum
How to use checksums
997f9c26ecbc7cc9d6777bdc273c68188760ed88ac32ccc69417f4083610ecf7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.1 importlib_metadata/3.7.3 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.7.10

Release files / django_datetime_helpers-0.0.1-py3-none-any.whl

Download URL django_datetime_helpers-0.0.1-py3-none-any.whl
Size 3.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
4f878386a093d749732e427a91264d81fb1a95f570613bec7d36b85558baf24f
BLAKE2b-256 checksum
How to use checksums
0d08f4c6a862dd55c57bcbd71cd748a992fa77c23fa25cf99d01bc62762f5500
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.1 importlib_metadata/3.7.3 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.7.10

Release history Release notifications | RSS feed

This release

0.0.1 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page