Skip to content

Commit

Permalink
release v5.0
Browse files Browse the repository at this point in the history
  • Loading branch information
snarfed committed Dec 4, 2022
1 parent 3e31e4b commit 724d6b2
Show file tree
Hide file tree
Showing 4 changed files with 102 additions and 32 deletions.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -228,6 +228,7 @@ Here's how to package, test, and ship a new release. (Note that this is [largely
```
1. Install from test.pypi.org.
```sh
cd /tmp
python3 -m venv local
source local/bin/activate.csh
pip3 uninstall granary # make sure we force Pip to use the uploaded version
Expand Down Expand Up @@ -290,7 +291,7 @@ On the open source side, there are many related projects. [php-mf2-shim](https:/

Changelog
---
### 5.0 - unreleased
### 5.0 - 2022-12-03

_Breaking changes:_

Expand Down
4 changes: 2 additions & 2 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,9 +87,9 @@
# built documents.
#
# The short X.Y version.
version = '4.0'
version = '5.0'
# The full version, including alpha/beta/rc tags.
release = '4.0'
release = '5.0'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down
125 changes: 97 additions & 28 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -459,7 +459,7 @@ Facebook and Twitter’s raw HTML.
Changelog
---------

5.0 - unreleased
5.0 - 2022-12-03
~~~~~~~~~~~~~~~~

*Breaking changes:*
Expand All @@ -474,6 +474,12 @@ Changelog
you pass an object that implements those as API calls, you’ll
probably want to batch those separately.

- Twitter, Mastodon, Flickr, GitHub:

- ``create``/``preview``: support the AS1 ``favorite`` verb as well
as ``like``.
(`bridgy#1345 <https://github.com/snarfed/bridgy/issues/1345>`__)

- Atom:

- Switch to converting AS1 ``id`` (instead of ``url``) to Atom
Expand All @@ -483,11 +489,59 @@ Changelog

- Implement ``get_actor``.

- ``Source.original_post_discovery``: remove deprecated ``cache``
kwarg.
- Mastodon:

- ``create``/``preview``: allow non-Mastodon replies, ie activities
that include ``inReplyTo`` URLs even if none of them point to a
toot.
(`bridgy#1321 <https://github.com/snarfed/bridgy/issues/1321>`__)
- Raise ``requests.HTTPError`` with ``response.status_code`` 502
instead of ``JSONDecodeError`` on non-JSON responses. This is
synthetic, but more helpful for error handling.

- microformats2:

- ``object_to_json`` and related functions: handle all escaped HTML
entities, not just ``&amp;`` ``&lt;`` ``&gt;``.
- Unify ``microformats2.prefix_image_urls`` and
``prefix_video_urls`` into a new ``as1.prefix_urls`` function.

- RSS:

- Remove ``itunes:category``. It has to be `one of Apple’s explicit
categories <https://feedgen.kiesow.be/ext/api.ext.podcast.html#feedgen.ext.podcast.PodcastExtension.itunes_category>`__,
which we aren’t prepared to validate, so don’t try.

- ActivityStreams 2:

- Translate both ``url`` and ``urls`` from AS1 into multi-valued AS2
``url`` field.

- Move a number of utility methods from the ``Source`` class to a new
``as1`` module: ``object_type``, ``merge_by_id``, ``is_public``,
``add_rsvps_to_event``, ``get_rsvps_from_event``,
``activity_changed``, ``append_in_reply_to``, ``actor_name``,
``original_post_discovery``.
- ``as1.original_post_discovery``: remove deprecated ``cache`` kwarg.

*Non-breaking changes:*

- ActivityStreams 2:

- Fix spec compliance bug: `icon`` and ``image`` are singly
valued, not multiply
valued <https://www.w3.org/TR/activitystreams-vocabulary/#dfn-icon>`__.
- Add new ``is_public`` method and ``PUBLIC_AUDIENCE`` constant.
- Prefer ``"objectType": "featured"`` first in the ``image`` field
when converting from AS1, last in the ``icon`` field. This matches
the ActivityPub (Mastodon) convention of using ``icon`` for
profile pictures and ``image`` for header images.
- Propagate ``url`` values into new ``PropertyValue`` attachments on
``Person`` objects; these end up in Mastodon’s “profile metadata”
link fields.
- ``to_as1``: if an attachment’s ``mediaType`` is ``image/...``,
override ``objectType`` and set it to ``image``.

- Twitter

- Trim alt text in line between post preview and creation
Expand All @@ -510,6 +564,9 @@ Changelog
``https://github.com/snarfed`` to ``@snarfed``
(`bridgy#1090 <https://github.com/snarfed/bridgy/issues/1090>`__).

- ``get_activities`` with ``activity_id`` now supports
``fetch_replies`` and ``fetch_likes``.

- Reddit

- Add ``cache`` support to ``get_activities``.
Expand All @@ -522,9 +579,21 @@ Changelog
and HTML as either raw request body or MIME multipart encoded file
in the ``input`` parameter.

- microformats2

- Add new ``extra`` and ``body_class`` kwargs to
``activities_to_html``.
- When converting ``u-featured`` images to AS1, add new non-standard
``"objectType": "featured"`` field to distinguish them from
``u-photo``.
- Convert ``p-note`` to AS1 ``summary``.
- Bug fixes for converting ``image`` attachments to ``photo``.

- ``Source.original_post_discovery``: add new ``max_redirect_fetches``
keyword arg.

.. _section-1:

4.0 - 2022-03-23
~~~~~~~~~~~~~~~~

Expand Down Expand Up @@ -569,7 +638,7 @@ Changelog

- Handle malformed ``items.author`` element.

.. _section-1:
.. _section-2:

3.2 - 2021-09-15
~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -627,7 +696,7 @@ Changelog
- REST API: ported web framework from webapp2 to Flask. No user-visible
behavior change expected.

.. _section-2:
.. _section-3:

3.1 - 2021-04-03
~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -732,7 +801,7 @@ Changelog
- ``from_as1()``: convert ``username`` to ``preferredUsername``.
- ``from_as1()``: bug fix, make ``context`` kwarg actually work.

.. _section-3:
.. _section-4:

3.0 - 2020-04-08
~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -811,7 +880,7 @@ Non-breaking changes:
caching now.
- Added Meetup.com support for publishing RSVPs.

.. _section-4:
.. _section-5:

2.2 - 2019-11-02
~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -860,7 +929,7 @@ Non-breaking changes:
supports one enclosure per item, so we now only include the first,
and log a warning if the activity has more.)

.. _section-5:
.. _section-6:

2.1 - 2019-09-04
~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -910,7 +979,7 @@ Non-breaking changes:

- Default title to ellipsized content.

.. _section-6:
.. _section-7:

2.0 - 2019-03-01
~~~~~~~~~~~~~~~~
Expand All @@ -919,7 +988,7 @@ Non-breaking changes:
March <https://developers.google.com/+/api-shutdown>`__. Notably, this
removes the ``googleplus`` module.

.. _section-7:
.. _section-8:

1.15 - 2019-02-28
~~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -970,7 +1039,7 @@ removes the ``googleplus`` module.
- ``/url``: Return HTTP 400 when fetching the user’s URL results in an
infinite redirect.

.. _section-8:
.. _section-9:

1.14 - 2018-11-12
~~~~~~~~~~~~~~~~~
Expand All @@ -997,7 +1066,7 @@ Encode ``&``\ s in author URL and email address too. (Thanks
`sebsued <https://twitter.com/sebsued>`__!) \* AS2: \* Add ``Follow``
support.

.. _section-9:
.. _section-10:

1.13 - 2018-08-08
~~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -1058,7 +1127,7 @@ support.
- Support ``alt`` attribute in ``<img>`` tags
(`snarfed/bridgy#756 <https://github.com/snarfed/bridgy/issues/756>`__).

.. _section-10:
.. _section-11:

1.12 - 2018-03-24
~~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -1093,7 +1162,7 @@ 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!

.. _section-11:
.. _section-12:

1.11 - 2018-03-09
~~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -1166,7 +1235,7 @@ still bugs. Please file issues if you notice anything broken!
- Omit title from items if it’s the same as the content. (Often
caused by microformats2’s implied ``p-name`` logic.)

.. _section-12:
.. _section-13:

1.10 - 2017-12-10
~~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -1208,7 +1277,7 @@ still bugs. Please file issues if you notice anything broken!
- Fix bug that omitted title in some cases
(`#122 <https://github.com/snarfed/granary/issues/122>`__).

.. _section-13:
.. _section-14:

1.9 - 2017-10-24
~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -1236,7 +1305,7 @@ still bugs. Please file issues if you notice anything broken!
``json``, ``json-mf2``, and ``xml`` are still accepted, but
deprecated.

.. _section-14:
.. _section-15:

1.8 - 2017-08-29
~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -1316,7 +1385,7 @@ still bugs. Please file issues if you notice anything broken!
`bug <https://github.com/kylewm/brevity/issues/5>`__
`fixes <https://github.com/kylewm/brevity/issues/6>`__.

.. _section-15:
.. _section-16:

1.7 - 2017-02-27
~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -1364,7 +1433,7 @@ still bugs. Please file issues if you notice anything broken!
on “narrow” builds of Python 2 with ``--enable-unicode=ucs2``, which
is the default on Mac OS X, Windows, and older \*nix.

.. _section-16:
.. _section-17:

1.6 - 2016-11-26
~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -1398,7 +1467,7 @@ still bugs. Please file issues if you notice anything broken!
- Error handling: return HTTP 502 for non-JSON API responses, 504 for
connection failures.

.. _section-17:
.. _section-18:

1.5 - 2016-08-25
~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -1436,14 +1505,14 @@ still bugs. Please file issues if you notice anything broken!
- Switch creating comments and reactions from GraphQL to REST API
(`bridgy#824 <https://github.com/snarfed/bridgy/issues/824>`__.

.. _section-18:
.. _section-19:

1.4.1 - 2016-06-27
~~~~~~~~~~~~~~~~~~

- Bump oauth-dropins requirement to 1.4.

.. _section-19:
.. _section-20:

1.4.0 - 2016-06-27
~~~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -1477,15 +1546,15 @@ still bugs. Please file issues if you notice anything broken!
- Upgrade to requests 2.10.0 and requests-toolbelt 0.60, which support
App Engine.

.. _section-20:
.. _section-21:

1.3.1 - 2016-04-07
~~~~~~~~~~~~~~~~~~

- Update `oauth-dropins <https://github.com/snarfed/oauth-dropins>`__
dependency to >=1.3.

.. _section-21:
.. _section-22:

1.3.0 - 2016-04-06
~~~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -1528,7 +1597,7 @@ still bugs. Please file issues if you notice anything broken!
- Misc bug fixes.
- Set up Coveralls.

.. _section-22:
.. _section-23:

1.2.0 - 2016-01-11
~~~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -1584,7 +1653,7 @@ still bugs. Please file issues if you notice anything broken!
- Misc bug fixes.
- Set up CircleCI.

.. _section-23:
.. _section-24:

1.1.0 - 2015-09-06
~~~~~~~~~~~~~~~~~~
Expand All @@ -1607,15 +1676,15 @@ still bugs. Please file issues if you notice anything broken!
- Improve original post discovery algorithm.
- New logo.

.. _section-24:
.. _section-25:

1.0.1 - 2015-07-11
~~~~~~~~~~~~~~~~~~

- Bug fix for atom template rendering.
- Facebook, Instagram: support access_token parameter.

.. _section-25:
.. _section-26:

1.0 - 2015-07-10
~~~~~~~~~~~~~~~~
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
'humanfriendly>=4.18',
'jinja2>=2.10',
'mf2util>=0.5.0',
'oauth-dropins>=5.0',
'oauth-dropins>=6.0',
'praw>=7.3.0',
'python-dateutil>=2.8',
'requests>=2.22',
Expand Down

0 comments on commit 724d6b2

Please sign in to comment.