Closed rashamalek closed 1 year ago
Hi. thx for giving it a try, Would you mind sharing the version of iOS in use ? This error is kinda weird, it's like the whole export.xml isn't parse-able by the lib.. I will make a more verbose version that you could try, maybe that will give us more info about the error.
Sure,
phone is running iOS version 16.1
The export.xml seems to be parsed partially after running the ingester
container multiple times, (ofcourse each time failing), I can see some routes under workout-routes
dashboard, but still data is incomplete, also other two dashboards are completely empty.
and Here is the ingester log:
ingester_1 | opening Route 2022-05-16 5:03pm
ingester_1 | opening Route 2022-11-02 12:49pm
ingester_1 | opening Route 2022-12-22 10:48pm
...
...
...
ingester_1 | opening Route 2022-08-29 9:37am
ingester_1 | opening Route 2022-03-05 6:39pm
ingester_1 | opening Route 2023-01-07 2:22pm
ingester_1 | opening Route 2022-05-18 1:52pm
ingester_1 | Traceback (most recent call last):
ingester_1 | File "//app.py", line 147, in <module>
ingester_1 | process_health_data()
ingester_1 | File "//app.py", line 107, in process_health_data
ingester_1 | for _, elem in etree.iterparse(export_path):
ingester_1 | File "/usr/local/lib/python3.11/xml/etree/ElementTree.py", line 1249, in iterator
ingester_1 | yield from pullparser.read_events()
ingester_1 | File "/usr/local/lib/python3.11/xml/etree/ElementTree.py", line 1320, in read_events
ingester_1 | raise event
ingester_1 | File "/usr/local/lib/python3.11/xml/etree/ElementTree.py", line 1292, in feed
ingester_1 | self._parser.feed(data)
ingester_1 | xml.etree.ElementTree.ParseError: syntax error: line 156, column 0
applehealthgrafana_ingester_1 exited with code 1
Ok, so loading the workout routes from their folder works fine, but the health data export (which is another XML file export.xml) fails.. I can create a version that will dump the faulty line, but due to the private nature of the data, I would rather communicate with you through a more private medium. If that's alright with you, let me now how you prefer things to continue.
Hey @k0rventen we can continue the discussion my GitHub username a t gmail. had to write it this way to try to slow down spammers :)
I'm having the same problem with the same IOS version. @rashamalek were you able to solve the problem?
I found out that my export file was damaged. I tried to open it with web browser and was able to spot damaged lines.
After fixing it everything worked out great!
Trying to ingest the data, the ingester container fails due to a ParseError
The
export.zip
contains the following filesHere is the container status: