zulip / python-zulip-api

Python library for the Zulip API.
https://zulip.com/api/
Apache License 2.0
350 stars 356 forks source link

API: Rename list_subscriptions to get_subscriptions. #665

Closed rht closed 3 years ago

rht commented 3 years ago

I replaced every occurrences of list_subscriptions and list-subscriptions except for https://github.com/zulip/python-zulip-api/blob/5b5fda2354f4488693f0f00def68eb8a9b426e67/zulip_bots/zulip_bots/bots/baremetrics/test_baremetrics.py#L68-L75 and list-subscriptions in baremetrics.

timabbott commented 3 years ago

Nice, merged, thanks @rht!

I suspect list_members has the same issue.

Oh, and now that I think about it, check the filenames in api/examples.

rht commented 3 years ago

I can't find list_members. There is get_members, but is marked as deprecated in https://github.com/zulip/python-zulip-api/blob/61abb4f59cefdf57fe5cce0c1b6fdaf15d93524e/zulip/zulip/__init__.py#L1241

        # This exists for backwards-compatibility; we renamed this
        # function get_users for consistency with the rest of the API.
        # Later, we may want to add a warning for clients using this
        # legacy name.
rht commented 3 years ago

Later, we may want to add a warning for clients using this legacy name.

Why later? Why not now?