Skip to main content

Bindings to the zmanim-core rust library

Project description

Zmanim Core Python Bindings

PyPI Version Python Versions License

High-performance Python bindings for the Zmanim Core library - a comprehensive solution for calculating Jewish religious times (zmanim) and astronomical events.

🌟 Features

  • Astronomical Calculations: Precise sunrise, sunset, and astronomical event calculations
  • Jewish Religious Times: Complete zmanim calculations including:
    • Alos Hashachar (dawn)
    • Tzais (nightfall)
    • Chatzos (midday)
    • Prayer times (Shacharis, Mincha, Maariv)
    • Candle lighting times
  • Hebrew Calendar: Full Jewish calendar support with:
    • Date conversions between Gregorian and Jewish dates
    • Holiday calculations
    • Parsha (weekly Torah portion) information
    • Daf Yomi calculations
  • Geolocation Support: Location-based calculations using coordinates
  • High Performance: Optimized Rust implementation with minimal overhead
  • Cross-Platform: Supports Windows, Linux, macOS

🚀 Installation

From PyPI (Recommended)

pip install zmanim-core-bindings

📖 Quick Start

Basic Usage

import zmanim_py.zmanim_core as zmanim
from datetime import datetime
import time

# Get current timestamp (milliseconds since epoch)
now = int(time.time() * 1000)

# Create a location (Jerusalem coordinates)
location = zmanim.new_geolocation(
    latitude=31.78,    # Jerusalem latitude
    longitude=35.22,   # Jerusalem longitude
    elevation=754.0    # Elevation in meters
)

# Create a zmanim calendar
calendar = zmanim.new_zmanim_calendar(
    timestamp=now,
    geo_location=location,
    use_astronomical_chatzos=True,
    use_astronomical_chatzos_for_other_zmanim=True,
    candle_lighting_offset=18 * 60 * 1000  # 18 minutes before sunset
)

# Get Alos Hashachar (dawn)
alos_timestamp = calendar.get_alos_hashachar()
if alos_timestamp:
    alos_datetime = datetime.fromtimestamp(alos_timestamp / 1000)
    print(f"Alos Hashachar: {alos_datetime}")
    # Note: This is in UTC, convert to local timezone as needed

For more information, see the Rust API Docs and the original KosherJava docs which this library is based on.

📄 License

This project is licensed under the MIT License - see the LICENSE file for details.

🙏 Acknowledgments

This library is a Rust port of the KosherJava library, which provides the reference implementation and testing framework. Special thanks to the KosherJava contributors for their excellent work.

Testing against KosherJava git hash: 0ce858258bff15c11235b1f1063d2eb0ef22b994

📞 Support


Made with ❤️ for the Jewish community and Python developers

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

zmanim_core_bindings-0.2.0.tar.gz (146.2 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

zmanim_core_bindings-0.2.0-py3-none-win_amd64.whl (384.5 kB view details)

Uploaded Python 3Windows x86-64

zmanim_core_bindings-0.2.0-py3-none-win32.whl (333.5 kB view details)

Uploaded Python 3Windows x86

zmanim_core_bindings-0.2.0-py3-none-musllinux_1_2_x86_64.whl (545.7 kB view details)

Uploaded Python 3musllinux: musl 1.2+ x86-64

zmanim_core_bindings-0.2.0-py3-none-musllinux_1_2_i686.whl (571.3 kB view details)

Uploaded Python 3musllinux: musl 1.2+ i686

zmanim_core_bindings-0.2.0-py3-none-musllinux_1_2_armv7l.whl (617.1 kB view details)

Uploaded Python 3musllinux: musl 1.2+ ARMv7l

zmanim_core_bindings-0.2.0-py3-none-musllinux_1_2_aarch64.whl (520.9 kB view details)

Uploaded Python 3musllinux: musl 1.2+ ARM64

zmanim_core_bindings-0.2.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (383.9 kB view details)

Uploaded Python 3manylinux: glibc 2.17+ x86-64

zmanim_core_bindings-0.2.0-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl (397.8 kB view details)

Uploaded Python 3manylinux: glibc 2.17+ s390x

zmanim_core_bindings-0.2.0-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl (415.6 kB view details)

Uploaded Python 3manylinux: glibc 2.17+ i686

zmanim_core_bindings-0.2.0-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl (352.3 kB view details)

Uploaded Python 3manylinux: glibc 2.17+ ARMv7l

zmanim_core_bindings-0.2.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (362.9 kB view details)

Uploaded Python 3manylinux: glibc 2.17+ ARM64

zmanim_core_bindings-0.2.0-py3-none-macosx_11_0_arm64.whl (360.2 kB view details)

Uploaded Python 3macOS 11.0+ ARM64

zmanim_core_bindings-0.2.0-py3-none-macosx_10_12_x86_64.whl (384.5 kB view details)

Uploaded Python 3macOS 10.12+ x86-64

File details

Details for the file zmanim_core_bindings-0.2.0.tar.gz.

File metadata

  • Download URL: zmanim_core_bindings-0.2.0.tar.gz
  • Upload date:
  • Size: 146.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: maturin/1.9.3

File hashes

Hashes for zmanim_core_bindings-0.2.0.tar.gz
Algorithm Hash digest
SHA256 67f865a3f47f515d1bc0a843203515f54018091500afccfc470b21d5fc982a61
MD5 9e43e294bf1888d7844e15b9ecc0b784
BLAKE2b-256 6f214e14b1fb310a0a23b13bdeabc50fb0b60be782fefdc209731c6f709de148

See more details on using hashes here.

File details

Details for the file zmanim_core_bindings-0.2.0-py3-none-win_amd64.whl.

File metadata

File hashes

Hashes for zmanim_core_bindings-0.2.0-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 bde1ae64e4f5f75a304cf4d198b05a0c78e3a8ed5d030d738dc9c2337cb35941
MD5 54b8266c26092b167e02b9ecbe301567
BLAKE2b-256 72c53d926192e38a0aa9725f0cc0316c6ba0a9e5390f94fa7d6edb840ebf91ee

See more details on using hashes here.

File details

Details for the file zmanim_core_bindings-0.2.0-py3-none-win32.whl.

File metadata

File hashes

Hashes for zmanim_core_bindings-0.2.0-py3-none-win32.whl
Algorithm Hash digest
SHA256 4b90bacfb3c699d7fb0bca076cc1d2ab57daa35698d9d2430134e531f50d040c
MD5 a2718454d1dd80334747bbd6855a3003
BLAKE2b-256 877b9d45a45cd15b6fbdae5966976fd3ebf5acac3102a211581892b3165b2853

See more details on using hashes here.

File details

Details for the file zmanim_core_bindings-0.2.0-py3-none-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for zmanim_core_bindings-0.2.0-py3-none-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 b8e71b1674b81f7c9a237a44883cfa6de9d25f75e8bfeb7dc00872ac53cc1f48
MD5 cb291975ae116aded5625459f57e8acb
BLAKE2b-256 abd8dbd68bf0eadfcc0e79c48ce80e6b855aacf02664a3d0630bbea46fdd84c2

See more details on using hashes here.

File details

Details for the file zmanim_core_bindings-0.2.0-py3-none-musllinux_1_2_i686.whl.

File metadata

File hashes

Hashes for zmanim_core_bindings-0.2.0-py3-none-musllinux_1_2_i686.whl
Algorithm Hash digest
SHA256 ebd8497ce748c1b597185b6478e0e1579b69ebc047b73cee9df6e90b467944df
MD5 a3036b4ba471f3ec8c51c7fa9add5526
BLAKE2b-256 cd4e8ae4f5c4b5493a669ae4f2e7b737ed28b6dd29aedf85b240025d37eae7c3

See more details on using hashes here.

File details

Details for the file zmanim_core_bindings-0.2.0-py3-none-musllinux_1_2_armv7l.whl.

File metadata

File hashes

Hashes for zmanim_core_bindings-0.2.0-py3-none-musllinux_1_2_armv7l.whl
Algorithm Hash digest
SHA256 eef2e314d524bb990bc9d092f2c91fdc8f530f1bf97916ff5119410de53adb6f
MD5 99bf07604a2707cf30765775642f7ff9
BLAKE2b-256 1479b1d456f9067722be42eaabaabdc272e0952c9cc36dc393eda9eaa0d9b6c6

See more details on using hashes here.

File details

Details for the file zmanim_core_bindings-0.2.0-py3-none-musllinux_1_2_aarch64.whl.

File metadata

File hashes

Hashes for zmanim_core_bindings-0.2.0-py3-none-musllinux_1_2_aarch64.whl
Algorithm Hash digest
SHA256 163167cdb0bb2691d30e4be0125879567e6ea7022d65b05658154dbdb73a9acd
MD5 9a13beb6c3f4479ef2ba81aa7e13e551
BLAKE2b-256 351a3143c241edccdcc0d4d033bcbe06e71f06b1030a102332657e13ba60652c

See more details on using hashes here.

File details

Details for the file zmanim_core_bindings-0.2.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for zmanim_core_bindings-0.2.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 a033b4d24f5260e0a30200c1c55bb880ac95b889db14023154f9617528b933d8
MD5 87dddae90fc3e2e39e3354c799a76bea
BLAKE2b-256 b9c84405cc445e2167cf46ed49386e62aaa721a0b20fd82d83fa8745d9db5b5f

See more details on using hashes here.

File details

Details for the file zmanim_core_bindings-0.2.0-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl.

File metadata

File hashes

Hashes for zmanim_core_bindings-0.2.0-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl
Algorithm Hash digest
SHA256 adc2c0071686bc8708090f3b15511d694bd5968f4e58d63ff35829f1ffa93cf2
MD5 6b6cabb178cb5eb2edd29eb72446d156
BLAKE2b-256 2b8f4dad820830d1824c65db565f1797860f10493cc13cba720a489cae225284

See more details on using hashes here.

File details

Details for the file zmanim_core_bindings-0.2.0-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for zmanim_core_bindings-0.2.0-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 c86fb5eb67f09e0f00f9a060bfd1b604891856e2486ab5b8283eb12ab0b58783
MD5 2e1418a0b67306d64048d803c43b5cce
BLAKE2b-256 7df5423b15e093c54b25d7f9b55fa3814337037c9407dc1c5f3d39fc0a406d07

See more details on using hashes here.

File details

Details for the file zmanim_core_bindings-0.2.0-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl.

File metadata

File hashes

Hashes for zmanim_core_bindings-0.2.0-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
Algorithm Hash digest
SHA256 45db17c741264ad77404ae21d1709fc7bfcc2d6682471fe9c0ff98fd12efb649
MD5 0bcdb2485d25968ef96aec63a872a1f6
BLAKE2b-256 4df83e1b6721f0af06b642418302bc520f539d0127ceab21c208e99f4e78b34f

See more details on using hashes here.

File details

Details for the file zmanim_core_bindings-0.2.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for zmanim_core_bindings-0.2.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 030223fe7a37f272b772eefe830e2d134db2c6ffd865b4d36f145f65cd3c7936
MD5 7b16ddd59cdae753d17de37767596503
BLAKE2b-256 5fa89e0bb60583c043404e0ac1bd58b5f4d1e456b52d70ce007f4bae6218665d

See more details on using hashes here.

File details

Details for the file zmanim_core_bindings-0.2.0-py3-none-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for zmanim_core_bindings-0.2.0-py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 f2b1b909e118aabe5a91a3125207c8e85923756649d1805ee644b2f8c3554c40
MD5 8f7fb74abb42fec804a93b3ca6f0d96e
BLAKE2b-256 8868d8fd85152ca8b64a5a619163ad65c402d520f01fab24801ad1a932e5dba0

See more details on using hashes here.

File details

Details for the file zmanim_core_bindings-0.2.0-py3-none-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for zmanim_core_bindings-0.2.0-py3-none-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 3ad44256e3a96a63d7f1ed105ff0d147f10235959a6f04a64afe841403e5d73b
MD5 085cec6e82ade11d3d189bb8c6e60f9f
BLAKE2b-256 08e8bd6194ab4a0ceffd2078b9deb34508ab7432834e60c175e7d3b4759e53c8

See more details on using hashes here.

Supported by

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