Now I see what the problem is. Use "almanac_time", instead of "date":
$almanac(*almanac_time*=($almanac.moon.next_transit.raw)).moon.alt My apologies for not documenting these. Done in commit e98c52d <https://github.com/weewx/weewx/commit/e98c52dee9a11c744bd78f08645fc8ea35d15d6a> -tk On Fri, Sep 20, 2019 at 9:48 AM Bernhard Walser <[email protected]> wrote: > ok i write for testing in my html file these exalple: > > <p>Test</p> > > <p>$almanac.moon.alt</p> > > <p>$almanac(date=($almanac.moon.next_transit.raw)).moon.alt</p> > > <p>$almanac(date=($almanac.moon.next_transit.format("%Y/%m/%d > %H:%M"))).moon.alt</p> > > > <p>$almanac(date=($almanac.moon.previous_transit.format("%z"))).moon.alt</p> > > <p>$almanac(date='2019/1/1 00:00:00').moon.alt</p> > > <p>$almanac(date='1568985086').moon.alt</p> > > <p>$almanac(date='36517.5').moon.alt</p> > > <p>Test</p> > > The output in the file was always the same altitude. so my guess is i > don't change date atribute or it's overwritten. my pyhton skills are not so > god to understand what exakly happen in almanac.py. > > Test > > -24.2707801024 > > -24.2707801024 > > -24.2707801024 > > -24.2707801024 > > -24.2707801024 > > -24.2707801024 > > -24.2707801024 > > Test > > I do also write an easy python code and tryed to put in almanay.py and > extensions.py. > but din't figgred out how to call it from an html.tmp. > > > Am Freitag, 20. September 2019 17:30:53 UTC+2 schrieb Thomas Keffer: >> >> I'm not seeing .raw in any of the tags you posted. What exactly did you >> try? >> >> Perhaps you could show us the error, rather than just "doesn't work"? >> >> On Fri, Sep 20, 2019 at 7:11 AM Bernhard Walser <[email protected]> >> wrote: >> >>> thank you for your fast answer! >>> >>> I have tested to change the date format, also .raw. But doesn't work. >>> >>> <p>$almanac(date=($almanac.moon.next_transit.format("%Y/%m/%d >>> %H:%M"))).moon.alt</p> >>> >>> >>> <p>$almanac(date=($almanac.moon.previous_transit.format("%z"))).moon.alt</p> >>> >>> <p>$almanac(date='2019/1/1 00:00:00').moon.alt</p> >>> >>> <p>$almanac(date=1568985086).moon.alt</p> #Unix epoch >>> >>> <p>$almanac(date=36517.5).moon.alt</p> #Dublin Julian date >>> >>> None of them worked, no error in syslog. >>> >>> >>>> >>> Am Freitag, 20. September 2019 14:05:12 UTC+2 schrieb Thomas Keffer: >>>> >>>> A tag like $almanac.moon.next_transit returns an object of type >>>> ValueHelper, not a floating point number. ValueHelpers contain not >>>> only the floating point number, but also formatting and labeling >>>> information. To get the embedded number, use the ".raw" suffix. See >>>> the section *Formatting options >>>> <http://www.weewx.com/docs/customizing.htm#formatting_options>* in the >>>> Customizing Guide. Your expression becomes (NOT TESTED): >>>> >>>> $almanac(date=($almanac.moon.next_transit*.raw*)).moon.alt >>>> >>>> -tk >>>> >>>> >>>> On Fri, Sep 20, 2019 at 4:38 AM Bernhard Walser <[email protected]> >>>> wrote: >>>> >>>>> Hello >>>>> >>>>> I want to write a code witch calculatetes the difference between, the >>>>> moon altiude at transit today, and altitude at transit yesterday. >>>>> this would give me the "übergehende Mond" or "untergehende Mond". >>>>> >>>>> a code like this don't work: >>>>> >>>>> $almanac(date=($almanac.moon.next_transit)).moon.alt >>>>> $almanac(date=($almanac.moon.previous_transit)).moon.alt >>>>> >>>>> it seems i cant manipulate the time of the ethem observer. >>>>> >>>>> -- >>>>> You received this message because you are subscribed to the Google >>>>> Groups "weewx-user" group. >>>>> To unsubscribe from this group and stop receiving emails from it, send >>>>> an email to [email protected]. >>>>> To view this discussion on the web visit >>>>> https://groups.google.com/d/msgid/weewx-user/935f39d9-c6fe-4ef4-ba98-7b3217348521%40googlegroups.com >>>>> <https://groups.google.com/d/msgid/weewx-user/935f39d9-c6fe-4ef4-ba98-7b3217348521%40googlegroups.com?utm_medium=email&utm_source=footer> >>>>> . >>>>> >>>> -- >>> You received this message because you are subscribed to the Google >>> Groups "weewx-user" group. >>> To unsubscribe from this group and stop receiving emails from it, send >>> an email to [email protected]. >>> To view this discussion on the web visit >>> https://groups.google.com/d/msgid/weewx-user/b03248c4-9a3d-4dd2-831e-c7ba40944349%40googlegroups.com >>> <https://groups.google.com/d/msgid/weewx-user/b03248c4-9a3d-4dd2-831e-c7ba40944349%40googlegroups.com?utm_medium=email&utm_source=footer> >>> . >>> >> -- > You received this message because you are subscribed to the Google Groups > "weewx-user" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/weewx-user/a4dace3a-3d16-4636-a33b-d27babab97e0%40googlegroups.com > <https://groups.google.com/d/msgid/weewx-user/a4dace3a-3d16-4636-a33b-d27babab97e0%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- You received this message because you are subscribed to the Google Groups "weewx-user" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/CAPq0zEA058Nj5VwxkZg08aKMqRn-FUEpE95wEPdQNm665r%2BuKQ%40mail.gmail.com.
