[bug] Potentially incorrect date format in last_status_at
#637
Labels
No labels
approved, awaiting change
bug
configuration
documentation
duplicate
enhancement
extremely low priority
feature request
Fix it yourself
help wanted
invalid
mastodon_api
needs docs
needs tests
not a bug
planned
pleroma_api
privacy
question
static_fe
triage
wontfix
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: AkkomaGang/akkoma#637
Loading…
Add table
Reference in a new issue
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?
Your setup
From source
Extra details
NixOS unstable
Version
3.9.3
PostgreSQL version
14
What were you trying to do?
Retrieve a user’s timeline as part of the NixOS module test (see https://github.com/NixOS/nixpkgs/blob/master/nixos/tests/akkoma.nix#L36) using toot (https://github.com/ihabunek/toot/).
What did you expect to happen?
Get a list of posts.
What actually happened?
Toot chokes on the
last_status_at
account field, expecting a date (like2023-08-30
), but receiving a date/time without timezone (2023-08-30T11:40:00
):I confirmed that this is triggered by toot expecting a date instead of date/time for the
last_status_at
field of the account structure: https://github.com/ihabunek/toot/blob/master/toot/entities.py#L64I am uncertain whether this is an issue in Akkoma, toot, or both.
Mastodon appears to provide a full date/time with decimal fraction and timezone (like
2023-08-30T11:40:00.000Z
, see https://docs.joinmastodon.org/methods/statuses/), which would also break toot.Logs
No response
Severity
I cannot use the software
Have you searched for this issue?
Corresponding toot issue: https://github.com/ihabunek/toot/issues/399
That example is wrong according to their own documentation -
Status
includes anAccount
which haslast_status_at
defined as "String (ISO 8601 Date), or null if no statuses". Akkoma is sending the wrong format and toot appears to be doing the correct thing according to the MastoAPI docs.That is consistent with the Mastodon code, as far as I can see.
I opened an issue regarding the discrepancy in the documentation: https://github.com/mastodon/mastodon/issues/26843