Granary

Latest version: v6.2

Safety actively analyzes 629765 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 3 of 5

1.14

Not secure
Notable changes
Add `delete()`. Currently includes Twitter and Flickr support.
* Instagram:
* Make extra HTTP fetch (with cookie) to get individual likes ([snarfed/bridgy840](https://github.com/snarfed/bridgy/issues/840)).
* Update scraping logic to handle feed HTML changes.
* Link -mentions in comments as well as photo/video captions.
* GitHub:
* `create`/`preview_create` bug fixes for issues and comments on private repos.
* Handle HTTP 410 Gone responses from REST API, eg when a repo has been deleted or issues for the repo disabled.
* Twitter:
* Add `delete()` and `preview_delete()` for deleting tweets.
* Flickr:
* Add `delete()` and `preview_delete()` for deleting photos.
* microformats2:
* Add [follow-of](https://indieweb.org/follow) support.
* Only use quotation-of property for quote tweets, not URLs. ([155](https://github.com/snarfed/granary/issues/155))
* If a tag has startIndex/length, it gets linkified in the content, so don't also emit an mf2 child or HTML h-cite for it. ([155](https://github.com/snarfed/granary/issues/155)
* Atom:
* Encode `&`s in author URL and email address too. (Thanks [sebsued](https://twitter.com/sebsued)!)
* AS2:
* Add `Follow` support.

1.13

Not secure
Notable changes
* Twitter:
* Support ISO 8601 formatted created_at timestamps, which the [archive download uses](https://help.twitter.com/en/managing-your-account/how-to-download-your-twitter-archive), as well as RFC 2822 from the API.
* `create()` and `preview_create()`: support RSVPs. Tweet them as normal tweets with the RSVP content. ([snarfed/bridgy818](https://github.com/snarfed/bridgy/issues/818))
* `create()` and `preview_create()`: support alt text for images, via AS1 `displayName`. ([snarfed/bridgy756](https://github.com/snarfed/bridgy/issues/756)).
* Instagram:
* Add global rate limiting lock for scraping. If a scraping HTTP request gets a 429 or 503 response, we refuse to make more requests for 5m, and instead short circuit and return the same error. This can be overridden with a new `ignore_rate_limit` kwarg to `get_activities()`.
* GitHub:
* Add `tag` support to `create`/`preview_create` to add label(s) to existing issues ([snarfed/bridgy811](https://github.com/snarfed/bridgy/issues/811)).
* Escape HTML characters (`<`, `>`, and `&`) in content in `create()` and `preview_create()` ([snarfed/bridgy810](https://github.com/snarfed/bridgy/issues/810)).
* `get_activities()` and `get_comment()` now return `ValueError` instead of `AssertionError` on malformed `activity_id` and `comment_id` args, respectively.
* `get_activities()` bug fix for issues/PRs with no body text.
* Switch from GraphQL to REST API for creating comments and reactions, since GraphQL hits authorization errors on many org repos. ([snarfed/bridgy824](https://github.com/snarfed/bridgy/issues/824))
* Improve GraphQL support for comments and users.
* Atom:
* Shorten and ellipsize feed title when necessary ([144](https://github.com/snarfed/granary/issues/144)).
* microformats2:
* Upgrade mf2py to improve a few things like [implied p-name detection](http://microformats.org/wiki/microformats2-implied-properties) and whitespace handling ([#142](https://github.com/snarfed/granary/issues/142), fixes [#145](https://github.com/snarfed/granary/issues/145), [snarfed/bridgy#756](https://github.com/snarfed/bridgy/issues/756), [snarfed/bridgy#828](https://github.com/snarfed/bridgy/issues/828)).
* Support `alt` attribute in `<img>` tags ([snarfed/bridgy756](https://github.com/snarfed/bridgy/issues/756)).

1.12

Not secure
Notable changes

* Add Python 3 support! Granary now requires either Python 2.7+ or Python 3.3+.
* Instagram:
* Fix scraping profile pages.
* Twitter:
* Update character counting to handle Twitter change that now auto-links *all* ccTLDs. [Background.](kylewm/brevity8)
* GitHub:
* Bug fix for `get_activities()` with deleted issues and repos.
* microformats2:
* `object_to_json()`: convert tags to simple strings in the `category` property, not full nested objects like `h-card`s ([141](141)).
* Special case GitHub issues that are in-reply-to a repo or its `/issues` URL to be objectType `issue`.
* Render simple string categories in HTML output.

This release is intentionally small and limited in scope to contain any impact of the Python 3 migration. It *should* be a noop for existing Python 2 users, and we've tested thoroughly, but I'm sure there are still bugs. Please file issues if you notice anything broken!

1.11

Not secure
Notable changes
* Add GitHub!
* `get_activities()` supports issues and pull requests, including comments and reactions. It's currently based on notifications, so it's best effort, not comprehensive, and only includes recently active issues/PRs.
* `create()` and `preview_create()` support issues, comments, [stars](https://help.github.com/articles/about-stars), and [reactions](https://help.github.com/articles/about-conversations-on-github/#reacting-to-ideas-in-comments).
* Twitter:
* Prefer MP4 and other video/... content types to HLS (.m3u8) etc. [Background.](https://twittercommunity.com/t/retiring-mp4-video-output/66093)
* Prefer HTTPS URLs for media images.
* `get_activities()`: Support -prefixed usernames in `user_id`.
* Facebook:
* Support new [recurring aka multi-instance events](https://stackoverflow.com/questions/45131646/decoding-recurring-events-from-facebook-open-graph-api). `create()` and `preview_create()` now only support RSVPs to individual instances of multi-instance events, to match the Facebook API itself.
* Try harder to find original (full) sized photo URLs, specifically `_o.jpg` files instead of `_s.jpg`.
* `create()` bug fix for photo and image URLs with unicode characters.
* Fixed bug where `get_activities(user_id=...)` included the authenticated user's own recent photos, albums, and news publishes.
* Instagram:
* Extract more user (`author`) data from scraped profile pages.
* Fix home page feed scraping.
* microformats2, Atom:
* Add enclosures for image attachments.
* Bug fixes for rendering image, video, and audio attachments inside shares and attachments. De-dupe images.
* microformats2:
* Handle simple string-only author properties.
* Add `fetch_mf2` kwarg to `json_to_object()` for fetching additional pages over HTTP to determine authorship.
* Generate explicit blank `p-name` in HTML to prevent old flawed [implied p-name handling](http://microformats.org/wiki/microformats2-implied-properties) [#131](https://github.com/snarfed/granary/issues/131).
* Fix `share` verb handling in `activity_to_json()` and `activities_to_html()` [134](https://github.com/snarfed/granary/issues/134).
* Remember which content contains HTML, preserve newlines in it, and don't translate those newlines to `<br>`s ([130](https://github.com/snarfed/granary/issues/130)).
* Atom:
* Fix timezone bugs in `updated` and `published`.
* JSON Feed:
* Omit title from items if it's the same as the content. (Often caused by microformats2's implied `p-name` logic.)

1.10

Not secure
Notable changes
* Moved web site and REST API to granary.io! granary-demo.appspot.com now 301 redirects.
* Twitter:
* Update the publish character limit to 280. [Background.](https://twittercommunity.com/t/updating-the-character-limit-and-the-twitter-text-library/96425)
* Fix a [bug in `preview_create` that auto-linked -mentions inside URLs](https://github.com/snarfed/bridgy/issues/527#issuecomment-346302800), e.g. Medium posts.
* Support videos and animated GIFs in `get_activities()` etc.
* Instagram:
* Add cookie query param to REST API to allow scraping that logged in user's feed.
* HTML (including Atom content):
* Render image, video, and audio attachments more often and consistently.
* Include microformats2 `u-photo`, `u-video`, and `u-audio` classes more often and consistently.
* Atom:
* Add `atom_to_activities()` for converting full feed documents.
* Add to REST API and web UI.
* JSON Feed:
* Fix bug that omitted title in some cases ([122](https://github.com/snarfed/granary/issues/122)).

1.9

Not secure
Notable changes
* Add [ActivityStreams 2.0](http://www.w3.org/TR/activitystreams-core/)! New `as2` module includes `to_as1()` and `from_as1()` functions. Currently supported: articles, notes, replies, likes, reposts, events, RSVPs, tags, attachments.
* Atom:
* Add new `atom_to_activity()` function for converting Atom to AS1.
* Add email field to author, if provided.
* JSON Feed:
* Raise ValueError on bad (non-dict) input.
* REST API:
* Add `as2` value for `format` and `input`. Revise existing ActivityStreams and microformats2 value names to `as1`, `as1-xml`, and `mf2-json`. Old values `activitystreams`, `json`, `json-mf2`, and `xml` are still accepted, but deprecated.

Page 3 of 5

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.