AO3 News

Post Header

Published:
2020-06-24 13:39:57 -0400
Tags:

In this batch of fixes, we rewrote large parts of the code that updates work and bookmark listings when a tag is wrangled (e.g. made canonical or added as a synonym of another tag). Now the process is much less error-prone and we have some shiny new troubleshooting tools in case anything goes wrong. \o/ We also fixed several issues concerning hit counts and notification emails, improved our automated test suite, and generally tidied up a bit around the place.

Special thanks to new contributors J, Stephen Burrows, and Tyme!

Credits

  • Coders: Alix R, cosette, dlhardin, DreamSea, J, james_, redsummernight, Sarken, Stephen Burrows, teyla, ticking instant, Tyme
  • Code reviewers: bingeling, james_, redsummernight, Sarken, ticking instant
  • Testers: Alyndra, Booksarelife, C. Ryan Smith, Chelsea Eidbo, cosette, Danielle Strong, GoldenFalls, james_, lydia-theda, mumble, Paula, QED, Qem, Rebecca Sentance, redsummernight, Sammie Louise, Sarken, teyla, ticking instant

Details

0.9.286

Focus on hit counts and automated tests, deployed on April 22.

  • [AO3-4622] - The hit count preferences hadn't been working properly for many years, so we removed them.
  • [AO3-5905] - We've rewritten the hit count code so we can count hits while caching works. Check out our post Guest hit counting is coming back for more information on hit counts.
  • [AO3-4750] - We added a link to work blurbs that will take you to a work's latest chapter.
  • [AO3-5757] - We've updated the gem that runs our feature tests.
  • [AO3-5338] - In many of our automated tests, we use factories to create test data. The most frequently used work factory turned out to be creating drafts, not posted works, which wasn't great: in most cases, we want to know how our code interacts with the latter. We've updated the factory and the tests to run on works unless we specifically need to test drafts.
  • [AO3-5921] - Some of our automated tests would occasionally fail due to timing issues, so we made some changes to make them less flaky.

0.9.287

Focus on tag wrangling and filtering, deployed on May 28.

The always wonderful ticking instant -- who you may remember as the coder responsible for the massive speed improvements for gift exchange matching in 2016 -- rewrote some of the code responsible for making sure works and bookmarks are included in the proper tag listings.

The previous version of the code was subject to race conditions, so sometimes (e.g. during periods of heavy load) changes to the way a tag was wrangled wouldn't affect which listings a work (or bookmark) with that tag was included in. ticking instant has rewritten the code so it won't be subject to those race conditions and provided new troubleshooting tools in case something else goes wrong.

  • [AO3-5617], [AO3-4965], [AO3-3830] - Works would sometimes not appear in the tag listings after synning a tag to canonical, or making a tag into a canonical. Now they do.
  • [AO3-5618] - When an admin syns a canonical to another canonical (decanonizing the first canonical in the process), all of the connections (e.g. fandoms) from the formerly canonical tag are supposed to move to the new canonical. They were just vanishing, though. Now they'll transfer correctly.
  • [AO3-3768] - When a wrangler makes a tag into a synonym, the syn is supposed to pick up information from the canonical tag (e.g. a synned fandom tag should acquire the canonical fandom's media tag). It wasn't always doing that, but now it should be.
  • [AO3-4077] - If a wrangler removed a subtag from a metatag that had its own metatag, the works from the subtag would still stick around in the work listing for the metatag's metatag. Now the works will disappear, since the relationship between the two tags no longer exists.
  • [AO3-5343] - Wranglers would get an error when adding a metatag to a tag that had two levels of subtags. Now they can do that.
  • [AO3-5432] - Decanonizing a tag without first removing its metatags would sometimes fail to remove the formerly canonical tag's works or bookmarks from the metatag's listings. Now the works are removed.
  • [AO3-5433] - In certain cases, if an admin attempted to edit an external work to simultaneously add and remove a tag, the external work's bookmarks would stay on in the listing for the old tag and not appear in the listing for the new one. Now the bookmarks go where they're supposed to.
  • [AO3-5507] - Imagine, if you will, a tag tree structured thusly: a metatag (e.g. Animals) with the direct subtags A and B (e.g. Cats and Dogs), and then another subtag of subtag A (e.g. Ragdoll Cats). Now imagine posting a work tagged with both Dogs and Ragdoll Cats, making it appear in the Animals tag. But then, one day, a wrangling change comes! We remove Ragdoll Cats as a subtag of Cats. And like magic, our work vanishes from the listings for the Animals tag. Except we don't want magic here: our work is still tagged with Dogs, which is still connected to our Animals metatag. We've put an end to these sorts of disappearing acts, and made any works affected by this bug reappear in their proper place.
  • [AO3-5508] - Let's say we have the metatag Foods with the two subtags Fruits and Vegetables, and the tag Tomatoes is subtagged to both Fruits and Vegetables. Then, one day, we decide vegetables are not food (just kidding, veggies, we love you! πŸ₯¦), and we remove the Vegetables subtag from the Foods metatag. Furthermore, we decide tomatoes are not vegetables, and we remove the Vegetables metatag from the Tomatoes subtag. During all this wrangling, we were losing the connection between the Tomatoes tag and the Foods tag, which would keep new works with the Tomatoes tag from appearing in the Foods tag. Now we've made sure that connection stays intact, so anything posted with the Tomatoes tag will -- in our hypothetical scenario -- appear in the Foods tag as well (because Tomatoes are still Fruits). We've also fixed the problem on any existing works.
  • [AO3-5945] - Systems updated some settings to make sure users who were browsing the insecure version of the Archive wouldn't get bumped to the secure version.
  • [AO3-5783] - We removed an old rake task.
  • [AO3-5943] - We've told the tool that informs us about code style violations that there are some things we'd like it not to complain about.
  • [AO3-5927] - Some of our automated tests for the autocomplete would occasionally fail because the animation effect took too long to fire, meaning the autocomplete options weren't fully expanded by the time the tests started looking for them. We've disabled the animations to prevent these failures.

0.9.288

Focus on miscellaneous bug fixes and infrastructure updates, deployed on June 17.

  • [AO3-4874] - We were stripping HTML and paragraph breaks out of summaries in subscription emails, which could make them hard to read. We've stopped doing that.
  • [AO3-5332] - If a co-creator who was added only to one or more chapters (and not as co-creator of the whole work) removed themselves from the last chapter they co-created, they would still be co-creator for the whole work, with editing permissions. That clearly needed to be fixed, so we did.
  • [AO3-5721] - It wasn't possible to delete a challenge from a collection unless you had JavaScript enabled. We've made it work if you have JavaScript disabled.
  • [AO3-5938] - In the line of stats (words, comments, kudos, etc.) in a bookmark blurb, the links had lost their bottom border, making it impossible to tell that they were links. We've added some room for the borders, making the numbers pop again.
  • [AO3-5736] - When you create an account and try to log in before you have confirmed your email address, you now receive a more helpful error message, i.e. "Please check your email for the confirmation link."
  • [AO3-5266] - We now enforce HTTPS for embeds from Vidders.net.
  • [AO3-5940] - To prevent failures when sending out notifications, we are now making sure that all necessary information has been committed to the database (and not merely saved by the user, possibly needing a second to make its way into the system) before we put the email together and add it to the mailer queue.
  • [AO3-5965] - When a request comes in from a user with an expired session, we respond with an error, but we didn't do this for all possible request types. That caused errors on our end, especially due to the requests going to the hit counter. We're handling those in the proper manner now.
  • [AO3-5948] - All our cookies now last a maximum of one year.
  • [AO3-5828] - We have added the ability to safelist IP addresses so they won't be affected by restrictions (e.g. on the number of database requests per minute) that we impose through the Rack::Attack gem.
  • [AO3-5936] - On the actual Archive, we use a type of caching that we weren't using in our automated tests. Because we want our tests to resemble our actual set up as closely as possible, we've started using that sort of caching there as well.
  • [AO3-5960] - We updated the actionpack-page_caching gem to version 1.2.2.
  • [AO3-5971] - We updated the websocket-extensions gem to version 0.1.5.
  • [AO3-5422], [AO3-5423], [AO3-5425], [AO3-5426] - We removed unused code from a number of places. Yay, tidying!