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

Manually set location #206

Open
smichel17 opened this issue Oct 21, 2017 · 9 comments
Open

Manually set location #206

smichel17 opened this issue Oct 21, 2017 · 9 comments
Labels
enhancement needsinfo PR Needed I'm unlikely to ever get around to these, but would accept pull requests for them.

Comments

@smichel17
Copy link
Member

smichel17 commented Oct 21, 2017

Is it important that to be able to manually set your location?

I think the main advantage of using location is saving the effort of setting up the timer and keeping it in sync as the days grow longer and shorter. If manually setting your location takes more effort than you save, the feature is not worth offering; in order to be useful, it much be easy.

Figuring out your latitude and longitude is quite a bit of effort without using location services, so I don't think we should ask the user to do this.

Setting your location from a map would work if the interface is good (ex: Twilight's map was very difficult to select a precise location with; I often had to try several times).

Alternatively, I wonder if it is possible to get a location based on the date and the sunrise/sunset times? If so, we could simply estimate a location based on the custom times the user has chosen and update the timer based on it. This seems like the easiest way, both from a user's point of view and effort to develop. However, it obviously depends on a big 'if'.

This issue was split out from #5, so it's not mixed in with irrelevant discussion.

@smichel17 smichel17 added this to the unplanned milestone Oct 21, 2017
@smichel17 smichel17 added enhancement feedback wanted android Requires android-specific knowledge. Generally also implies 'hard'. labels Oct 21, 2017
@smichel17 smichel17 removed this from the someday/maybe milestone Dec 20, 2017
@smichel17 smichel17 added needsinfo and removed design android Requires android-specific knowledge. Generally also implies 'hard'. labels Dec 20, 2017
@smichel17 smichel17 added this to the someday/maybe milestone Dec 22, 2017
@nzmacalasdair
Copy link

So Redshift, a similar application, uses Latitude/Longditude measurements, which are pretty easy for a user to look up, with services like the following: https://www.latlong.net/,

Might be the easiest method to develop as well?

@decadent
Copy link

If I understand the question right, it's about having the option to manually specify the location, vs only using the system location?

If so, I'd like to add a datapoint: I have the system location services permanently disabled to avoid having the location snooped by Google. I know they still have it through other means, but with ever so slightly less precision.

As for the latitude and longitude, Wikipedia has it on cities' pages, and of course Google's search also can supply it.

@smichel17
Copy link
Member Author

Red Moon does not care what your location is. We only ask for location because it can be used to calculate sunrise/sunset times, the data we actually care about. I am wondering if there is any other data we could ask the user for, that could be used to calculate sunrise/sunset times instead of location.

The reason I am interested is that this data might be for the user to produce/input than location. Prompting for Latitude/Longitude is certainly the easiest method to develop.

@Albirew
Copy link

Albirew commented Mar 4, 2020

An easier way would be to ask user to add city/country and to translate that internally into lat/lon, but for that, it would either need a database stored in app or to use a public database over the internets

@decadent
Copy link

decadent commented Mar 5, 2020

Yeah, software like the desktop F.lux usually asks for the city, sometimes with auto-completion (which is much nicer than no autocompletion). The procedure is sorta worked-out on websites by now, but I'm not sure what kind of database is typically used—the db needs to be updated regularly and might be rather big to be embedded. One thing to be wary of is, there are plenty of places with identical names, so the region for each should be clarified in the auto-completion or in another way.

@Albirew
Copy link

Albirew commented Mar 5, 2020

Is there a need for regular updates and every villages of the world? I mean, big cities aren't moving, new cities are not created every months, and localisation data doesn't need to be really precise, using a city that is 50~100km² around you should be enough, no? If you're limiting database to that, it shouldn't be bigger than 1~2mb...

@decadent
Copy link

decadent commented Mar 5, 2020

Well, for a commercial service it would be considered bad tone if a user can't find their town in the list—but it could fly for open-source software. Still, cities get renamed or change their population and databases fix their mistakes. People are notoriously dirty in their handling of real-world information and don't want to fit into computer-convenient constraints.

By the way, fallback to manual entry of latitude and longitude should still be possible—for the case when I live in remote outback.

@Totorrr
Copy link

Totorrr commented Dec 19, 2020

Hello,

please consider adding an option to manually set the position using latitude an longitude values. I agree that a list of "big enough" cities location would be a cool plus.

What I would also love, is the possibility of adding an offset to those sunset/sunrise times (like go red 30 or 60 minutes after sunset), or to use twilight values: civil, nautical or astronomical dawn/dusk times (see #280 in this regard).

Like @decadent, I am reluctant to enable the location service when not really necessary, for battery, but mostly privacy concerns, and also because when I tweak Red Moon, it is usually at night, within a building, and I don't have a GPS signal (I disabled WiFi and GSM location services, because it sends sensitive info to Google servers and needs an Internet connection working).

I am not in favor of "get a location based on the date and the sunrise/sunset times" as @smichel17 suggests, because:

  • it means you need to know the sunrise/sunset times for your location beforehand, as precisely as possible,
  • as we are close to the equinoxes (around March 21 and September 21), it would be impossible (or inaccurate at best) to guess the location of the device (the closer to the equinoxes, the less accuracy).

@smichel17
Copy link
Member Author

See #281

  • I think it is reasonable to add a text preference in which you can enter lat,lon. Not the ideal experience, but beats having to turn on gps when you don't want to.
    • I am willing to implement this, but no guarantees about when I will get to it, maybe in a month, maybe in a year or two. If you want it sooner, PRs welcome.
    • The bulk of the work is in just adding the android boilerplate for a preference, with the appropriate instructions. If someone implements just this part (but doing nothing on save), I will make it save to / load from the correct place.
  • It is also reasonable to add a drop-down to select a city. I would suggest using the IANA time zone cities. However, adding both this and manual lat/lon would be excessive with the way the preferences are currently laid out. So, I would accept a PR adding this, but will not do it myself.

@smichel17 smichel17 added the PR Needed I'm unlikely to ever get around to these, but would accept pull requests for them. label Sep 13, 2021
@smichel17 smichel17 removed this from the someday/maybe milestone Sep 13, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement needsinfo PR Needed I'm unlikely to ever get around to these, but would accept pull requests for them.
Development

No branches or pull requests

5 participants