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

inconsistent encoding and list of attributes retreived from OSM (same preset, different zoom levels) #427

Open
cedivers opened this issue Oct 30, 2022 · 0 comments
Labels
bug An identified bug

Comments

@cedivers
Copy link

cedivers commented Oct 30, 2022

What is the bug?

I'm facing a lot of issues with encoding in data retrieved from QuickOSM.
I work on an area (south french Brittany) using one, and only one QuickOSM preset.
I download OSM data in my canvas extent using this preset. 
- the full list of OSM attributes are downloaded for each feature
- the names with french characters and not showing correctly (value of "name" key in attribute table) : for instance I get "Chapelle de la Moëre" instead of "Chapelle de la Moëre", even if every setting in Qgis / geopackage says data encoding is UTF-8

I zoom in really close around this "Chapelle", and run this preset again.
- now I retreive only a few of OSM attributes.
- the name prints correctly : "Chapelle de la Moëre"

For the attributes, I'm guessing you get the attributes which are not NULL for at least one feature in the area. This would explain what I get... but tI can't understand for the encoding, and this drives me crazy (I never know in advance if my output will be correct or not).

I tried using selection by layer extend instead of canvas : same.
My preset currently outputs a geopackage, but I found the same issue using temporary files 
The content of the temporary OSM files is always OK : the xml shows "Chapelle de la Moëre", and encoding UTF-8
URL giving bad encoding when showing data :
Encoded URL: https://lz4.overpass-api.de/api/interpreter?data=[out:xml] [timeout:25];%0A(%0A node[%22tourism%22%3D%22caravan_site%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A node[%22amenity%22%3D%22parking%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A node[%22amenity%22%3D%22drinking_water%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A node[%22amenity%22%3D%22toilets%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A node[%22tourism%22%3D%22picnic_site%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A node[%22tourism%22%3D%22camp_site%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A node[%22leisure%22%3D%22picnic_table%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A node[%22amenity%22%3D%22shower%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A node[%22tourism%22%3D%22viewpoint%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A node[%22historic%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A node[%22tourism%22%3D%22information%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A node[%22information%22%3D%22office%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A node[%22amenity%22%3D%22townhall%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A node[%22amenity%22%3D%22place_of_worship%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A way[%22tourism%22%3D%22caravan_site%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A way[%22amenity%22%3D%22parking%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A way[%22amenity%22%3D%22drinking_water%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A way[%22amenity%22%3D%22toilets%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A way[%22tourism%22%3D%22picnic_site%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A way[%22tourism%22%3D%22camp_site%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A way[%22leisure%22%3D%22picnic_table%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A way[%22amenity%22%3D%22shower%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A way[%22tourism%22%3D%22viewpoint%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A way[%22historic%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A way[%22tourism%22%3D%22information%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A way[%22information%22%3D%22office%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A way[%22amenity%22%3D%22townhall%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A way[%22amenity%22%3D%22place_of_worship%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A relation[%22tourism%22%3D%22caravan_site%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A relation[%22amenity%22%3D%22parking%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A relation[%22amenity%22%3D%22drinking_water%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A relation[%22amenity%22%3D%22toilets%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A relation[%22tourism%22%3D%22picnic_site%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A relation[%22tourism%22%3D%22camp_site%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A relation[%22leisure%22%3D%22picnic_table%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A relation[%22amenity%22%3D%22shower%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A relation[%22tourism%22%3D%22viewpoint%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A relation[%22historic%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A relation[%22tourism%22%3D%22information%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A relation[%22information%22%3D%22office%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A relation[%22amenity%22%3D%22townhall%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A relation[%22amenity%22%3D%22place_of_worship%22]( 47.09718,-2.5272,47.62318,-1.33824);%0A);%0A(._;%3E;);%0Aout body;&info=QgisQuickOSMPlugin

Area with correct encoding:
Encoded URL: https://lz4.overpass-api.de/api/interpreter?data=[out:xml] [timeout:25];%0A(%0A node[%22tourism%22%3D%22caravan_site%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A node[%22amenity%22%3D%22parking%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A node[%22amenity%22%3D%22drinking_water%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A node[%22amenity%22%3D%22toilets%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A node[%22tourism%22%3D%22picnic_site%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A node[%22tourism%22%3D%22camp_site%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A node[%22leisure%22%3D%22picnic_table%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A node[%22amenity%22%3D%22shower%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A node[%22tourism%22%3D%22viewpoint%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A node[%22historic%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A node[%22tourism%22%3D%22information%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A node[%22information%22%3D%22office%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A node[%22amenity%22%3D%22townhall%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A node[%22amenity%22%3D%22place_of_worship%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A way[%22tourism%22%3D%22caravan_site%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A way[%22amenity%22%3D%22parking%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A way[%22amenity%22%3D%22drinking_water%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A way[%22amenity%22%3D%22toilets%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A way[%22tourism%22%3D%22picnic_site%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A way[%22tourism%22%3D%22camp_site%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A way[%22leisure%22%3D%22picnic_table%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A way[%22amenity%22%3D%22shower%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A way[%22tourism%22%3D%22viewpoint%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A way[%22historic%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A way[%22tourism%22%3D%22information%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A way[%22information%22%3D%22office%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A way[%22amenity%22%3D%22townhall%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A way[%22amenity%22%3D%22place_of_worship%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A relation[%22tourism%22%3D%22caravan_site%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A relation[%22amenity%22%3D%22parking%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A relation[%22amenity%22%3D%22drinking_water%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A relation[%22amenity%22%3D%22toilets%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A relation[%22tourism%22%3D%22picnic_site%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A relation[%22tourism%22%3D%22camp_site%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A relation[%22leisure%22%3D%22picnic_table%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A relation[%22amenity%22%3D%22shower%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A relation[%22tourism%22%3D%22viewpoint%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A relation[%22historic%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A relation[%22tourism%22%3D%22information%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A relation[%22information%22%3D%22office%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A relation[%22amenity%22%3D%22townhall%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A relation[%22amenity%22%3D%22place_of_worship%22]( 47.36557,-1.92603,47.37585,-1.9028);%0A);%0A(._;%3E;);%0Aout body;&info=QgisQuickOSMPlugin


Environment

  • QuickOSM version: 2.1.1
  • QGIS version: 3.24.2
  • OS: Win10
@cedivers cedivers added the bug An identified bug label Oct 30, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug An identified bug
Projects
None yet
Development

No branches or pull requests

1 participant