A # breaks the feeds.json file #9
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Hmm, maybe a short replacement search/replace can be done? Or are there other ways in Python to check if a JSON object is "safe"?
the python3 json library can already do that with the load and loads function.
https://pynative.com/python-json-validation/
I think the trouble is updating the rss feeds to the simple database using db.update on line 41 of feedtools.py
I don't think that function cares about valid json. So load everything into a valid json object using json.load(tmp) and then update that to the SimpleDatabase
in my opinion this is always a better approach than small fixes by hand, now its a #, next time its a "\/". json.loads does that all for you perfectly.