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

[Bug] App doesn't know if it's day or night during midnight sun / polar night #488

Open
vodkapmp opened this issue Jun 20, 2023 · 4 comments

Comments

@vodkapmp
Copy link

I live within the arctic circle, and when midnight sun / polar night happens, the app doesn't know if it is day or night.
This means it'll sometime show as nighttime 24/7 during midnight sun, and show as daytime 24/7 during polar night.

Currently where I am it is midnight sun, and the sun is not going below the horizon at all for weeks on end, this confuses GW because accuweather reports the sun as never rising nor setting.
image

This makes the live wallpaper kinda sad, as it's bright and sunny out but my wallpaper is showing a dark sky.

@papjul
Copy link
Contributor

papjul commented Jun 21, 2023

I noticed that with AccuWeather provider, the sunrise and sunset info is missing when testing an arctic circle city.

In this situation, how is the app supposed to know if it means:

  1. Info is missing
  2. Midnight sun
  3. Polar night

I’m not sure to know what could be the correct approach to fix this issue.

Best I can think is when values are missing, use a default 06:00 -> 18:00 (12 hours of sun/12 hours of night).

What do you think?

@vodkapmp
Copy link
Author

I think a fallback to 06-18 seems to be the most sensible.

What would be the best is if it could default to 24/7 night or day depending on time of year if in a location north of certain latitude (or south of certain latitude for the opposite in southern hemisphere, but I don't think many people in Antarctica care)
But this sounds like it'd be unnecessarily complicated.

@papjul
Copy link
Contributor

papjul commented Jun 22, 2023

I think a fallback to 06-18 seems to be the most sensible.

Not sure to understand the meaning of "sensible" here? I interpret two ways.

What would be the best is if it could default to 24/7 night or day depending on time of year if in a location north of certain latitude (or south of certain latitude for the opposite in southern hemisphere, but I don't think many people in Antarctica care) But this sounds like it'd be unnecessarily complicated.

If we go that way, it means we calculate sunrise/sunset ourselves from any coordinates in the world. I don't know how heavy this operation is for an Android device, this would require some tests.

@vodkapmp
Copy link
Author

I think a fallback to 06-18 seems to be the most sensible.

Not sure to understand the meaning of "sensible" here? I interpret two ways.

What I mean is that there is no need to over-complicate the solution, and just going with "there is no data, default to 12/12 hours" solves both the issue of potentially missing data, and location issues like within the arctic and antarctic circle.

My suggesting to start taking date and coordinates into account is a needlessly complicated solution for such a small amount of the userbase.

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

2 participants