Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Timezone CET/UTC not handled correct #50

Open
pjw65 opened this issue Oct 31, 2024 · 0 comments
Open

Timezone CET/UTC not handled correct #50

pjw65 opened this issue Oct 31, 2024 · 0 comments

Comments

@pjw65
Copy link

pjw65 commented Oct 31, 2024

The following code (on Ubuntu Linux 24.01 shows, that CET (UTC+1) is not correct handled, the UTC time differs by 2 hours instead of 1. CEST (Summer time) differs by 3 instead of 2 hours!
Local sunrise time seems correct,

export TZ="Europe/Zurich"; Zurich="47.3774121N 8.4541624E"; ./sunwait list rise $Zurich; ./sunwait list rise gmt $Zurich; date; date -u
07:05
05:05
Do 31 Okt 2024 07:06:18 CET
Do 31 Okt 2024 06:06:18 UTC

same with "debug" parameter added:

Debug: argv[1]: >list<
Debug: argv[2]: >debug<
Debug: argv[3]: >rise<
Debug: argv[4]: >47.3774121n<
Debug: argv[5]: >8.4541624e<
Debug: All output to use local timezone (nogmt).
Debug: Now   utcTm:  Thu Oct 31 16:20:23 2024 GMT
Debug: Now localTm:  Thu Oct 31 17:20:23 2024 CET
Debug: Now UTC bias (add to GMT to get CET) hours: 1.000000
Debug: UTC Bias (hours): 1.000000
Debug: Now: Days since 2000: 9070
Debug: Target  year set to: 124
Debug: Target   mon set to: 9
Debug: Target  mday set to: 31
Debug: Target   utcTm:  Thu Oct 31 00:00:00 2024 GMT
Debug: Target localTm:  Thu Oct 31 01:00:00 2024 CET
Debug: Target UTC bias (add to GMT to get CET) hours: 1.000000
Debug: Target: Days since 2000: 9070
Debug: Co-ordinates -  Latitude: 47.377412N
Debug: Co-ordinates - Longitude: 8.454162E
Debug: Twilight - Daylight
Debug: User specified offset (hours): 0.000000
Debug: Function selected: List
Debug: sunriset.c: Sun directly south: 11.164019 UTC, Diurnal Arc = 10.155840 hours
Debug: sunriset.c: Days since 2000: 9070
07:05
Debug: argv[1]: >list<
Debug: argv[2]: >rise<
Debug: argv[3]: >debug<
Debug: argv[4]: >gmt<
Debug: argv[5]: >47.3774121n<
Debug: argv[6]: >8.4541624e<
Debug: All output to use UTC.
Debug: Now   utcTm:  Thu Oct 31 16:20:23 2024 GMT
Debug: Now localTm:  Thu Oct 31 17:20:23 2024 CET
Debug: Now UTC bias (add to GMT to get CET) hours: 1.000000
Debug: UTC Bias (hours): 1.000000
Debug: Now: Days since 2000: 9070
Debug: Target  year set to: 124
Debug: Target   mon set to: 9
Debug: Target  mday set to: 31
Debug: Target   utcTm:  Thu Oct 31 00:00:00 2024 GMT
Debug: Target localTm:  Thu Oct 31 01:00:00 2024 CET
Debug: Target UTC bias (add to GMT to get CET) hours: 1.000000
Debug: Target: Days since 2000: 9070
Debug: Co-ordinates -  Latitude: 47.377412N
Debug: Co-ordinates - Longitude: 8.454162E
Debug: Twilight - Daylight
Debug: User specified offset (hours): 0.000000
Debug: Function selected: List
Debug: sunriset.c: Sun directly south: 11.164019 UTC, Diurnal Arc = 10.155840 hours
Debug: sunriset.c: Days since 2000: 9070
05:05

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant