Following problem:
I think it relates to UTF8.
I read some data from a public API with network.request().
The data gets returned as JSON data.
Now I want to compare a text string from within the data with a hardcoded string.
I.e. the german word “Außen” which has a special character in it.
So in the JSON data (which I saved to DocumentsDirectory and read it again), I can see the word “Außen”.
Let’s say the JSON decoded table path to the loaded word is like this:
data.devices.module.name
So when I do this
print( data.devices.module.name )
it properly prints the word “Außen” to console.
But then when I try to compare it like this
if data.devices.module.name == "Außen"
it gives me a false result.
Any hints how to solve this?