Skip to main content

A library to reserve things

Project description

Libres is a reservations management library to reserve things like tables at a restaurant or tickets at an event. It works with Python 3.7+ and requires Postgresql 9.1+.

Documentation | Source | Bugs

This library is at an experimental stage and not yet suitable for production

Tests Coverage Release

Changelog

0.6.0 (2022-08-10)

  • Drops Python 3.6 support. [Daverball]

  • Normalizes availability partitions on 23/25 hours to a 24 hour day so that DST transition days can be rendered the same as regular days.

    This can optionally be avoided by passing normalize_dst=False to the function. [Daverball]

  • Adds Allocation.normalized_availability that reports the availability in the same normalized way. [Daverball]

  • Adds extra parameters to Allocation.limit_timespan that match the new parameters added to sedate.get_date_range. [Daverball]

0.5.4 (2022-06-15)

  • Switches from Travis to GitHub Workflows. [msom]

  • Resolves SQLAlchemy 1.4 warnings. [msom]

0.5.3 (2021-01-18)

  • Fix collections deprecation warnings and fix tests. [dadadamotha]

0.5.2 (2019-11-11)

  • Adds Python 3.8 compatibility. [href]

  • Changes PostgreSQL version check to be distribution-independent. [href]

0.5.1 (2019-01-23)

  • Fixes overlapping allocations not being skipped in all cases. [href]

0.5.0 (2019-01-17)

  • Adds the ability to skip overlapping allocations. [href]

0.4.0 (2017-06-16)

  • Adds the ability to define the allocation/reservation class used by the scheduler.

0.3.1 (2017-06-07)

  • Approved reservations may have session ids again, this restores backwards compatibiility with seantis.reservation. [href]

0.3.0 (2017-06-07)

  • Enables polymorphy on reservations and allocations. [href]

0.2.4 (2017-01-10)

  • Fixes reservation length check not working on DST days. [href]

0.2.3 (2016-10-25)

  • Small performance improvements when dealing with many allocations. [href]

0.2.2 (2016-07-08)

  • Ensures that all models are hashable to avoid problems with certain SQLAlchemy extensions/plugins. [href]

0.2.1 (2016-04-27)

  • Reservations added to the same session may not be duplicated anymore. [href]

  • Errors raised during reservation now have a ‘reservation’ attribute. [href]

0.2.0 (2016-04-26)

  • Adds the ability to have a single token shared across multiple reservations in a single session. [href]

0.1.4 (2015-11-25)

  • Adds the ability to change unapproved reservations. [href]

  • Adds an extra check for start/end time. If the requested start/end time lies outside any possible allocation, an error is raised. [href]

  • Ensures that approved reservations cannot be somehow removed during cleanup. [href]

0.1.3 (2015-09-03)

  • Adds a method to remove unused allocations. [href]

0.1.2 (2015-08-25)

  • Replaces libres.modules.calendar with sedate. [href]

  • Naive start/end dates on the allocation are now automatically converted into the correct timezone when they are set. [href]

0.1.1 (2015-08-19)

  • It was possible to add or move an allocation to an invalid state (end before start date). This is now caught correctly. [href]

0.1.0 (2015-07-30)

  • BREAKING CHANGE: This release switches to a single SERIALIZED connections.

    Previously it used a READ COMMITED and a SERIALIZED connection in parallel, switching to the READ COMMITED connection for readonly queries and using the SERIALIZED connection for write queries.

    Using a serialized connection for everything reduces speed slightly (though we haven’t been able to measure the effect on our lowish traffic sites). But it makes it easier to use libres with an existing connection when integrating it.

    It also simplifies the code by quite a bit.

0.0.2 (2015-03-16)

  • Fix being unable to delete an allocation with a quota > 1. See issue #8. [href]

  • Replace read session write guard with a simpler version. [href]

0.0.1 (2015-02-09)

  • Initial release. [href]

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

libres-0.6.0.tar.gz (87.7 kB view details)

Uploaded Source

Built Distribution

libres-0.6.0-py3-none-any.whl (63.0 kB view details)

Uploaded Python 3

File details

Details for the file libres-0.6.0.tar.gz.

File metadata

  • Download URL: libres-0.6.0.tar.gz
  • Upload date:
  • Size: 87.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.6

File hashes

Hashes for libres-0.6.0.tar.gz
Algorithm Hash digest
SHA256 6632349f555b67a79b1ad4b3816692b9b4d5d6c065e151628c9ec4eca3bc8257
MD5 a8c7388a01c0ca5b8c4e2c1f6a98ae9b
BLAKE2b-256 fe9ea38abb02c376d6adc1ca1e0074c365edf1e9ce999d9f0cc4d5c28f04f583

See more details on using hashes here.

File details

Details for the file libres-0.6.0-py3-none-any.whl.

File metadata

  • Download URL: libres-0.6.0-py3-none-any.whl
  • Upload date:
  • Size: 63.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.6

File hashes

Hashes for libres-0.6.0-py3-none-any.whl
Algorithm Hash digest
SHA256 34eb1b0811a236fd75ee39098141b0b972979b7880a1420ad459b0d02a5c341c
MD5 474a7cf56cb580bcf87b813f4794dbc4
BLAKE2b-256 36284086768c17b20dc6d398d9493570237e76c8710cb9e360f20018d9ea77de

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