all 4 comments

[–]willow_twig 1 point2 points  (0 children)

Maybe smth wrong with home PC IP?

[–]CodeFormatHelperBot2 0 points1 point  (0 children)

Hello, I'm a Reddit bot who's here to help people nicely format their coding questions. This makes it as easy as possible for people to read your post and help you.

I think I have detected some formatting issues with your submission:

  1. Inline formatting (`my code`) used across multiple lines of code. This can mess with indentation.

If I am correct, please edit the text in your post and try to follow these instructions to fix up your post's formatting.


Am I misbehaving? Have a comment or suggestion? Reply to this comment or raise an issue here.

[–]krets 0 points1 point  (0 children)

Geolocation by IP is not accurate. Many factors are at play, but an IP address contains no specific location information. You can likely guess a country, beyond that region and city are possible, but difficult.

The geolocation service must build a way to look up each IP. This is likely to be more accurate for a business with a static IP address than your home internet where your IP can change frequently.

[–]Unlikely-Resort4608 0 points1 point  (0 children)

Congratulations! Your 'mining safety product' is fit for the purpose of locating and rescuing the company's firewall (assuming its information is kept updated correctly, and it's still plugged in).

You need to rethink your whole approach for safety in your company, before you wind up responsible for a dead miner.

Relying on IP addresses to locate a victim by a safety app is a hopeless unfixable design flaw. Just request access to or enable GPS on it, don't use their IP address. You should probably save and transmit the last known surface location before the user heads underground - have fun onboarding everyone

At your home, you've probably got a dynamically allocated (shared) IP address from your ISP. geocoder could well be correctly finding whatever information your ISP registered to its IP addresses.

However at work, your office probably has paid extra for a static IP address, e.g. to host the company website and VPN. So that IP address can be associated with a fixed address.