Mastodon.py 2.2.0__tar.gz → 2.2.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/CHANGELOG.rst +12 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2/Mastodon.py.egg-info}/PKG-INFO +10 -1
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/Mastodon.py.egg-info/SOURCES.txt +1 -0
- {mastodon_py-2.2.0/Mastodon.py.egg-info → mastodon_py-2.2.2}/PKG-INFO +10 -1
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/README.rst +9 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/07_timelines.rst +1 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/conf.py +1 -1
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/index.rst +22 -3
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/Mastodon.py +1 -1
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/authentication.py +5 -1
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/instance.py +10 -2
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/internals.py +59 -3
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/search.py +14 -10
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/streaming_endpoints.py +17 -2
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/timeline.py +36 -1
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/utility.py +13 -12
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/pyproject.toml +1 -1
- mastodon_py-2.2.2/tests/cassettes/test_account.yaml +120 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_account_block_unblock.yaml +33 -33
- mastodon_py-2.2.0/tests/cassettes/test_account_pin_unpin.yaml → mastodon_py-2.2.2/tests/cassettes/test_account_endorse_unendorse.yaml +87 -87
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_account_familiar_followers.yaml +80 -80
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_account_follow_unfollow.yaml +34 -34
- mastodon_py-2.2.0/tests/cassettes/test_account_following.yaml → mastodon_py-2.2.2/tests/cassettes/test_account_followers.yaml +18 -18
- mastodon_py-2.2.0/tests/cassettes/test_account_followers.yaml → mastodon_py-2.2.2/tests/cassettes/test_account_following.yaml +18 -18
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_account_lookup.yaml +44 -44
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_account_mute_unmute.yaml +64 -61
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_account_notes.yaml +22 -22
- mastodon_py-2.2.0/tests/cassettes/test_account_endorse_unendorse.yaml → mastodon_py-2.2.2/tests/cassettes/test_account_pin_unpin.yaml +87 -87
- mastodon_py-2.2.2/tests/cassettes/test_account_pinned.yaml +525 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_account_relationships.yaml +22 -22
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_account_remove_from_followers.yaml +92 -92
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_account_search.yaml +59 -59
- mastodon_py-2.2.2/tests/cassettes/test_account_update_credentials.yaml +2093 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_account_update_credentials_no_avatar.yaml +22 -22
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_account_update_credentials_no_header.yaml +22 -22
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_account_update_credentials_quote_policy.yaml +40 -39
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_account_update_credentials_source_and_privacy.yaml +14 -14
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_account_update_credentials_too_many_fields.yaml +7 -7
- mastodon_py-2.2.2/tests/cassettes/test_accounts.yaml +179 -0
- mastodon_py-2.2.2/tests/cassettes/test_admin_accounts.yaml +184 -0
- mastodon_py-2.2.2/tests/cassettes/test_admin_accounts_v1.yaml +184 -0
- mastodon_py-2.2.2/tests/cassettes/test_admin_accounts_v2.yaml +241 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_admin_canonical_email_block.yaml +96 -96
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_admin_domain_blocks.yaml +52 -52
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_admin_email_domain_blocks.yaml +40 -40
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_admin_ip_blocks.yaml +57 -57
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_admin_moderation.yaml +271 -269
- mastodon_py-2.2.2/tests/cassettes/test_admin_reports.yaml +824 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_admin_stats.yaml +24 -24
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_admin_trends.yaml +28 -28
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_app_account_create.yaml +41 -41
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_app_account_create_invalid.yaml +29 -29
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_app_verify_credentials.yaml +9 -9
- mastodon_py-2.2.2/tests/cassettes/test_attribute_access.yaml +134 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_auth_request_url.yaml +18 -18
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_blocks.yaml +7 -7
- mastodon_py-2.2.2/tests/cassettes/test_bookmarks.yaml +452 -0
- mastodon_py-2.2.2/tests/cassettes/test_conversations.yaml +394 -0
- mastodon_py-2.2.2/tests/cassettes/test_date_hook.yaml +134 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_directory.yaml +10 -10
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_domain_block_unblock.yaml +15 -15
- mastodon_py-2.2.0/tests/cassettes/test_follow_requests.yaml → mastodon_py-2.2.2/tests/cassettes/test_domain_blocks.yaml +8 -8
- mastodon_py-2.2.0/tests/cassettes/test_instance_rules.yaml → mastodon_py-2.2.2/tests/cassettes/test_emoji.yaml +8 -8
- mastodon_py-2.2.0/tests/cassettes/test_domain_blocks.yaml → mastodon_py-2.2.2/tests/cassettes/test_favourites.yaml +7 -7
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_featured_tags.yaml +51 -51
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_featured_tags_2.yaml +57 -57
- mastodon_py-2.2.2/tests/cassettes/test_fetch_next_previous.yaml +1653 -0
- mastodon_py-2.2.2/tests/cassettes/test_fetch_next_previous_after_persist.yaml +1653 -0
- mastodon_py-2.2.2/tests/cassettes/test_fetch_next_previous_from_pagination_info.yaml +1653 -0
- mastodon_py-2.2.2/tests/cassettes/test_fetch_remaining.yaml +4334 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_follow_request_authorize.yaml +60 -60
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_follow_request_reject.yaml +47 -47
- mastodon_py-2.2.0/tests/cassettes/test_favourites.yaml → mastodon_py-2.2.2/tests/cassettes/test_follow_requests.yaml +7 -7
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_follow_suggestions.yaml +21 -21
- mastodon_py-2.2.2/tests/cassettes/test_follow_with_notify_reblog.yaml +645 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_followed_hashtags.yaml +52 -52
- mastodon_py-2.2.2/tests/cassettes/test_get_pagination_info.yaml +1487 -0
- mastodon_py-2.2.2/tests/cassettes/test_grouped_notification_pagination.yaml +1630 -0
- mastodon_py-2.2.2/tests/cassettes/test_grouped_notifications.yaml +580 -0
- mastodon_py-2.2.2/tests/cassettes/test_hashtag_tl.yaml +263 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_health.yaml +6 -6
- mastodon_py-2.2.2/tests/cassettes/test_home_tl.yaml +237 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_home_tl_anonymous_throws.yaml +7 -7
- mastodon_py-2.2.2/tests/cassettes/test_id_hook.yaml +134 -0
- mastodon_py-2.2.2/tests/cassettes/test_id_hook_in_reply_to.yaml +266 -0
- mastodon_py-2.2.2/tests/cassettes/test_id_hook_within_reblog.yaml +269 -0
- mastodon_py-2.2.2/tests/cassettes/test_instance.yaml +66 -0
- mastodon_py-2.2.2/tests/cassettes/test_instance_activity.yaml +63 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_instance_domain_blocks.yaml +6 -6
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_instance_extended_description.yaml +8 -8
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_instance_languages.yaml +40 -34
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_instance_peers.yaml +23 -23
- mastodon_py-2.2.0/tests/cassettes/test_emoji.yaml → mastodon_py-2.2.2/tests/cassettes/test_instance_rules.yaml +9 -9
- mastodon_py-2.2.0/tests/cassettes/test_stream_healthy.yaml → mastodon_py-2.2.2/tests/cassettes/test_instance_v1.yaml +13 -49
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_lang_for_errors.yaml +14 -13
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_list_add_remove_account.yaml +132 -132
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_list_by_account.yaml +64 -64
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_list_create.yaml +21 -21
- mastodon_py-2.2.2/tests/cassettes/test_list_timeline.yaml +589 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_list_update.yaml +43 -43
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_log_in_none.yaml +9 -9
- mastodon_py-2.2.2/tests/cassettes/test_markers.yaml +257 -0
- mastodon_py-2.2.2/tests/cassettes/test_media_post[False].yaml +35756 -0
- mastodon_py-2.2.2/tests/cassettes/test_media_post[True].yaml +35760 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_media_post_file.yaml +15 -15
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_media_post_multiple.yaml +94 -214
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_media_post_pathlib.yaml +15 -15
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_media_update.yaml +36 -36
- mastodon_py-2.2.2/tests/cassettes/test_min_max_id.yaml +382 -0
- mastodon_py-2.2.2/tests/cassettes/test_min_max_id_datetimes.yaml +258 -0
- mastodon_py-2.2.2/tests/cassettes/test_min_max_id_datetimes_datetimeobjects.pkl +0 -0
- mastodon_py-2.2.2/tests/cassettes/test_mutes.yaml +62 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_nodeinfo.yaml +17 -17
- mastodon_py-2.2.2/tests/cassettes/test_notification_requests_accept.yaml +1556 -0
- mastodon_py-2.2.2/tests/cassettes/test_notifications.yaml +381 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_notifications_clear.yaml +7 -7
- mastodon_py-2.2.2/tests/cassettes/test_notifications_dismiss.yaml +260 -0
- mastodon_py-2.2.2/tests/cassettes/test_notifications_exclude_and_types.yaml +383 -0
- mastodon_py-2.2.2/tests/cassettes/test_notifications_exclude_types.yaml +192 -0
- mastodon_py-2.2.2/tests/cassettes/test_notifications_mentions_only.yaml +261 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_notifications_policy.yaml +31 -31
- mastodon_py-2.2.2/tests/cassettes/test_notifications_types.yaml +320 -0
- mastodon_py-2.2.2/tests/cassettes/test_pagination_iterator.yaml +4697 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_poll_illegal_vote.yaml +27 -27
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_polls.yaml +60 -60
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_preferences.yaml +7 -7
- mastodon_py-2.2.2/tests/cassettes/test_public_tl.yaml +358 -0
- mastodon_py-2.2.2/tests/cassettes/test_public_tl_anonymous.yaml +273 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_push_delete.yaml +26 -26
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_push_set.yaml +20 -20
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_push_set_all_events.yaml +11 -11
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_push_update.yaml +53 -53
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_push_update_all_events.yaml +20 -20
- mastodon_py-2.2.2/tests/cassettes/test_report.yaml +263 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_scheduled_status.yaml +54 -54
- mastodon_py-2.2.2/tests/cassettes/test_scheduled_status_datetimeobjects.pkl +0 -0
- mastodon_py-2.2.2/tests/cassettes/test_search.yaml +185 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_server_time.yaml +33 -33
- mastodon_py-2.2.2/tests/cassettes/test_server_time_datetimeobjects.pkl +0 -0
- mastodon_py-2.2.2/tests/cassettes/test_status.yaml +196 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_card.yaml +204 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_context.yaml +193 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_status_delete_media.yaml +126 -112
- mastodon_py-2.2.2/tests/cassettes/test_status_edit.yaml +374 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_status_empty.yaml +8 -8
- mastodon_py-2.2.2/tests/cassettes/test_status_fav_unfav.yaml +263 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_favourited_by.yaml +263 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_status_missing.yaml +9 -9
- mastodon_py-2.2.2/tests/cassettes/test_status_mute_unmute.yaml +264 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_pin_unpin.yaml +264 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_post[Content warning-None].yaml +136 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_post[Content warning-direct].yaml +136 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_post[Content warning-private].yaml +136 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_post[Content warning-public].yaml +136 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_post[Content warning-unlisted].yaml +136 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_post[None-None].yaml +134 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_post[None-direct].yaml +134 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_post[None-private].yaml +134 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_post[None-public].yaml +134 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_post[None-unlisted].yaml +134 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_post_with_quote.yaml +276 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_post_with_quote_approval_policy.yaml +202 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_quote_approval_visibility.yaml +597 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_quote_revoke.yaml +348 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_quotes.yaml +193 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_reblog_unreblog.yaml +267 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_reblog_visibility.yaml +338 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_reblogged_by.yaml +453 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_reply.yaml +322 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_reply_with_quote.yaml +476 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_translate.yaml +195 -0
- mastodon_py-2.2.2/tests/cassettes/test_status_update_quote_approval_policy.yaml +206 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_status_update_with_media_edit.yaml +78 -77
- mastodon_py-2.2.2/tests/cassettes/test_stream_direct.yaml +438 -0
- mastodon_py-2.2.2/tests/cassettes/test_stream_healthy.yaml +163 -0
- mastodon_py-2.2.2/tests/cassettes/test_stream_user_direct.yaml +859 -0
- mastodon_py-2.2.2/tests/cassettes/test_stream_user_local.yaml +364 -0
- mastodon_py-2.2.2/tests/cassettes/test_suggested_tags.yaml +196 -0
- mastodon_py-2.2.2/tests/cassettes/test_timeline_disabled.yaml +1311 -0
- mastodon_py-2.2.2/tests/cassettes/test_timeline_link_fails.yaml +123 -0
- mastodon_py-2.2.2/tests/cassettes/test_toot.yaml +134 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_translation_languages.yaml +8 -8
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_trending_links.yaml +6 -6
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_trending_statuses.yaml +7 -7
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_trending_tags.yaml +13 -13
- mastodon_py-2.2.2/tests/cassettes/test_unauthed_home_tl_throws.yaml +192 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_v2_filters_keywords.yaml +67 -67
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes/test_v2_filters_statuses.yaml +90 -90
- mastodon_py-2.2.2/tests/cassettes/test_verify_credentials.yaml +120 -0
- mastodon_py-2.2.2/tests/cassettes/test_verify_version.yaml +129 -0
- mastodon_py-2.2.2/tests/cassettes_special/test_scheduled_status_long_datetimeobjects.pkl +0 -0
- mastodon_py-2.2.2/tests/cassettes_special/test_scheduled_status_long_part1.yaml +130 -0
- mastodon_py-2.2.2/tests/cassettes_special/test_scheduled_status_long_part2.yaml +92 -0
- mastodon_py-2.2.2/tests/cassettes_special/test_scheduled_status_long_text.pkl +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_account.py +12 -6
- mastodon_py-2.2.2/tests/test_constructor.py +184 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_entities.py +24 -6
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_instance.py +7 -1
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_status.py +8 -2
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_streaming.py +41 -21
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_timeline.py +52 -2
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_trends.py +0 -1
- mastodon_py-2.2.0/tests/cassettes/test_account.yaml +0 -120
- mastodon_py-2.2.0/tests/cassettes/test_account_pinned.yaml +0 -525
- mastodon_py-2.2.0/tests/cassettes/test_account_update_credentials.yaml +0 -2093
- mastodon_py-2.2.0/tests/cassettes/test_accounts.yaml +0 -179
- mastodon_py-2.2.0/tests/cassettes/test_admin_accounts.yaml +0 -184
- mastodon_py-2.2.0/tests/cassettes/test_admin_accounts_v1.yaml +0 -184
- mastodon_py-2.2.0/tests/cassettes/test_admin_accounts_v2.yaml +0 -241
- mastodon_py-2.2.0/tests/cassettes/test_admin_reports.yaml +0 -824
- mastodon_py-2.2.0/tests/cassettes/test_attribute_access.yaml +0 -134
- mastodon_py-2.2.0/tests/cassettes/test_bookmarks.yaml +0 -452
- mastodon_py-2.2.0/tests/cassettes/test_conversations.yaml +0 -400
- mastodon_py-2.2.0/tests/cassettes/test_date_hook.yaml +0 -134
- mastodon_py-2.2.0/tests/cassettes/test_fetch_next_previous.yaml +0 -1653
- mastodon_py-2.2.0/tests/cassettes/test_fetch_next_previous_after_persist.yaml +0 -1653
- mastodon_py-2.2.0/tests/cassettes/test_fetch_next_previous_from_pagination_info.yaml +0 -1653
- mastodon_py-2.2.0/tests/cassettes/test_fetch_remaining.yaml +0 -4270
- mastodon_py-2.2.0/tests/cassettes/test_follow_with_notify_reblog.yaml +0 -677
- mastodon_py-2.2.0/tests/cassettes/test_get_pagination_info.yaml +0 -1487
- mastodon_py-2.2.0/tests/cassettes/test_grouped_notification_pagination.yaml +0 -1630
- mastodon_py-2.2.0/tests/cassettes/test_grouped_notifications.yaml +0 -580
- mastodon_py-2.2.0/tests/cassettes/test_hashtag_tl.yaml +0 -199
- mastodon_py-2.2.0/tests/cassettes/test_home_tl.yaml +0 -268
- mastodon_py-2.2.0/tests/cassettes/test_id_hook.yaml +0 -134
- mastodon_py-2.2.0/tests/cassettes/test_id_hook_in_reply_to.yaml +0 -266
- mastodon_py-2.2.0/tests/cassettes/test_id_hook_within_reblog.yaml +0 -269
- mastodon_py-2.2.0/tests/cassettes/test_instance.yaml +0 -63
- mastodon_py-2.2.0/tests/cassettes/test_instance_activity.yaml +0 -63
- mastodon_py-2.2.0/tests/cassettes/test_instance_v1.yaml +0 -65
- mastodon_py-2.2.0/tests/cassettes/test_list_timeline.yaml +0 -576
- mastodon_py-2.2.0/tests/cassettes/test_markers.yaml +0 -257
- mastodon_py-2.2.0/tests/cassettes/test_media_post[False].yaml +0 -35755
- mastodon_py-2.2.0/tests/cassettes/test_media_post[True].yaml +0 -35759
- mastodon_py-2.2.0/tests/cassettes/test_min_max_id.yaml +0 -382
- mastodon_py-2.2.0/tests/cassettes/test_min_max_id_datetimes.yaml +0 -258
- mastodon_py-2.2.0/tests/cassettes/test_min_max_id_datetimes_datetimeobjects.pkl +0 -0
- mastodon_py-2.2.0/tests/cassettes/test_mutes.yaml +0 -63
- mastodon_py-2.2.0/tests/cassettes/test_notification_requests_accept.yaml +0 -1555
- mastodon_py-2.2.0/tests/cassettes/test_notifications.yaml +0 -385
- mastodon_py-2.2.0/tests/cassettes/test_notifications_dismiss.yaml +0 -262
- mastodon_py-2.2.0/tests/cassettes/test_notifications_exclude_and_types.yaml +0 -386
- mastodon_py-2.2.0/tests/cassettes/test_notifications_exclude_types.yaml +0 -193
- mastodon_py-2.2.0/tests/cassettes/test_notifications_mentions_only.yaml +0 -264
- mastodon_py-2.2.0/tests/cassettes/test_notifications_types.yaml +0 -323
- mastodon_py-2.2.0/tests/cassettes/test_pagination_iterator.yaml +0 -4633
- mastodon_py-2.2.0/tests/cassettes/test_public_tl.yaml +0 -306
- mastodon_py-2.2.0/tests/cassettes/test_public_tl_anonymous.yaml +0 -218
- mastodon_py-2.2.0/tests/cassettes/test_report.yaml +0 -263
- mastodon_py-2.2.0/tests/cassettes/test_scheduled_status_datetimeobjects.pkl +0 -0
- mastodon_py-2.2.0/tests/cassettes/test_search.yaml +0 -185
- mastodon_py-2.2.0/tests/cassettes/test_server_time_datetimeobjects.pkl +0 -0
- mastodon_py-2.2.0/tests/cassettes/test_status.yaml +0 -196
- mastodon_py-2.2.0/tests/cassettes/test_status_card.yaml +0 -198
- mastodon_py-2.2.0/tests/cassettes/test_status_context.yaml +0 -193
- mastodon_py-2.2.0/tests/cassettes/test_status_edit.yaml +0 -376
- mastodon_py-2.2.0/tests/cassettes/test_status_fav_unfav.yaml +0 -263
- mastodon_py-2.2.0/tests/cassettes/test_status_favourited_by.yaml +0 -263
- mastodon_py-2.2.0/tests/cassettes/test_status_mute_unmute.yaml +0 -264
- mastodon_py-2.2.0/tests/cassettes/test_status_pin_unpin.yaml +0 -264
- mastodon_py-2.2.0/tests/cassettes/test_status_post[Content warning-None].yaml +0 -136
- mastodon_py-2.2.0/tests/cassettes/test_status_post[Content warning-direct].yaml +0 -136
- mastodon_py-2.2.0/tests/cassettes/test_status_post[Content warning-private].yaml +0 -136
- mastodon_py-2.2.0/tests/cassettes/test_status_post[Content warning-public].yaml +0 -136
- mastodon_py-2.2.0/tests/cassettes/test_status_post[Content warning-unlisted].yaml +0 -136
- mastodon_py-2.2.0/tests/cassettes/test_status_post[None-None].yaml +0 -134
- mastodon_py-2.2.0/tests/cassettes/test_status_post[None-direct].yaml +0 -134
- mastodon_py-2.2.0/tests/cassettes/test_status_post[None-private].yaml +0 -134
- mastodon_py-2.2.0/tests/cassettes/test_status_post[None-public].yaml +0 -134
- mastodon_py-2.2.0/tests/cassettes/test_status_post[None-unlisted].yaml +0 -134
- mastodon_py-2.2.0/tests/cassettes/test_status_post_with_quote.yaml +0 -276
- mastodon_py-2.2.0/tests/cassettes/test_status_post_with_quote_approval_policy.yaml +0 -201
- mastodon_py-2.2.0/tests/cassettes/test_status_quote_approval_visibility.yaml +0 -602
- mastodon_py-2.2.0/tests/cassettes/test_status_quote_revoke.yaml +0 -347
- mastodon_py-2.2.0/tests/cassettes/test_status_quotes.yaml +0 -193
- mastodon_py-2.2.0/tests/cassettes/test_status_reblog_unreblog.yaml +0 -267
- mastodon_py-2.2.0/tests/cassettes/test_status_reblog_visibility.yaml +0 -338
- mastodon_py-2.2.0/tests/cassettes/test_status_reblogged_by.yaml +0 -453
- mastodon_py-2.2.0/tests/cassettes/test_status_reply.yaml +0 -323
- mastodon_py-2.2.0/tests/cassettes/test_status_reply_with_quote.yaml +0 -457
- mastodon_py-2.2.0/tests/cassettes/test_status_translate.yaml +0 -195
- mastodon_py-2.2.0/tests/cassettes/test_status_update_quote_approval_policy.yaml +0 -205
- mastodon_py-2.2.0/tests/cassettes/test_stream_direct.yaml +0 -374
- mastodon_py-2.2.0/tests/cassettes/test_stream_user_direct.yaml +0 -859
- mastodon_py-2.2.0/tests/cassettes/test_stream_user_local.yaml +0 -366
- mastodon_py-2.2.0/tests/cassettes/test_suggested_tags.yaml +0 -196
- mastodon_py-2.2.0/tests/cassettes/test_timeline_link_fails.yaml +0 -59
- mastodon_py-2.2.0/tests/cassettes/test_toot.yaml +0 -134
- mastodon_py-2.2.0/tests/cassettes/test_unauthed_home_tl_throws.yaml +0 -192
- mastodon_py-2.2.0/tests/cassettes/test_verify_credentials.yaml +0 -120
- mastodon_py-2.2.0/tests/cassettes/test_verify_version.yaml +0 -374
- mastodon_py-2.2.0/tests/cassettes_special/test_scheduled_status_long_datetimeobjects.pkl +0 -0
- mastodon_py-2.2.0/tests/cassettes_special/test_scheduled_status_long_part1.yaml +0 -133
- mastodon_py-2.2.0/tests/cassettes_special/test_scheduled_status_long_part2.yaml +0 -73
- mastodon_py-2.2.0/tests/cassettes_special/test_scheduled_status_long_text.pkl +0 -0
- mastodon_py-2.2.0/tests/test_constructor.py +0 -48
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/LICENSE +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/MANIFEST.in +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/Mastodon.py.egg-info/dependency_links.txt +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/Mastodon.py.egg-info/requires.txt +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/Mastodon.py.egg-info/top_level.txt +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/01_general.rst +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/02_return_values.rst +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/03_errors.rst +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/04_auth.rst +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/05_statuses.rst +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/06_accounts.rst +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/08_instances.rst +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/09_notifications.rst +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/10_streaming.rst +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/11_misc.rst +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/12_utilities.rst +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/13_admin.rst +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/14_contributing.rst +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/15_everything.rst +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/Makefile +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/docs/update_everything_page.sh +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/__init__.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/_url_regex.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/accounts.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/admin.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/async_refresh.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/compat.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/conversations.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/defaults.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/endorsements.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/errors.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/favourites.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/filters.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/hashtags.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/lists.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/media.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/notifications.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/polls.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/preferences.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/push.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/py.typed +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/relationships.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/reports.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/return_types.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/statuses.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/streaming.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/suggestions.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/trends.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/types_base.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/mastodon/versions.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/setup.cfg +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/setup.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/README.markdown +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/__init__.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/amewatson.jpg +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_account.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_accountcreationerror.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_accountcreationerrordetails.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_accountcreationerrordetailsfield.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_accountfield.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_activity.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_announcement.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_application.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_context.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_conversation.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_credentialaccountsource.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_customemoji.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_domainblock.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_extendeddescription.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_familiarfollowers.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_featuredtag.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_filter.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_filterkeyword.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_filterresult.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_filterstatus.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_filterv2.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_groupednotificationsresults.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instance.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instanceaccountconfiguration.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instanceconfiguration.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instanceconfigurationv2.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instancecontact.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instanceicon.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instancemediaconfiguration.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instancepollconfiguration.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instanceregistrations.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instancestatistics.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instancestatusconfiguration.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instancethumbnail.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instancethumbnailversions.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instancetimelinesaccessconfiguration.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instancetimelinesaccessfeedconfiguration.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instancetranslationconfiguration.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instanceurls.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instanceurlsv2.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instanceusage.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instanceusageusers.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instancev2.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_instancevapidkey.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_marker.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_mediaattachment.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_mediaattachmentaudiometadata.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_mediaattachmentcolors.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_mediaattachmentfocuspoint.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_mediaattachmentimagemetadata.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_mediaattachmentmetadatacontainer.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_mediaattachmentvideometadata.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_nodeinfo.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_nodeinfometadata.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_nodeinfoservices.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_nodeinfosoftware.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_nodeinfousage.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_nodeinfousageusers.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_notification.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_notificationgroup.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_notificationpolicy.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_notificationpolicysummary.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_oauthserverinfo.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_oauthuserinfo.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_partialaccountwithavatar.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_poll.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_polloption.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_preferences.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_previewcard.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_previewcardauthor.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_quote.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_quoteapproval.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_reaction.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_relationship.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_role.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_rule.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_ruletranslation.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_scheduledstatus.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_scheduledstatusparams.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_searchv2.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_shallowquote.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_status.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_statusedit.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_statusmention.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_statussource.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_suggestion.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_supportedlocale.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_tag.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_taghistory.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_termsofservice.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_trendinglinkhistory.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_unreadnotificationscount.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_userlist.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_webpushsubscription.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_entity_tests/test_entity_webpushsubscriptionalerts.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_old_pagination/test_fetch_next_previous.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_old_pagination/test_fetch_next_previous_from_pagination_info.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_pre_2_9_2/test_notifications_dismiss.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_pre_2_9_2/test_search.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_pre_2_9_2/test_status_card.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_pre_4_0_0/test_filter_clientside.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_pre_4_0_0/test_filter_create.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_pre_4_0_0/test_filter_serverside.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_pre_4_0_0/test_filter_update.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_pre_4_0_0/test_media_post.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_pre_4_4_0/test_log_in_password.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_pre_4_4_0/test_log_in_password_incorrect.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_pre_4_4_0/test_log_in_password_to_file.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/cassettes_pre_4_4_0/test_zzz_revoke.yaml +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/conftest.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/image.jpg +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/run_mastodon_for_tests.sh +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/setup.sql +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_admin.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_async_refresh.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_auth.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_blurhash.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_bookmarks.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_create_app.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_domain_blocks.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_errors.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_filters.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_follow_requests.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_hooks.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_lists.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_markers.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_media.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_notifications.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_pagination.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_polls.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_push.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_quotes.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_reports.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_search.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_status_length.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_types_base.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/test_zzz_revoke.py +0 -0
- {mastodon_py-2.2.0 → mastodon_py-2.2.2}/tests/video.mp4 +0 -0
|
@@ -2,6 +2,18 @@ A note on versioning: This librarys major version will grow with the APIs
|
|
|
2
2
|
version number. Breaking changes will be indicated by a change in the minor
|
|
3
3
|
(or major) version number, and will generally be avoided.
|
|
4
4
|
|
|
5
|
+
v2.2.2
|
|
6
|
+
-------
|
|
7
|
+
* Improve instance information caching
|
|
8
|
+
* Add a function to check whether a given timeline is available on an instance (Thanks @pdeitel for the report that triggered this)
|
|
9
|
+
* Add warnings when a user tries to access the stream for a deprecated timeline (Thanks @pdeitel for the report that triggered this)
|
|
10
|
+
* Add missing `limit` parameter for `search` (Thanks @Vitexus)
|
|
11
|
+
* Various small fixes and improvements to testing
|
|
12
|
+
|
|
13
|
+
v2.2.1
|
|
14
|
+
------
|
|
15
|
+
* Updated citation information to match the new JOSS publication (Thanks @dataspider and @professornaite for reviewing and @danielskatz for editing)
|
|
16
|
+
|
|
5
17
|
v2.2.0
|
|
6
18
|
------
|
|
7
19
|
* Bumped support level to 4.5.0
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: Mastodon.py
|
|
3
|
-
Version: 2.2.
|
|
3
|
+
Version: 2.2.2
|
|
4
4
|
Summary: Python wrapper for the Mastodon API
|
|
5
5
|
Author-email: Lorenz Diener <lorenzd+mastodonpypypi@gmail.com>
|
|
6
6
|
License: MIT
|
|
@@ -101,6 +101,15 @@ please feel free to open an issue, a github discussion thread, or to just direct
|
|
|
101
101
|
contact @halcy@icosahedron.website on the Fediverse or .halcy on Discord - we'll
|
|
102
102
|
try to respond as quickly as possible.
|
|
103
103
|
|
|
104
|
+
Citing
|
|
105
|
+
------
|
|
106
|
+
If you use Mastodon.py as part of your research, please review and cite the following paper:
|
|
107
|
+
|
|
108
|
+
Diener et al., (2026). Mastodon.py: A Python library for the Mastodon API. *Journal of Open Source Software*, 11(120), 8946, https://doi.org/10.21105/joss.08946
|
|
109
|
+
|
|
110
|
+
.. image:: https://joss.theoj.org/papers/10.21105/joss.08946/status.svg
|
|
111
|
+
:target: https://doi.org/10.21105/joss.08946
|
|
112
|
+
|
|
104
113
|
Acknowledgements
|
|
105
114
|
----------------
|
|
106
115
|
Mastodon.py contains work by a large amount of contributors, many of which have
|
|
@@ -266,6 +266,7 @@ tests/cassettes/test_stream_healthy.yaml
|
|
|
266
266
|
tests/cassettes/test_stream_user_direct.yaml
|
|
267
267
|
tests/cassettes/test_stream_user_local.yaml
|
|
268
268
|
tests/cassettes/test_suggested_tags.yaml
|
|
269
|
+
tests/cassettes/test_timeline_disabled.yaml
|
|
269
270
|
tests/cassettes/test_timeline_link_fails.yaml
|
|
270
271
|
tests/cassettes/test_toot.yaml
|
|
271
272
|
tests/cassettes/test_translation_languages.yaml
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: Mastodon.py
|
|
3
|
-
Version: 2.2.
|
|
3
|
+
Version: 2.2.2
|
|
4
4
|
Summary: Python wrapper for the Mastodon API
|
|
5
5
|
Author-email: Lorenz Diener <lorenzd+mastodonpypypi@gmail.com>
|
|
6
6
|
License: MIT
|
|
@@ -101,6 +101,15 @@ please feel free to open an issue, a github discussion thread, or to just direct
|
|
|
101
101
|
contact @halcy@icosahedron.website on the Fediverse or .halcy on Discord - we'll
|
|
102
102
|
try to respond as quickly as possible.
|
|
103
103
|
|
|
104
|
+
Citing
|
|
105
|
+
------
|
|
106
|
+
If you use Mastodon.py as part of your research, please review and cite the following paper:
|
|
107
|
+
|
|
108
|
+
Diener et al., (2026). Mastodon.py: A Python library for the Mastodon API. *Journal of Open Source Software*, 11(120), 8946, https://doi.org/10.21105/joss.08946
|
|
109
|
+
|
|
110
|
+
.. image:: https://joss.theoj.org/papers/10.21105/joss.08946/status.svg
|
|
111
|
+
:target: https://doi.org/10.21105/joss.08946
|
|
112
|
+
|
|
104
113
|
Acknowledgements
|
|
105
114
|
----------------
|
|
106
115
|
Mastodon.py contains work by a large amount of contributors, many of which have
|
|
@@ -50,6 +50,15 @@ please feel free to open an issue, a github discussion thread, or to just direct
|
|
|
50
50
|
contact @halcy@icosahedron.website on the Fediverse or .halcy on Discord - we'll
|
|
51
51
|
try to respond as quickly as possible.
|
|
52
52
|
|
|
53
|
+
Citing
|
|
54
|
+
------
|
|
55
|
+
If you use Mastodon.py as part of your research, please review and cite the following paper:
|
|
56
|
+
|
|
57
|
+
Diener et al., (2026). Mastodon.py: A Python library for the Mastodon API. *Journal of Open Source Software*, 11(120), 8946, https://doi.org/10.21105/joss.08946
|
|
58
|
+
|
|
59
|
+
.. image:: https://joss.theoj.org/papers/10.21105/joss.08946/status.svg
|
|
60
|
+
:target: https://doi.org/10.21105/joss.08946
|
|
61
|
+
|
|
53
62
|
Acknowledgements
|
|
54
63
|
----------------
|
|
55
64
|
Mastodon.py contains work by a large amount of contributors, many of which have
|
|
@@ -11,6 +11,7 @@ access is allowed even when not authenticated if the instance admin has enabled
|
|
|
11
11
|
|
|
12
12
|
.. _timeline():
|
|
13
13
|
.. automethod:: Mastodon.timeline
|
|
14
|
+
.. automethod:: Mastodon.timeline_is_available
|
|
14
15
|
.. automethod:: Mastodon.timeline_home
|
|
15
16
|
.. automethod:: Mastodon.timeline_local
|
|
16
17
|
.. _timeline_public():
|
|
@@ -68,7 +68,7 @@ author = u'Lorenz Diener'
|
|
|
68
68
|
# The short X.Y version.
|
|
69
69
|
version = u'2.2'
|
|
70
70
|
# The full version, including alpha/beta/rc tags.
|
|
71
|
-
release = u'2.2.
|
|
71
|
+
release = u'2.2.2'
|
|
72
72
|
|
|
73
73
|
# The language for content autogenerated by Sphinx. Refer to documentation
|
|
74
74
|
# for a list of supported languages.
|
|
@@ -82,11 +82,30 @@ about who helped with which particular feature or fix in the changelog.
|
|
|
82
82
|
|
|
83
83
|
Research use and citing
|
|
84
84
|
-----------------------
|
|
85
|
-
If you use Mastodon.py
|
|
85
|
+
If you use Mastodon.py as part of your research, please review and cite the following paper:
|
|
86
86
|
|
|
87
|
-
https://
|
|
87
|
+
Diener et al., (2026). Mastodon.py: A Python library for the Mastodon API. *Journal of Open Source Software*, 11(120), 8946, https://doi.org/10.21105/joss.08946
|
|
88
88
|
|
|
89
|
-
|
|
89
|
+
BibTeX:
|
|
90
|
+
|
|
91
|
+
.. code-block:: bibtex
|
|
92
|
+
|
|
93
|
+
@article{Diener2026,
|
|
94
|
+
doi = {10.21105/joss.08946},
|
|
95
|
+
url = {https://doi.org/10.21105/joss.08946},
|
|
96
|
+
year = {2026},
|
|
97
|
+
publisher = {The Open Journal},
|
|
98
|
+
volume = {11},
|
|
99
|
+
number = {120},
|
|
100
|
+
pages = {8946},
|
|
101
|
+
author = {Diener, Lorenz and Delcourt, Corentin},
|
|
102
|
+
title = {Mastodon.py: A Python library for the Mastodon API},
|
|
103
|
+
journal = {Journal of Open Source Software}
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
Full citation metadata is also available in the `CITATION.cff <https://github.com/halcy/Mastodon.py/blob/master/CITATION.cff>`_ in the repository.
|
|
107
|
+
|
|
108
|
+
As a personal request, it is important to me to ask you to make sure that the subjects of
|
|
90
109
|
your research - fediverse users - are alright with the research you are doing on them
|
|
91
110
|
and/or that you have secured the approval of your institutions ethics board.
|
|
92
111
|
|
|
@@ -74,7 +74,7 @@ class Mastodon(MastoUtility, MastoAuthentication, MastoAccounts, MastoInstance,
|
|
|
74
74
|
"""
|
|
75
75
|
# Support level
|
|
76
76
|
__SUPPORTED_MASTODON_VERSION = "4.5.8"
|
|
77
|
-
__MASTODON_PY_VERSION = "2.
|
|
77
|
+
__MASTODON_PY_VERSION = "2.2.2"
|
|
78
78
|
|
|
79
79
|
@staticmethod
|
|
80
80
|
def get_supported_version() -> str:
|
|
@@ -254,8 +254,10 @@ class Mastodon(Internals):
|
|
|
254
254
|
self.__version_check_tried = True
|
|
255
255
|
self.__version_check_worked = True
|
|
256
256
|
|
|
257
|
-
# Cached version
|
|
257
|
+
# Cached version/instance checks
|
|
258
258
|
self.__streaming_base = None
|
|
259
|
+
self.__instance_v1_cache = None
|
|
260
|
+
self.__instance_v2_cache = None
|
|
259
261
|
|
|
260
262
|
# Versioning
|
|
261
263
|
if mastodon_version is None and self.version_check_mode != 'none':
|
|
@@ -277,6 +279,8 @@ class Mastodon(Internals):
|
|
|
277
279
|
self.__version_check_worked = None
|
|
278
280
|
self.__version_check_tried = False
|
|
279
281
|
self.__streaming_base = None
|
|
282
|
+
self.__instance_v1_cache = None
|
|
283
|
+
self.__instance_v2_cache = None
|
|
280
284
|
|
|
281
285
|
def auth_request_url(self, client_id: Optional[Union[str, PurePath]] = None, redirect_uris: str = "urn:ietf:wg:oauth:2.0:oob",
|
|
282
286
|
scopes: List[str] =_DEFAULT_SCOPES, force_login: bool = False, state: Optional[str] = None,
|
|
@@ -28,16 +28,20 @@ class Mastodon(Internals):
|
|
|
28
28
|
instance = self.__api_request('GET', '/api/v1/instance/', override_type=Instance)
|
|
29
29
|
return instance
|
|
30
30
|
|
|
31
|
-
def __instance(self) -> Instance:
|
|
31
|
+
def __instance(self, cached: bool = False) -> Instance:
|
|
32
32
|
"""
|
|
33
33
|
Internal, non-version-checking helper that does the same as instance_v1()
|
|
34
34
|
|
|
35
35
|
Silences the deprecation warnning, we are careful about fallbacks anywhere this is used.
|
|
36
36
|
If you are using this, this is your notice to do that.
|
|
37
37
|
"""
|
|
38
|
+
if cached and self.__instance_v1_cache is not None:
|
|
39
|
+
return self.__instance_v1_cache
|
|
40
|
+
|
|
38
41
|
with warnings.catch_warnings():
|
|
39
42
|
warnings.simplefilter("ignore", category=MastodonDeprecationWarning)
|
|
40
43
|
instance = self.__api_request('GET', '/api/v1/instance/', override_type=Instance)
|
|
44
|
+
self.__instance_v1_cache = instance
|
|
41
45
|
return instance
|
|
42
46
|
|
|
43
47
|
@api_version("4.0.0", "4.0.0")
|
|
@@ -49,11 +53,15 @@ class Mastodon(Internals):
|
|
|
49
53
|
"""
|
|
50
54
|
return self.__api_request('GET', '/api/v2/instance/')
|
|
51
55
|
|
|
52
|
-
def __instance_v2(self) -> InstanceV2:
|
|
56
|
+
def __instance_v2(self, cached: bool = False) -> InstanceV2:
|
|
53
57
|
"""
|
|
54
58
|
Internal, non-version-checking helper that does the same as instance_v2()
|
|
55
59
|
"""
|
|
60
|
+
if cached and self.__instance_v2_cache is not None:
|
|
61
|
+
return self.__instance_v2_cache
|
|
62
|
+
|
|
56
63
|
instance = self.__api_request('GET', '/api/v2/instance/', override_type=InstanceV2)
|
|
64
|
+
self.__instance_v2_cache = instance
|
|
57
65
|
return instance
|
|
58
66
|
|
|
59
67
|
@api_version("1.1.0", "4.0.0")
|
|
@@ -19,7 +19,7 @@ import warnings
|
|
|
19
19
|
from mastodon.versions import parse_version_string
|
|
20
20
|
from mastodon.errors import MastodonNetworkError, MastodonIllegalArgumentError, MastodonRatelimitError, MastodonNotFoundError, \
|
|
21
21
|
MastodonUnauthorizedError, MastodonInternalServerError, MastodonBadGatewayError, MastodonServiceUnavailableError, \
|
|
22
|
-
MastodonGatewayTimeoutError, MastodonServerError, MastodonAPIError, MastodonMalformedEventError, MastodonDeprecationWarning
|
|
22
|
+
MastodonGatewayTimeoutError, MastodonServerError, MastodonAPIError, MastodonMalformedEventError, MastodonDeprecationWarning, MastodonWarning
|
|
23
23
|
from mastodon.compat import urlparse, magic, PurePath, Path
|
|
24
24
|
from mastodon.defaults import _DEFAULT_STREAM_TIMEOUT, _DEFAULT_STREAM_RECONNECT_WAIT_SEC
|
|
25
25
|
from mastodon.return_types import AttribAccessDict, PaginatableList, try_cast_recurse
|
|
@@ -27,8 +27,55 @@ from mastodon.return_types import *
|
|
|
27
27
|
|
|
28
28
|
###
|
|
29
29
|
# Internal helpers, dragons probably
|
|
30
|
+
# timeline_is_available is exported and can be used, it is here for import circularity reasons
|
|
30
31
|
###
|
|
31
32
|
class Mastodon():
|
|
33
|
+
def timeline_is_available(self, timeline: str = "public", local: bool = False, remote: bool = False,
|
|
34
|
+
with_auth: bool = False, fail_hard: bool = False) -> bool:
|
|
35
|
+
"""
|
|
36
|
+
Determine whether a given public timeline feed variant is available on this instance.
|
|
37
|
+
|
|
38
|
+
Supported parameter values are as in `timeline()`.
|
|
39
|
+
|
|
40
|
+
Set `with_auth` to True to return True for timelines that require login, not just fully public ones.
|
|
41
|
+
Set `fail_hard` to True to raise an exception if we fail to determine availability, instead of silently returning True.
|
|
42
|
+
"""
|
|
43
|
+
timeline_to_feed_key = {
|
|
44
|
+
"public": "live_feeds",
|
|
45
|
+
"hashtag": "hashtag_feeds",
|
|
46
|
+
"trending_links": "trending_link_feeds",
|
|
47
|
+
}
|
|
48
|
+
if timeline not in timeline_to_feed_key:
|
|
49
|
+
if fail_hard:
|
|
50
|
+
raise MastodonIllegalArgumentError(f"Unknown timeline: {timeline}")
|
|
51
|
+
return True
|
|
52
|
+
feed_key = timeline_to_feed_key[timeline]
|
|
53
|
+
|
|
54
|
+
valid_values = ("public")
|
|
55
|
+
if with_auth:
|
|
56
|
+
valid_values = ("authenticated", "public")
|
|
57
|
+
|
|
58
|
+
try:
|
|
59
|
+
instance_v2_info = self.__instance_v2(cached=True)
|
|
60
|
+
|
|
61
|
+
timelines_access = instance_v2_info["configuration"]["timelines_access"]
|
|
62
|
+
feed_config = timelines_access[feed_key]
|
|
63
|
+
local_available = feed_config["local"] in valid_values
|
|
64
|
+
remote_available = feed_config["remote"] in valid_values
|
|
65
|
+
|
|
66
|
+
if local and remote:
|
|
67
|
+
return local_available and remote_available
|
|
68
|
+
elif local:
|
|
69
|
+
return local_available
|
|
70
|
+
elif remote:
|
|
71
|
+
return remote_available
|
|
72
|
+
else:
|
|
73
|
+
return local_available or remote_available
|
|
74
|
+
except Exception as e:
|
|
75
|
+
if fail_hard:
|
|
76
|
+
raise MastodonAPIError(f"Failed to determine timeline availability for '{timeline}'.") from e
|
|
77
|
+
return True
|
|
78
|
+
|
|
32
79
|
def __datetime_to_epoch(self, date_time: datetime) -> float:
|
|
33
80
|
"""
|
|
34
81
|
Converts a python datetime to unix epoch, accounting for
|
|
@@ -395,16 +442,22 @@ class Mastodon():
|
|
|
395
442
|
"""
|
|
396
443
|
if self.__streaming_base is not None:
|
|
397
444
|
return self.__streaming_base
|
|
445
|
+
|
|
446
|
+
if not self.timeline_is_available("public", with_auth=self.access_token is not None, fail_hard=False):
|
|
447
|
+
warnings.warn(
|
|
448
|
+
"Public timeline appears to be unavailable on this instance for the current auth context; streaming may fail.",
|
|
449
|
+
MastodonWarning
|
|
450
|
+
)
|
|
398
451
|
|
|
399
452
|
# Try to support implementations that have no v1 endpoint (Sharkey does this)
|
|
400
453
|
streaming_api_url = None
|
|
401
454
|
try:
|
|
402
|
-
instance = self.__instance()
|
|
455
|
+
instance = self.__instance(cached=True)
|
|
403
456
|
if "streaming_api" in instance["urls"]:
|
|
404
457
|
streaming_api_url = instance["urls"]["streaming_api"]
|
|
405
458
|
except:
|
|
406
459
|
try:
|
|
407
|
-
streaming_api_url = self.__instance_v2().configuration.urls.streaming
|
|
460
|
+
streaming_api_url = self.__instance_v2(cached=True).configuration.urls.streaming
|
|
408
461
|
except:
|
|
409
462
|
pass
|
|
410
463
|
|
|
@@ -417,12 +470,15 @@ class Mastodon():
|
|
|
417
470
|
elif parse.scheme == 'ws':
|
|
418
471
|
url = "http://" + parse.netloc
|
|
419
472
|
else:
|
|
473
|
+
if parse.scheme in ('http', 'https'):
|
|
474
|
+
url = parse.scheme + "://" + parse.netloc
|
|
420
475
|
raise MastodonAPIError(
|
|
421
476
|
f"Could not parse streaming api location returned from server: {streaming_api_url}."
|
|
422
477
|
)
|
|
423
478
|
else:
|
|
424
479
|
url = self.api_base_url
|
|
425
480
|
assert not url is None
|
|
481
|
+
self.__streaming_base = url
|
|
426
482
|
return url
|
|
427
483
|
|
|
428
484
|
def __stream(self, endpoint, listener, params={}, run_async=False, timeout=_DEFAULT_STREAM_TIMEOUT, reconnect_async=False, reconnect_async_wait_sec=_DEFAULT_STREAM_RECONNECT_WAIT_SEC):
|
|
@@ -21,10 +21,10 @@ class Mastodon(Internals):
|
|
|
21
21
|
raise MastodonVersionError("Advanced search parameters require Mastodon 2.8.0+")
|
|
22
22
|
|
|
23
23
|
@api_version("1.1.0", "2.8.0")
|
|
24
|
-
def search(self, q: str, resolve: bool = True, result_type: Optional[str] = None,
|
|
25
|
-
account_id: Optional[Union[Account, IdType]] = None, offset: Optional[int] = None,
|
|
26
|
-
min_id: Optional[IdType] = None, max_id: Optional[IdType] = None,
|
|
27
|
-
exclude_unreviewed: bool = True) -> Union[Search, SearchV2]:
|
|
24
|
+
def search(self, q: str, resolve: bool = True, result_type: Optional[str] = None,
|
|
25
|
+
account_id: Optional[Union[Account, IdType]] = None, offset: Optional[int] = None,
|
|
26
|
+
min_id: Optional[IdType] = None, max_id: Optional[IdType] = None,
|
|
27
|
+
exclude_unreviewed: bool = True, limit: Optional[int] = None) -> Union[Search, SearchV2]:
|
|
28
28
|
"""
|
|
29
29
|
Fetch matching hashtags, accounts and statuses. Will perform webfinger
|
|
30
30
|
lookups if resolve is True. Full-text search is only enabled if
|
|
@@ -42,6 +42,10 @@ class Mastodon(Internals):
|
|
|
42
42
|
those that have been reviewed by moderators. It is on by default. When using the
|
|
43
43
|
v1 search API (pre 2.4.1), it is ignored.
|
|
44
44
|
|
|
45
|
+
`limit` caps the number of results returned per category (accounts, statuses
|
|
46
|
+
and hashtags). It is only forwarded to the server when using the v2 search API
|
|
47
|
+
(pre 2.4.1 does not support it and it is silently ignored on search_v1).
|
|
48
|
+
|
|
45
49
|
Will use search_v1 (no tags in return values) on Mastodon versions before
|
|
46
50
|
2.4.1), search_v2 otherwise. Parameters other than resolve are only available
|
|
47
51
|
on Mastodon 2.8.0 or above - this function will throw a MastodonVersionError
|
|
@@ -49,7 +53,7 @@ class Mastodon(Internals):
|
|
|
49
53
|
number will be used for this to avoid uneccesary requests.
|
|
50
54
|
"""
|
|
51
55
|
if self.verify_minimum_version("2.4.1", cached=True):
|
|
52
|
-
return self.search_v2(q, resolve=resolve, result_type=result_type, account_id=account_id, offset=offset, min_id=min_id, max_id=max_id, exclude_unreviewed=exclude_unreviewed)
|
|
56
|
+
return self.search_v2(q, resolve=resolve, result_type=result_type, account_id=account_id, offset=offset, min_id=min_id, max_id=max_id, exclude_unreviewed=exclude_unreviewed, limit=limit)
|
|
53
57
|
else:
|
|
54
58
|
self.__ensure_search_params_acceptable(account_id, offset, min_id, max_id)
|
|
55
59
|
return self.search_v1(q, resolve=resolve)
|
|
@@ -68,12 +72,12 @@ class Mastodon(Internals):
|
|
|
68
72
|
return self.__api_request('GET', '/api/v1/search', params)
|
|
69
73
|
|
|
70
74
|
@api_version("2.4.1", "2.8.0")
|
|
71
|
-
def search_v2(self, q, resolve: bool = True, result_type: Optional[str] = None,
|
|
72
|
-
account_id: Optional[Union[Account, IdType]] = None, offset: Optional[int] = None,
|
|
73
|
-
min_id: Optional[IdType] = None, max_id: Optional[IdType] = None,
|
|
74
|
-
exclude_unreviewed: bool = True) -> SearchV2:
|
|
75
|
+
def search_v2(self, q, resolve: bool = True, result_type: Optional[str] = None,
|
|
76
|
+
account_id: Optional[Union[Account, IdType]] = None, offset: Optional[int] = None,
|
|
77
|
+
min_id: Optional[IdType] = None, max_id: Optional[IdType] = None,
|
|
78
|
+
exclude_unreviewed: bool = True, limit: Optional[int] = None) -> SearchV2:
|
|
75
79
|
"""
|
|
76
|
-
Identical to `search_v1()`, except in that it returns tags as objects,
|
|
80
|
+
Identical to `search_v1()`, except in that it returns tags as objects,
|
|
77
81
|
has more parameters, and resolves by default.
|
|
78
82
|
|
|
79
83
|
For more details documentation, please see `search()`
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
-
|
|
1
|
+
# streaming_endpoints.py - endpoints for getting streaming data using the HTTP SSE streaming API
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
import warnings
|
|
4
|
+
|
|
5
|
+
from mastodon.errors import MastodonIllegalArgumentError, MastodonWarning
|
|
4
6
|
from mastodon.defaults import _DEFAULT_STREAM_TIMEOUT, _DEFAULT_STREAM_RECONNECT_WAIT_SEC
|
|
5
7
|
from mastodon.utility import api_version
|
|
6
8
|
|
|
@@ -27,6 +29,12 @@ class Mastodon(Internals):
|
|
|
27
29
|
Set `local` to True to only get local statuses.
|
|
28
30
|
Set `remote` to True to only get remote statuses.
|
|
29
31
|
"""
|
|
32
|
+
if not self.timeline_is_available("public", local=local, remote=remote, with_auth=self.access_token is not None, fail_hard=False):
|
|
33
|
+
warnings.warn(
|
|
34
|
+
"Public stream appears to be unavailable on this instance for the current auth context.",
|
|
35
|
+
MastodonWarning
|
|
36
|
+
)
|
|
37
|
+
|
|
30
38
|
base = '/api/v1/streaming/public'
|
|
31
39
|
if local:
|
|
32
40
|
base += '/local'
|
|
@@ -56,6 +64,13 @@ class Mastodon(Internals):
|
|
|
56
64
|
"""
|
|
57
65
|
if tag.startswith("#"):
|
|
58
66
|
raise MastodonIllegalArgumentError("Tag parameter should omit leading #")
|
|
67
|
+
|
|
68
|
+
if not self.timeline_is_available("hashtag", local=local, with_auth=self.access_token is not None, fail_hard=False):
|
|
69
|
+
warnings.warn(
|
|
70
|
+
"Hashtag stream appears to be unavailable on this instance for the current auth context.",
|
|
71
|
+
MastodonWarning
|
|
72
|
+
)
|
|
73
|
+
|
|
59
74
|
base = '/api/v1/streaming/hashtag'
|
|
60
75
|
if local:
|
|
61
76
|
base += '/local'
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
# timeline.py - endpoints for reading various different timelines
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
import warnings
|
|
4
|
+
|
|
5
|
+
from mastodon.errors import MastodonIllegalArgumentError, MastodonNotFoundError, MastodonWarning
|
|
4
6
|
from mastodon.utility import api_version
|
|
5
7
|
|
|
6
8
|
from mastodon.internals import Mastodon as Internals
|
|
@@ -29,6 +31,38 @@ class Mastodon(Internals):
|
|
|
29
31
|
|
|
30
32
|
See <https://docs.joinmastodon.org/methods/timelines/> for a description of the parameters.
|
|
31
33
|
"""
|
|
34
|
+
check_timeline = None
|
|
35
|
+
check_local = local
|
|
36
|
+
check_remote = remote
|
|
37
|
+
|
|
38
|
+
if timeline == "public":
|
|
39
|
+
check_timeline = "public"
|
|
40
|
+
elif timeline == "local":
|
|
41
|
+
check_timeline = "public"
|
|
42
|
+
check_local = True
|
|
43
|
+
check_remote = False
|
|
44
|
+
elif timeline.startswith("tag/"):
|
|
45
|
+
check_timeline = "hashtag"
|
|
46
|
+
elif timeline.startswith("link"):
|
|
47
|
+
check_timeline = "trending_links"
|
|
48
|
+
|
|
49
|
+
if check_timeline is not None:
|
|
50
|
+
available = self.timeline_is_available(check_timeline,
|
|
51
|
+
local=check_local,
|
|
52
|
+
remote=check_remote,
|
|
53
|
+
with_auth=self.access_token is not None,
|
|
54
|
+
fail_hard=False,
|
|
55
|
+
)
|
|
56
|
+
if not available:
|
|
57
|
+
warnings.warn(
|
|
58
|
+
f"Timeline '{timeline}' appears to be unavailable on this instance for the current auth context.",
|
|
59
|
+
MastodonWarning
|
|
60
|
+
)
|
|
61
|
+
del available
|
|
62
|
+
del check_timeline
|
|
63
|
+
del check_local
|
|
64
|
+
del check_remote
|
|
65
|
+
|
|
32
66
|
params_initial = locals()
|
|
33
67
|
|
|
34
68
|
if not local:
|
|
@@ -40,6 +74,7 @@ class Mastodon(Internals):
|
|
|
40
74
|
if not only_media:
|
|
41
75
|
del params_initial['only_media']
|
|
42
76
|
|
|
77
|
+
|
|
43
78
|
if timeline == "local":
|
|
44
79
|
timeline = "public"
|
|
45
80
|
params_initial['local'] = True
|
|
@@ -31,43 +31,44 @@ class Mastodon(Internals):
|
|
|
31
31
|
"""
|
|
32
32
|
self.lang = lang
|
|
33
33
|
|
|
34
|
-
def retrieve_mastodon_version(self) -> str:
|
|
34
|
+
def retrieve_mastodon_version(self, fail_hard=False) -> str:
|
|
35
35
|
"""
|
|
36
36
|
Determine installed Mastodon version and set major, minor and patch (not including RC info) accordingly.
|
|
37
37
|
|
|
38
38
|
Returns the version string, possibly including rc info.
|
|
39
39
|
"""
|
|
40
40
|
try:
|
|
41
|
-
version_str = self.__normalize_version_string(
|
|
42
|
-
self.__instance()["version"])
|
|
41
|
+
version_str = self.__normalize_version_string(self.__instance(cached=True)["version"])
|
|
43
42
|
self.__version_check_worked = True
|
|
44
43
|
except Exception as e:
|
|
44
|
+
if fail_hard:
|
|
45
|
+
raise MastodonVersionError("Failed to retrieve Mastodon version") from e
|
|
45
46
|
# instance() was added in 1.1.0, so our best guess is 1.0.0.
|
|
46
47
|
version_str = "1.0.0"
|
|
47
48
|
self.__version_check_worked = False
|
|
48
|
-
self.mastodon_major, self.mastodon_minor, self.mastodon_patch = parse_version_string(
|
|
49
|
-
version_str)
|
|
49
|
+
self.mastodon_major, self.mastodon_minor, self.mastodon_patch = parse_version_string(version_str)
|
|
50
50
|
|
|
51
51
|
# If the instance has an API version, we store that as well.
|
|
52
52
|
# If we have a version >= 4.3.0 but no API version, we throw a warning that this is a Weird Implementation,
|
|
53
53
|
# which might help with adoption of the API versioning or at least give us a better picture of how it is going.
|
|
54
54
|
found_api_version = False
|
|
55
55
|
try:
|
|
56
|
-
instance_v2_info = self.__instance_v2()
|
|
57
|
-
if "api_versions" in instance_v2_info and instance_v2_info["api_versions"]:
|
|
56
|
+
instance_v2_info = self.__instance_v2(cached=True)
|
|
57
|
+
if instance_v2_info and "api_versions" in instance_v2_info and instance_v2_info["api_versions"]:
|
|
58
58
|
if "mastodon" in instance_v2_info["api_versions"]:
|
|
59
59
|
self.mastodon_api_version = int(
|
|
60
60
|
instance_v2_info["api_versions"]["mastodon"])
|
|
61
61
|
found_api_version = True
|
|
62
|
-
except
|
|
63
|
-
|
|
64
|
-
|
|
62
|
+
except Exception as e:
|
|
63
|
+
# Not the worlds most important issue if this fails,
|
|
64
|
+
# so we silently eat it, unless requested not to
|
|
65
|
+
if fail_hard:
|
|
66
|
+
raise MastodonVersionError("Failed to retrieve Mastodon version") from e
|
|
65
67
|
pass
|
|
66
68
|
|
|
67
69
|
self.__version_check_tried = True
|
|
68
70
|
if not found_api_version and self.verify_minimum_version("4.3.0", cached=True):
|
|
69
|
-
warnings.warn(
|
|
70
|
-
"Mastodon version is detected as >= 4.3.0, but no API version found. Please report this.")
|
|
71
|
+
warnings.warn("Mastodon version is detected as >= 4.3.0, but no API version found. Please report this.")
|
|
71
72
|
return version_str
|
|
72
73
|
|
|
73
74
|
def verify_minimum_version(self, version_str: str, cached: bool = False) -> bool:
|