>and see if it answers your questions.
NO.
@Tom,
You assume that the current deltatime value is always less than 1 hour,
otherwise the default definition of
current = "%(minute)d%(minute_label)s, %(second)d%(second_label)s"
makes no sense.
You can now redefine this in weewx.conf or %lang.conf:
current = "%(day)d%(day_label)s, %(hour)d%(hour_label)s,
%(minute)d%(minute_label)s".
But with that, you get an error when starting the report:
*ERROR weewx.reportengine: Syntax error: missing option "day_label" in
interpolation.*
If you then change this definition without the '_labels', e.g.;
current = "%(day)d days, %(hour)d hours, %(minute)d minutes".
Then it works, but you lose the foreign language support.
I have now changed the units.py and in
def long_form(self, val_t, context, format_string=None):
I now differentiate between less than 3600 seconds and less than 86400
seconds and then greater.
Tom Keffer schrieb am Mittwoch, 8. Februar 2023 um 17:06:12 UTC+1:
> Take a look at the Upgrade guide and see if it answers your questions.
>
>
> *Breaking changes for skins that use delta times
> <http://www.weewx.com/docs/upgrading.htm#Breaking_changes_for_skins_that_use_delta_times>*
>
> *Changes for custom delta time formats
> <http://www.weewx.com/docs/upgrading.htm#Changes_for_custom_delta_time_formats>*
>
>
>
>
> On Wed, Feb 8, 2023 at 3:54 AM 'Werner Krenn' via weewx-user <
> [email protected]> wrote:
>
>> before 4.10.1
>> $current.runtime 18 Tage, 0 Stunden, 18 Minuten
>>
>> with 4.10.1
>> $current.runtime 1556294 Sekunden
>> $current.runtime.hour 432,3 Stunden
>> $current.runtime.day 18,0 Tage
>> $current.runtime.long_form 18 Minuten, 14 Sekunden #missing days
>> and hours!
>>
>> temporary solution:
>> in weewx.conf
>> [StdReport]
>> [[Defaults]]
>> [[[Units]]]
>> [[[[DeltaTimeFormats]]]]
>> current = "%(day)d Tage, %(hour)d Stunden, %(minute)d
>> Minuten" Labels are Text
>>
>> with
>> current = "%(day)d%(day_label)s,
>> %(hour)d%(hour_label)s, %(minute)d%(minute_label)s"
>> weewx[11327] ERROR weewx.reportengine: Syntax error: missing option
>> "day_label" in interpolation.
>> weewx[11327] ERROR weewx.reportengine: **** Report ignored
>>
>> Is there another solution?
>>
>> --
>> 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/244f2e80-195c-4f99-a5a2-a99af0052257n%40googlegroups.com
>>
>> <https://groups.google.com/d/msgid/weewx-user/244f2e80-195c-4f99-a5a2-a99af0052257n%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/9179d053-e85e-4564-9bdc-2156dea1f0c9n%40googlegroups.com.