Open zetasyanthis opened 8 years ago
Actually, I should note that this is with the small mod from here inserted to let it run at all... That could be layering to cause this issue, but I don't quite understand the protocol well enough to determine if that's the cause. (Apologies if it is.)
Finally getting back to my own project that uses this and it looks like we've got another issue with dreamwidth.org compatibility.
I'm not quite sure what the right thing to do is here. Looks like the API is kicking out 2015-09-24 23:22:44.000000. Sticking a [:19] to force trim the date string down to just seconds seems to work, but I'm not sure if that's a good solution.
Traceback (most recent call last): File "./main.py", line 238, in
main() File "./main.py", line 228, in main db_session=tag_db.session File "/home/zeta/repos/projects/myarchive/src/myarchive/modules/ljlib.py", line 131, in download_journals_and_comments ljapi.download_journals_and_comments(db_session=db_session) File "/home/zeta/repos/projects/myarchive/src/myarchive/modules/ljlib.py", line 60, in download_journals_and_comments nj = update_journal_entries(server=self._server, journal=self.journal) File "/usr/local/lib/python3.5/dist-packages/lj/backup.py", line 117, in update_journal_entries sync = server.getevents_syncitems(one_second_before(syncitems[0][1])) File "/usr/local/lib/python3.5/dist-packages/lj/backup.py", line 65, in one_second_before return str(datetime_from_string(s) - datetime.timedelta(seconds=1)) File "/usr/local/lib/python3.5/dist-packages/lj/backup.py", line 57, in datetime_from_string return datetime.datetime.strptime(s, "%Y-%m-%d %H:%M:%S") File "/usr/lib/python3.5/_strptime.py", line 510, in _strptime_datetime tt, fraction = _strptime(data_string, format) File "/usr/lib/python3.5/_strptime.py", line 346, in _strptime data_string[found.end():]) ValueError: unconverted data remains: .000000
Dreamwidth is Live-Journal based and uses the same XML-RPC interface (maybe a slightly older version?). This should work, but blows up with the following error.
Note that oddly, ljdump doesn't blow up talking to dw, so it is possible for this to work, but ljdump is not nearly the fully featured library this is. I'm investigating what it's doing differently...