TkinterMapView
TkinterMapView copied to clipboard
Add `user_agent` parameter when instantiating classes (and fix examples)
The Nominatim Usage Policy requires the application to be identified in HTTP requests. In this context, TkinterMapView is not the application; it is a library. Calling applications need to pass a User-Agent string. (Notice the corresponding documentation for geopy.)
This adds a unique User-Agent to each example. (Additionally, fix the window title in several examples, and make the import statements consistent.)
In the case of my team, this has now become a problem because some user of this library has spammed the search API and it seems to have temporarily banned the user agent. I'd like to see this in a future release of the library.