Synonyms and canonicals do not take and works do not show

Description

Different wranglers have reported encountering these issues since the 29th of March.

Normally, after synning a tag in the edit page (by adding an existing canonical tag in the "Synonym of" box and saving, the fandom of the canonical tag will be attached automatically in the "Fandoms" box. After 1-10 minutes the works will show at the works page e.g. (edit page) (work page). Works would also show after canonising tags by ticking the "Canonical" box.

Occasionally we will encounter issues especially during high archive usage times. But for the most parts, everything takes after a few minutes.

However, for the past couple of weeks, works have repeatedly not show nor does the fandoms get attached. It takes many tries (manually desynning then resynning, or decanonising then recanonising) to get works to show, even during archive low usage periods. A staff also reported issues during staff allocated days (Wed/Fri).

For syns with more than one work, there are some cases where only some of the works show but others don't. Reindexing the works does not fix the problem.

Activity

Show:
ticking instant
April 27, 2020, 2:06 AM

This issue is basically the same as , except that it specifically seems to have gotten much worse after the taggings count changes in .

I think the reason it got worse was because the taggings count is displayed on the tag edit page. When the taggings count for a small tag is displayed, it’s recalculated and cached, and queued for writing to the database in batches. This happens even if the taggings count hasn’t changed.

This means that very soon after viewing the tag edit page – that is, soon after visiting the page you need to visit in order to make a tag canonical or add a synonym – the tag is updated in a batch transaction that might cause any other transactions involving that tag to be very slow. I believe that is caused by jobs being queued before the end of the transaction. The competition between the batch update and the canonical/synonym update probably caused even longer delays between when the job was queued (in the before_update callback) and when the data was committed to the database.

Hopefully resolving should be sufficient to fix this even without updating the taggings count code to reduce the number of updates.

teyla
May 10, 2020, 3:26 PM
  1. created four new freeform tags on new works

  2. synned them to a canonical in a specific fandom

  3. checked canonical for new works: works shown

  4. checked tag edit pages for fandom: fandom transferred

This seems to work. I’ve not come across this issue testing other of the tag tickets currently in QA, either.

Sarken
May 11, 2020, 5:59 AM
  1. Created four new works with four new fandom tags. Also bookmarked one of the works for fun.

  2. Made one of the tags canonical. Its work appeared in it right away.

  3. On the canonical’s edit page, I added the other three tags as syns. (Also added some non-canonical characters to it because, hey, what the heck.)

  4. While I was waiting to see if the works would show up, I posted another work with one of the new syns. It appeared right away on the works page for the canonical.

  5. After about six minutes, all of the works and bookmarks appeared on the canonical’s work and bookmark listings. On the tags' edit pages, fandom was correctly attached to the character tags and the syns all listed the canonical as the canonical.

Looks good!

Assignee

ticking instant

Reporter

phoenixacid

Roadmap

Tag Wrangling

Priority

Medium

Affects versions

None

Fix versions

Components

BackEnd

Difficulty

Medium

Required Access Level

Tag Wrangler

Epic Link

Milestone

Internal 0.9
Configure