Open Kapple14 opened 3 months ago
💎 $10 bounty created by Kapple140
🙋 If you start working on this, comment /attempt #1
along with your implementation plan
👉 To claim this bounty, submit a pull request that includes the text /claim #1
somewhere in its body
📝 Before proceeding, please make sure you can receive payouts in your country
💵 Payment arrives in your account 2-5 days after the bounty is rewarded
💯 You keep 100% of the bounty award
🙏 Thank you for contributing to Kapple14/KiddyGuide!
👉 Add a bounty • Share on socials
Attempt | Started (GMT+3) | Solution |
---|---|---|
🟢 @abhishek818 | #3 |
Can I be assigned? @Kapple14
/attempt #1
implementation plan, please
@Kapple14 Tried repro, fetching location gets stuck infinitely in Firefox, works fine in GChrome for me. (Both browsers asks for location permissions).
Tested with npm packages like current-location-geo, others and tried popular package like react-geolocated (didnt tested with it since it uses hook and older versions supporting need React<18.0), But to no avail.
Seems navigator apis have this known issue for a long time now, Refer this stackoverflow link and you will find several other threads related : link, Also tried every possible way defined in Firefox official support site
I feel we can go ahead with fixed values for request timeout and optional cache expiry (arguments of navigator.geolocation.getCurrentPosition , Refer link ), and throw a proper Error on timeout expiry, Pushing a PR for it, up to you.
Also, Found some active high rated repos still are using navigator apis similarly. (though i saw some github issues talking about this issue but no solution in the end conversation). Overall, its about issues with older versions of browsers/location permission settings.
Also, If Firefox failure is the same issue for you as well, you can once try with enabling Geolocation API in about:config by toggling geo.enabled. (We might have diff Firefox versions, so the ask)
I see! Thanks for pointing out the issue so precisely, but I can not see how we could fix that issue in the short term without access to a modern browser. Will close the issue as it does not seem solvable from my perspective.
@Kapple14 Overall, its about issues with older versions of browsers/location permission settings. But shouldnt we atleast have some timeout (and then throw error suggesting users to update browser or enable location permissions) for location fetch call ?, Else it gets stuck infinitely sometimes. If agreed, you can review or suggest alternatives (if any) on my PR
Will have a look at it, but the features do not seem for this repository. Thank you
GitHub Issue: Inconsistent Location Detection in KiddyGuide App
Problem: Location detection sporadically fails or gets stuck during app use, possibly related to Google Geoservices integration.
Symptoms:
Steps to Reproduce:
Expected Behavior:
Proposed Solution: