Skip to main content

Simple module to parse ISO 8601 dates

Project description

Simple module to parse ISO 8601 dates

This module parses the most common forms of ISO 8601 date strings (e.g. 2007-01-14T20:34:22+00:00) into datetime objects.

>>> import iso8601
>>> iso8601.parse_date("2007-01-25T12:00:00Z")
datetime.datetime(2007, 1, 25, 12, 0, tzinfo=<iso8601.iso8601.Utc ...>)
>>>

Changes

0.1.3

  • Fixed the microsecond handling, the generated microsecond values were way too small. Fixes issue 9.

0.1.2

  • Adding ParseError to __all__ in iso8601 module, allows people to import it. Addresses issue 7.

  • Be a little more flexible when dealing with dates without leading zeroes. This violates the spec a little, but handles more dates as seen in the field. Addresses issue 6.

  • Allow date/time separators other than T.

0.1.1

  • When parsing dates without a timezone the specified default is used. If no default is specified then UTC is used. Addresses issue 4.

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

iso8601-0.1.3.tar.gz (4.6 kB view details)

Uploaded Source

Built Distributions

iso8601-0.1.3-py2.5.egg (7.4 kB view details)

Uploaded Egg

iso8601-0.1.3-py2.4.egg (7.4 kB view details)

Uploaded Egg

File details

Details for the file iso8601-0.1.3.tar.gz.

File metadata

  • Download URL: iso8601-0.1.3.tar.gz
  • Upload date:
  • Size: 4.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for iso8601-0.1.3.tar.gz
Algorithm Hash digest
SHA256 39378d3d579eec2fe451a2bac9e0b001e4e3321e60ba13c37397868f931d9eee
MD5 969a79fec1b591d9f28425b1fbb03f96
BLAKE2b-256 5ae960eaa3be33cb8780d0163c46e512603433986dbff4033f639543b7c50335

See more details on using hashes here.

File details

Details for the file iso8601-0.1.3-py2.5.egg.

File metadata

  • Download URL: iso8601-0.1.3-py2.5.egg
  • Upload date:
  • Size: 7.4 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for iso8601-0.1.3-py2.5.egg
Algorithm Hash digest
SHA256 d021370139691328ca5834317659537a393c7aff4fb610138fe379cf8d60f6c0
MD5 42923fdb060e23af4af367166fb6475a
BLAKE2b-256 a11d19a1a3d4336d1da7bbf426f4b300361e3d34dc1f0e5c855464e0f2cbcda7

See more details on using hashes here.

File details

Details for the file iso8601-0.1.3-py2.4.egg.

File metadata

  • Download URL: iso8601-0.1.3-py2.4.egg
  • Upload date:
  • Size: 7.4 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for iso8601-0.1.3-py2.4.egg
Algorithm Hash digest
SHA256 1aacd27d9f16804972f82c36b172c41418e540bf6a0bb305a64700ff24aecc51
MD5 176667c1212cdf0c0bc42e4326f740fd
BLAKE2b-256 2d8107ed18b659f908a3a5258f8fc70bce34d3c4edfa6100a508c568bdcedb21

See more details on using hashes here.

Supported by

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