Danbooru

[Bug] convenient_arm only returns 19 posts

Posted under Bugs & Features

Recently, when I was thinking of creating a convenient arm tag because of post #1825757, I learned it already exists. Then, I started to populate the tag, however, during this process I noticed that there's a glitch when searching for posts with this tag. If you search convenient_arm, the search only shows 19 of the posts with the tag, even though I know there's more than 19.

You can get the full search results by searching convenient_arm status:all despite that fact that, as of the creation of this topic, only one image is deleted. Yet, the tag still indicates there are only 19 images even though I'm counting 33 right now.

When a tag is added to a post, the tag count is updated in the background as a background job. This is why it sometimes takes a couple seconds for the tag count to update after editing a post.

You can see the backlog of background jobs at /delayed_jobs. Apparently the job processor went down yesterday so we have a backlog of 1.8 million jobs and growing (!) right now. Pinging @albert.

Mikaeri said:

This is happening for every tag right now, the counts aren't updating correctly on the view. Dunno what's causing it, but its there.

Really? When I noticed it yesterday, I assumed it might have been the server lagging because of all the large bulk updates you guys were approving with footwear and neckwear. This happens sometimes on Wikia when I run too many AWB updates and upload tons of images at once, and sometimes I become unable to unfollow a page for some time. That's why I didn't report it immediately, as I assumed it would be gone by today.

But, this has been happening for all tags!? How long?

Also, I noticed that when I edit the tags in an image, when I add a tag, the number of images with this tag doesn't update in the autocomplete menu in the edit box when I edit another image to add the same tag. This is something I noticed when taking on the large task of filling the National Shin Ooshima School uniform, which I have yet to completed due to the amount of images (like, almost every Vividred Operation image depicts the uniform, I think).
The number of images in the tag in the edit box doesn't update until the next day, I think, despite updating in the list of tags of the image. I always assumed this was some cache thing, but is it part of the bug?

EDIT:

evazion said:

When a tag is added to a post, the tag count is updated in the background as a background job. This is why it sometimes takes a couple seconds for the tag count to update after editing a post.

You can see the backlog of background jobs at /delayed_jobs. Apparently the job processor went down yesterday so we have a backlog of 1.8 million jobs and growing (!) right now. Pinging @albert.

Sorry, I started typing before you posted. Is that realy all there is to it? Because I think at least the search returns all images in normal circumstances.

G-SANtos said:

@albert

It's delaying again, probably because of the bulk reversal on topic #14395, page 10. Better put the site on maintenance for some hours.

Nah, there was no bulk reversal. Only a mass un-alias, which isn't the same thing. I did a lot updates myself to reverse it, but it was only about 20K post changes over several hours.

It was the tag category changes that did it. For each tag category change, it has to go to every post that has that tag and update its tag count.

http://danbooru.donmai.us/tags?search%5Bcategory%5D=5&search%5Border%5D=count

As you can see, that's an awful lot of posts to update, causing the delayed jobs queue to hang again.

I already created issue #3370 for it.

Updated

1