Releases: jessicarod7/XKCDAltTextBot
3.3.0
3.2.4
This update replaces the insecure yaml.load()
for loading environmental variables with yaml.safe_load()
.
As a heads up, at some point this summer, XKCDAltTextBot will transition to Twitter API v2.
3.2.3
This update performs a security update to urllib and some dependent libraries.
3.2.2
This update fixes a security vulnerability in PyYAML.
3.2.1
This update fixes a security vulnerability in urllib. It is strongly recommended to update to this version as soon as possible.
3.2.0
Making XKCDAltTextBot accessible
This update adds header support for Tweets, allowing for a customizable message to appear at the front of each tweet. For more info, read this new section in the wiki.
Behind the change
On a recent comic posting, Nicolas Steenhout started a discussion on how xkcd comics, and by extension this bot, don't use the alt
attribute of images as intended. Best practices are that the attribute should be used to describe the image in text, providing support for users with accessibility needs or slow internet connections. Instead, xkcd uses that field for the title of each comic, and the title
attribute to include the joke posted by the bot.
Afterwards, Nicolas posted an article explaining the importance of correct usage, and an example. It was this article that inspired me to make changes to the bot. Starting on 2020-12-23 (provided everything works properly), new tweets from XKCDAltTextBot will be prefixed with a link to a transcript from the wiki site explainxkcd.com. For example, here is the current transcript for comic 2400. Although the transcript is unofficial, and dependent on volunteers, it is a notable improvement from the current state.
Although I am unable to change how @xkcdComic posts its images, or how xkcd itself uses HTML attributes, I can do my part to help make the Internet more accessible to all.
3.1.0
This update reintroduces the time limit on Tweet replies, now reduced to 6 hours. If you would like to update, replace xkcd_alt.py.
3.0.0
A new Twitter API
This major update to the XKCDAltTextBot changes the way that the bot retrieves data from Twitter, switching from the search API to the more reliable user timeline API. Further explanation is available here.
This update increases the required version to Python 3.8. Additionally, the following 4 files must be replaced to update the bot:
If you are installing for the first time, follow the instruction in the Wiki.
2.2.0
This update brings the fix for delayed replies of the bot. The issue was that in using the entire JSON data of the tweet to verify, it would not match until the number of likes and retweets does not change in the designated timeframe. This is mitigated by only comparing Tweet IDs.
To update, replace the bot file and restart the program.
2.1.0
Welcome to episode... 10, 11,... 12 of dealing with the painful inconsistency of the Twitter search API. If you're looking to build something similar, I would recommend looking at the streaming API.
To install this update, replace the Python file, Pipfile, and Pipfile.lock.