Skip to main content

Description

https://travis-ci.org/kurtraschke/pyRFC3339.svg?branch=master

pyRFC3339 parses and generates RFC 3339-compliant timestamps using Python datetime.datetime objects.

>>> from pyrfc3339 import generate, parse
>>> from datetime import datetime
>>> import pytz
>>> generate(datetime.utcnow().replace(tzinfo=pytz.utc)) #doctest:+ELLIPSIS
'...T...Z'
>>> parse('2009-01-01T10:01:02Z')
datetime.datetime(2009, 1, 1, 10, 1, 2, tzinfo=<UTC>)
>>> parse('2009-01-01T14:01:02-04:00')
datetime.datetime(2009, 1, 1, 14, 1, 2, tzinfo=<UTC-04:00>)

Installation

To install the latest version from PyPI:

$ pip install pyRFC3339

To install the latest development version:

$ pip install https://github.com/kurtraschke/pyRFC3339/tarball/master#egg=pyRFC3339-dev

To build the documentation with Sphinx:

  1. $ pip install Sphinx

  2. $ python setup.py build_sphinx

The documentation is also available online at:

https://pythonhosted.org/pyRFC3339/

Download files

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

Source Distribution

pyRFC3339-0.2.tar.gz (5.1 kB view details)

Uploaded Source

File details

Details for the file pyRFC3339-0.2.tar.gz.

File metadata

  • Download URL: pyRFC3339-0.2.tar.gz
  • Upload date:
  • Size: 5.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for pyRFC3339-0.2.tar.gz
Algorithm Hash digest
SHA256 a504ff6bcb363fa402d393f65fe5f542475e54fbfc55817b80892ba93b22e6de
MD5 5e0f7e40e363812180fffaae52daf2e6
BLAKE2b-256 9c80472db644715f8bd7d7bb5df77c740605549ed7d059c4ebcfcbd4cd4efd84

See more details on using hashes here.

Release history Release notifications | RSS feed

2.1.0

2 files

2.0.1

2 files

1.1

2 files

1.0

2 files

This release

0.2 This release

1 file

0.1

1 file

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page