Giter VIP home page Giter VIP logo

python-zmanim's People

Contributors

jacobshilitz avatar pinnymz avatar yankyhoffman avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

python-zmanim's Issues

Implement ComplexZmanimCalendar

Are there any plans to port over the ComplexZmanimCalendar class from KosherJava? Or is it already implemented elsewhere?

Date calculations are off

When I run this bit of code

from zmanim.hebrew_calendar.jewish_calendar import JewishCalendar
print(JewishCalendar(5783, 1, 17).day_of_week)

it insists that today is that date (today) is shabbos, which it is not.
Are the calculations off? Or is it a problem on my end?

Zmanim vary by time when using a `datetime` object as input

Different times yield different zmanim.
MWE:

import datetime as dt
from zmanim.util.geo_location import GeoLocation
from zmanim.zmanim_calendar import ZmanimCalendar
location = GeoLocation('Lakewood, NJ', 40.0721087, -74.2400243, 'America/New_York', elevation=15)
print(ZmanimCalendar(geo_location=location, date=dt.datetime(2023,8,7)).shkia())
print(ZmanimCalendar(geo_location=location, date=dt.datetime(2023,8,7,1)).shkia())

Even worse, when no date is passed, the default is a datetime object with the current time, so

print(ZmanimCalendar(geo_location=location).shkia())

will yield different, incorrect times throughout the day.

As per @pinnymz, ZmanimCalendar should require a date object.
While a datetime object can be coerced to a date, since the caller may possibly want the next day's zmanim (e.g., if it's after nightfall), we agreed that the input should be restricted to date object, placing the onus on the caller to decide which date.

PR to follow.

JewishDate Go back Error

When jd.back() is called and it needs to go a year back
like this:
jd = JewishDate(5781, 1, 1)
jd.back()
or
jd.forward(-1)

I get an error

m = days_of_year.length
AttributeError: 'list' object has no attribute 'length'

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.