Opened 7 years ago

Closed 7 years ago

Last modified 7 years ago

#5355 closed defect (fixed)

Graveyard media don't return serializable actors

Reported by: ayleph Owned by:
Priority: critical Milestone: 0.9.0
Component: programming Keywords: api, json, graveyard
Cc: tsyesika Parent Tickets:

Description

Related to #5354, entries in core_graveyard don't return a serializable actor. Instead, I get something like below in server logs when trying to pull from the inbox.

TypeError: <LocalUser #5 verified user "machalus"> is not JSON serializable

As a temporary hack, I hardcoded the graveyard actor as shown below. After doing so, pumpa finally was able to pull my inbox and load media and comments.

diff --git a/mediagoblin/db/models.py b/mediagoblin/db/models.py
index 0de14b4..8af520d 100644
--- a/mediagoblin/db/models.py
+++ b/mediagoblin/db/models.py
@@ -1566,7 +1566,8 @@ class Graveyard(Base):
         return {
             "id": self.public_id,
             "objectType": self.object_type,
-            "actor": self.actor(),
+            "actor": "bob",
             "published": deleted.isoformat(),
             "updated": deleted.isoformat(),
             "deleted": deleted.isoformat()

Subtickets

Change History (4)

comment:1 Changed 7 years ago by ayleph

Milestone: 0.8.1

comment:2 Changed 7 years ago by Christopher Allan Webber

Owner: set to tsyesika
Status: newin_progress

Let's have Jessica look at this when she gets back next week. I'm assigning to her.

comment:3 Changed 7 years ago by Jessica Tallon

Owner: tsyesika deleted
Resolution: fixed
Status: in_progressclosed

This has been fixed with 89068c2.

comment:4 Changed 7 years ago by Christopher Allan Webber

Milestone: 0.8.20.9.0

All 0.8.2 tickets are being rolled over to 0.9.0

Note: See TracTickets for help on using tickets.