Although I do not have the code for you, I can provide information that may give you some progress.
Firstly, Julian Dana makes sense as a basis for calculating lunar and lunisolar dates, because it extinguishes in seconds the SI measured on the geoid. Thus, formulas for predicting the number of SI seconds between these events can be easily correlated. http://en.wikipedia.org/wiki/Julian_day
Lunisolar holidays and the planning of the Jewish calendar as a whole depend on the ratio of the phase of the moon to the sunny weekday. In the Jewish and Islamic calendar, the day begins at sunset. Therefore, if the moon reaches 100% phase near sunset, this can affect when the holidays take place and how the calendar is planned in the future. But what time is sunset? This depends not only on longitude, but also on the breadth of observation. Therefore, you should plan lunisolar calendars and holidays from a specific location on the geoid. http://en.wikipedia.org/wiki/Jewish_calendar#Principles
These factors led to the use of simplified church systems, of which there are several in widespread use in the world, for "calculating" the date of Easter, used instead of direct astronomical observation. http://en.wikipedia.org/wiki/Computus
Thus, the requirements of the traditional Islamic calendar, defined in terms of astronomical observations, including sunset, should be tied to a specific place on geoids if you intend to predict vacation dates and time intervals in SI seconds for an indefinite period of the past or future. This may be the reason for the comments about "North American observations" and the errors of future vacation dates that you spoke of; if the observation of the moon phase and sunny day occurs in North America, and not in Mecca, the calendar will be planned differently.
One of the inevitable and unpredictable factors in predicting any astronomical ephemera and, consequently, lunar or lunar salt events of the calendar, is the change in the Earth's rotation in time. There is a simple formula for evaluating this change, but the actual one is measured using signals from extremely distant celestial objects. http://en.wikipedia.org/wiki/Leap_second Because of this uncertainty and the sensitivity of some calendars to the correlation between the moon phase and the solar ephemeris, there is always a horizon (distant?) for these calendars past which the sequence of dates is unrecognizable.
PyEphem looks very cool, and I'll check it out myself. If its built-in logic does not meet your needs, you have been developing for quite some time how to infinitely predict celestial events in the future. Here's a taste: http://en.wikipedia.org/wiki/Precession_of_the_equinoxes#Values
Again, I do not have a special code for you, but I hope that this information does not repeat what you already know and is useful to you.