Entry tags:
Code Tour, February 25 - March 9, 2011
Hi, Dreamwidth Devistas! Got a backend-heavy code tour for you this week, so let's get to it! Also, a welcome back to
wyntarvox, who gives us five patches this go-round :)
Bug 3542: some AJAX endpoints can return invalid JSON
Category: Misc UI/Frontend
Patch by:
fu
Description: Things like same-page comment deletion are handled by AJAX endpoints. This is really a future-proofing bug - Dreamwidth is starting to use jQuery (a JavaScript code library that makes it easy to use nifty front-end interaction), and jQuery is a bit picky about the format in which it accepts certain code, so some Cleanup Was Done.
Bug 3533: Lots of unused JS files in the js repo
Category: Modernization
Patch by:
fu
Description: Doing a back-end tidy up - tossing about six dozen inherited and unused files in the trash.
Bug 3487: improve the workflow while using the poll creator
Category: Misc UI/Frontend
Suggested by:
ratcreature
Patch by:
yvi
Description: Tweaks to the poll creator. Previously, when adding a new question in the poll creator, inserting a question scrolled you back to the top of the page, requiring you scroll back down to find the question you were trying to enter. Now, inserting a question scrolls you to the right place.
Bug 3343: Poll Creator: unclear error message when answer exceeds 255 characters
Category: User documentation
Patch by:
denise
Description: Minor text change for an error message in the Poll Creator; this actually changes it in the repository for anybody running their own Dreamwidth clone.
Bug 3500: User tag should allow Twitter as an option
Category: Misc UI/Frontend
Suggested by:
eleanorjane
Patch by:
denise
Description: Very soon, as of the next code push, you will be able to type <user name=ursamajor site=twitter.com> and it will create a link to that Twitter, like so:
ursamajor, except the userhead that's there right now will actually be a Twitter-userhead. Also, the intrepid
denise would like you all to know, "Rockin' robin, tweet, tweetely-tweet."
Bug 3519: Use of uninitialized value in weblib.pl
Category: Misc Backend
Patch by:
denise
Description: When an entry lacked a subject, this caused a behind-the-scenes error that spams the server's error logs. Many entries lack subjects intentionally; this condition is not an error, so there will no longer be tantrums thrown in the error logs for lack of a subject.
Bug 3539: Make sure method is GET/POST ( unless the controller handles more )
Category: Routing/TT
Patch by:
exor674 and
fu
Description:
Crowdsourced from #dreamwidth: Basically, there are certain protocols for transmitting information across the internet. The major ones used on Dreamwidth are GET and POST. The routing-thing was accepting stuff being sent using not just these two protocols, but pretty much any protocol you could make up out there - "it also accepted BLURG, or HAMSTERS, or GIVEMETHEPAGEDAMNIT." So this bug makes the routing-thing be more picky about through which protocols it will accept stuff.
Bug 3547: Need a way to cleanly call controllers from tests
Category: Unknown
Patch by:
exor674
Description: There are many things that have to be done in the process of "calling a controller through routing in a non-web environment." (In a web environment, other code, including the web server, deals with it for you.) So organizing these things into one place is useful.
Bug 3305: More ID at the shop transfer confirmation
Category: Payments
Suggested by:
zvi
Patch by:
kareila
Description: Adds the default icon and "display name" for a given user on the confirmation page when you are transfering Dreamwidth points to them, as additional information for you to double-check their identity before proceeding.
Bug 3531: Old JS libraries don't play nice with other libraries on the page
Category: Modernization
Patch by:
fu
Description: We are making way for jQuery, JavaScript code library of Light. (Then how come you had to cast Magic Missile?)
Bug 3545: Make libfunctions > jquery test complete in IE
Category: Unknown
Patch by:
fu
Description: IE thinks it's a special snowflake, and doesn't have to implement a function that's listed in the standard for JavaScript. This patch gets around that.
Bug 3528: jQuerify password hashing JS for login
Category: Modernization
Patch by:
fu
Description: Makes the code that keeps your password secure on login compatible with the (previously-mentioned in bug 3542) jQuery JavaScript library.
Bug 3475: More scale options allowed in polls
Category: Journal contents
Suggested by:
yvi
Patch by:
yvi
Description: Adds one more step to the "scale" option in polls - goes from 20 to 21. So, for example, if you wanted a scale that ran from 0% to 100% in 5% increments, there are now enough "steps" to allow for this.
Bug 3548: t/routing.t is getting quite large, split it up.
Category: Routing/TT
Patch by:
exor674
Description: In "QA testing" (quality assurance), Dreamwidth runs what are known as "unit tests." One of these tests, the one that makes sure that routing is working, was getting on the large side, so the test has been split into multiple parts.
Bug 3551: t/wtf.t fails in clustered setups
Category: Circle/Relationships
Patch by:
fu
Description: Another "unit test" error - the test was broken; now it's fixed.
Bug 3549: Make automatic /foo/ == /foo/index work on '/index'
Category: Routing/TT
Patch by:
exor674
Description: Prep work for when the root index page (the one at http://dreamwidth.org/ ) is ported over to the new templating system, the URL system will behave properly.
Bug 1200: separate interest search results for communities vs. users
Category: Search
Patch by:
kareila
Description: Sweet! This splits up interest search results for communities vs. users in a more readable fashion.
Bug 3552: Make /create-url.t report failures on more useful line
Category: Misc Backend
Patch by:
exor674
Description: Unit tests report failures - but this unit test was complex enough that the way it was reporting the failure made it hard to see exactly where things went wrong. This patch helps pinpoint where the issues are when a test fails.
Bug 3553: Tests which use convenience methods report failures unhelpfully
Category: Misc Backend
Patch by:
fu
Description: Same as Bug 3552, just for a different test.
Bug 3529: Crossposts don't delete
Category: Crossposter
Patch by:
allen
Description: Crossposted entries weren't deleting on the remote site, and there wasn't an alert for this. Now they are and there is!
Bug 3556: feed-atom.t fails when SITENAMEABBREV is not DW
Category: Misc Backend
Patch by:
kareila
Description: Another unit test error! This affects people running their own Dreamwidth clones - the unit test was failing when the variable SITENAMEABBREV was changed from the default "DW" (for "Dreamwidth") to reflect the desired abbreviation for the name of the clone.
Bug 3554: enforce minimum version for Test::More & HTML::TokeParser
Category: Site Administration
Patch by:
kareila
Description: Dreamhacks were running older versions of some backend modules than the ones on the live Dreamwidth site; now updated to match.
Bug 2257: Recognize authors in different formats in the feeds we pull in
Category: Feeds
Patch by:
kareila
Description: Adding different standard tags for recognizing post authors on RSS and Atom feeds that we syndicate in, so that credit can be attributed more frequently.
Bug 3378: Too many styles error does not tell you how many styles you have
Category: Misc UI/Frontend
Patch by:
wyntarvox
Description: "You have too many styles! But we're not going to tell you how many styles you have or what the limit on the number of styles is inline!" Okay, yes, we will. :)
Bug 2917: Mood becomes alt text for default icon
Category: Journal contents
Patch by:
wyntarvox
Description: When the default icon was used on a post by selecting "(default)" from the dropdown menu, the title-text didn't display the icon keyword, but the "mood" associated with the post instead. This patch makes it so that the title-text uses "(default)" (the "keyword" selected) rather than the mood.
Bug 3560: Tests shouldn't need the webserver running to run
Category: Modernization
Patch by:
fu
Description: One of the tests was trying to run on the webserver when it doesn't need to; it got told to stop doing that.
Bug 3493: Link between Manage Circle and My Account Settings: Notifications
Category: Site Layout/Navigation
Suggested by:
azurelunatic
Patch by:
wyntarvox
Description: "Subscription" applies to a couple of different major functions on Dreamwidth - both the behavior that lets you see someone on your reading page, and the behavior that lets you get notifications in your email or inbox when Various Things Happen. There are now crosslinks between http://www.dreamwidth.org/manage/settings/?cat=notifications and http://www.dreamwidth.org/manage/circle/edit to help address this confusion when it happens.
Bug 3557: Auto-discovery when creating a feed should use the first available feed, not the last
Category: Feeds
Patch by:
fu
Description: Usual practice on external pages that have corresponding RSS feeds is to list the first feed in a list of available feeds as the "preferred" feed; our code was using the last feed. Switched to use the first feed.
Bug 3532: Cannot gift an unknown random user
Category: Payments
Patch by:
wyntarvox
Description: Whoops, we accidentally removed the link to gift an unknown random user awhile back. It's been put it back now!
Bug 3394: "Refresh" link at the bottom of the Inbox
Category: Inbox/Notifications
Suggested by:
peoppenheimer
Patch by:
wyntarvox
Description: "The "Refresh" link currently exists only at the top of the Inbox. If I had a nickel for every time I have scrolled to the top of the page in order to refresh it ..." Same here, so I'm glad that a "Refresh" link is added to the bottom of the Inbox to save me that scrolling. :)
Bug 3243: Need consistent styling across the site
Category: Misc UI/Frontend
Patch by:
fu
Description: Cleaning up the code for the various site skins - making them more consistent with each other for easier future development and maintenance.
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Bug 3542: some AJAX endpoints can return invalid JSON
Category: Misc UI/Frontend
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: Things like same-page comment deletion are handled by AJAX endpoints. This is really a future-proofing bug - Dreamwidth is starting to use jQuery (a JavaScript code library that makes it easy to use nifty front-end interaction), and jQuery is a bit picky about the format in which it accepts certain code, so some Cleanup Was Done.
Bug 3533: Lots of unused JS files in the js repo
Category: Modernization
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: Doing a back-end tidy up - tossing about six dozen inherited and unused files in the trash.
Bug 3487: improve the workflow while using the poll creator
Category: Misc UI/Frontend
Suggested by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: Tweaks to the poll creator. Previously, when adding a new question in the poll creator, inserting a question scrolled you back to the top of the page, requiring you scroll back down to find the question you were trying to enter. Now, inserting a question scrolls you to the right place.
Bug 3343: Poll Creator: unclear error message when answer exceeds 255 characters
Category: User documentation
Patch by:
![[staff profile]](https://www.dreamwidth.org/img/silk/identity/user_staff.png)
Description: Minor text change for an error message in the Poll Creator; this actually changes it in the repository for anybody running their own Dreamwidth clone.
Bug 3500: User tag should allow Twitter as an option
Category: Misc UI/Frontend
Suggested by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Patch by:
![[staff profile]](https://www.dreamwidth.org/img/silk/identity/user_staff.png)
Description: Very soon, as of the next code push, you will be able to type <user name=ursamajor site=twitter.com> and it will create a link to that Twitter, like so:
![[staff profile]](https://www.dreamwidth.org/img/silk/identity/user_staff.png)
Bug 3519: Use of uninitialized value in weblib.pl
Category: Misc Backend
Patch by:
![[staff profile]](https://www.dreamwidth.org/img/silk/identity/user_staff.png)
Description: When an entry lacked a subject, this caused a behind-the-scenes error that spams the server's error logs. Many entries lack subjects intentionally; this condition is not an error, so there will no longer be tantrums thrown in the error logs for lack of a subject.
Bug 3539: Make sure method is GET/POST ( unless the controller handles more )
Category: Routing/TT
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description:
exor674: okay, i have no idea how to explain that in human
ursamajor: ahahaha, that makes me feel better, honestly :D
Crowdsourced from #dreamwidth: Basically, there are certain protocols for transmitting information across the internet. The major ones used on Dreamwidth are GET and POST. The routing-thing was accepting stuff being sent using not just these two protocols, but pretty much any protocol you could make up out there - "it also accepted BLURG, or HAMSTERS, or GIVEMETHEPAGEDAMNIT." So this bug makes the routing-thing be more picky about through which protocols it will accept stuff.
Bug 3547: Need a way to cleanly call controllers from tests
Category: Unknown
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: There are many things that have to be done in the process of "calling a controller through routing in a non-web environment." (In a web environment, other code, including the web server, deals with it for you.) So organizing these things into one place is useful.
Bug 3305: More ID at the shop transfer confirmation
Category: Payments
Suggested by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: Adds the default icon and "display name" for a given user on the confirmation page when you are transfering Dreamwidth points to them, as additional information for you to double-check their identity before proceeding.
Bug 3531: Old JS libraries don't play nice with other libraries on the page
Category: Modernization
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: We are making way for jQuery, JavaScript code library of Light. (Then how come you had to cast Magic Missile?)
Bug 3545: Make libfunctions > jquery test complete in IE
Category: Unknown
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: IE thinks it's a special snowflake, and doesn't have to implement a function that's listed in the standard for JavaScript. This patch gets around that.
Bug 3528: jQuerify password hashing JS for login
Category: Modernization
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: Makes the code that keeps your password secure on login compatible with the (previously-mentioned in bug 3542) jQuery JavaScript library.
Bug 3475: More scale options allowed in polls
Category: Journal contents
Suggested by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: Adds one more step to the "scale" option in polls - goes from 20 to 21. So, for example, if you wanted a scale that ran from 0% to 100% in 5% increments, there are now enough "steps" to allow for this.
Bug 3548: t/routing.t is getting quite large, split it up.
Category: Routing/TT
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: In "QA testing" (quality assurance), Dreamwidth runs what are known as "unit tests." One of these tests, the one that makes sure that routing is working, was getting on the large side, so the test has been split into multiple parts.
Bug 3551: t/wtf.t fails in clustered setups
Category: Circle/Relationships
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: Another "unit test" error - the test was broken; now it's fixed.
Bug 3549: Make automatic /foo/ == /foo/index work on '/index'
Category: Routing/TT
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: Prep work for when the root index page (the one at http://dreamwidth.org/ ) is ported over to the new templating system, the URL system will behave properly.
Bug 1200: separate interest search results for communities vs. users
Category: Search
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: Sweet! This splits up interest search results for communities vs. users in a more readable fashion.
Bug 3552: Make /create-url.t report failures on more useful line
Category: Misc Backend
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: Unit tests report failures - but this unit test was complex enough that the way it was reporting the failure made it hard to see exactly where things went wrong. This patch helps pinpoint where the issues are when a test fails.
Bug 3553: Tests which use convenience methods report failures unhelpfully
Category: Misc Backend
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: Same as Bug 3552, just for a different test.
Bug 3529: Crossposts don't delete
Category: Crossposter
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: Crossposted entries weren't deleting on the remote site, and there wasn't an alert for this. Now they are and there is!
Bug 3556: feed-atom.t fails when SITENAMEABBREV is not DW
Category: Misc Backend
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: Another unit test error! This affects people running their own Dreamwidth clones - the unit test was failing when the variable SITENAMEABBREV was changed from the default "DW" (for "Dreamwidth") to reflect the desired abbreviation for the name of the clone.
Bug 3554: enforce minimum version for Test::More & HTML::TokeParser
Category: Site Administration
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: Dreamhacks were running older versions of some backend modules than the ones on the live Dreamwidth site; now updated to match.
Bug 2257: Recognize authors in different formats in the feeds we pull in
Category: Feeds
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: Adding different standard tags for recognizing post authors on RSS and Atom feeds that we syndicate in, so that credit can be attributed more frequently.
Bug 3378: Too many styles error does not tell you how many styles you have
Category: Misc UI/Frontend
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: "You have too many styles! But we're not going to tell you how many styles you have or what the limit on the number of styles is inline!" Okay, yes, we will. :)
Bug 2917: Mood becomes alt text for default icon
Category: Journal contents
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: When the default icon was used on a post by selecting "(default)" from the dropdown menu, the title-text didn't display the icon keyword, but the "mood" associated with the post instead. This patch makes it so that the title-text uses "(default)" (the "keyword" selected) rather than the mood.
Bug 3560: Tests shouldn't need the webserver running to run
Category: Modernization
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: One of the tests was trying to run on the webserver when it doesn't need to; it got told to stop doing that.
Bug 3493: Link between Manage Circle and My Account Settings: Notifications
Category: Site Layout/Navigation
Suggested by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: "Subscription" applies to a couple of different major functions on Dreamwidth - both the behavior that lets you see someone on your reading page, and the behavior that lets you get notifications in your email or inbox when Various Things Happen. There are now crosslinks between http://www.dreamwidth.org/manage/settings/?cat=notifications and http://www.dreamwidth.org/manage/circle/edit to help address this confusion when it happens.
Bug 3557: Auto-discovery when creating a feed should use the first available feed, not the last
Category: Feeds
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: Usual practice on external pages that have corresponding RSS feeds is to list the first feed in a list of available feeds as the "preferred" feed; our code was using the last feed. Switched to use the first feed.
Bug 3532: Cannot gift an unknown random user
Category: Payments
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: Whoops, we accidentally removed the link to gift an unknown random user awhile back. It's been put it back now!
Bug 3394: "Refresh" link at the bottom of the Inbox
Category: Inbox/Notifications
Suggested by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: "The "Refresh" link currently exists only at the top of the Inbox. If I had a nickel for every time I have scrolled to the top of the page in order to refresh it ..." Same here, so I'm glad that a "Refresh" link is added to the bottom of the Inbox to save me that scrolling. :)
Bug 3243: Need consistent styling across the site
Category: Misc UI/Frontend
Patch by:
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Description: Cleaning up the code for the various site skins - making them more consistent with each other for easier future development and maintenance.
no subject
no subject
(and I just realised that I don't think we have any equivalent change to alt text to specify that. But I'm not sure how to designate it in the alt text, because not all such links will be broken.)
no subject
no subject
no subject
no subject
Also, I'm awarding you the Best Description Award for bug 3539 :D
Bug 3529 is pretty awesome too.