Skip to content

Commit

Permalink
Updated python-client-gen now has deprecation warnings for deprecated…
Browse files Browse the repository at this point in the history
… routes.
  • Loading branch information
braincore committed May 29, 2016
1 parent f12f276 commit b314dab
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 1 deletion.
13 changes: 13 additions & 0 deletions dropbox/base.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# Auto-generated by Stone, do not modify.

from abc import ABCMeta, abstractmethod
import warnings

from . import (
async,
Expand Down Expand Up @@ -774,6 +775,10 @@ def files_upload_session_append(self,
If this raises, ApiError.reason is of type:
:class:`dropbox.files.UploadSessionLookupError`
"""
warnings.warn(
'upload_session/append is deprecated. Use upload_session/append_v2.',
DeprecationWarning,
)
arg = files.UploadSessionCursor(session_id,
offset)
r = self.request(
Expand Down Expand Up @@ -982,6 +987,10 @@ def sharing_create_shared_link(self,
If this raises, ApiError.reason is of type:
:class:`dropbox.sharing.CreateSharedLinkError`
"""
warnings.warn(
'create_shared_link is deprecated. Use create_shared_link_with_settings.',
DeprecationWarning,
)
arg = sharing.CreateSharedLinkArg(path,
short_url,
pending_upload)
Expand Down Expand Up @@ -1165,6 +1174,10 @@ def sharing_get_shared_links(self,
If this raises, ApiError.reason is of type:
:class:`dropbox.sharing.GetSharedLinksError`
"""
warnings.warn(
'get_shared_links is deprecated. Use list_shared_links.',
DeprecationWarning,
)
arg = sharing.GetSharedLinksArg(path)
r = self.request(
sharing.get_shared_links,
Expand Down
9 changes: 9 additions & 0 deletions dropbox/base_team.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# Auto-generated by Stone, do not modify.

from abc import ABCMeta, abstractmethod
import warnings

from . import (
async,
Expand Down Expand Up @@ -119,6 +120,10 @@ def team_devices_list_team_devices(self,
If this raises, ApiError.reason is of type:
:class:`dropbox.team.ListTeamDevicesError`
"""
warnings.warn(
'devices/list_team_devices is deprecated. Use devices/list_members_devices.',
DeprecationWarning,
)
arg = team.ListTeamDevicesArg(cursor,
include_web_sessions,
include_desktop_clients,
Expand Down Expand Up @@ -519,6 +524,10 @@ def team_linked_apps_list_team_linked_apps(self,
If this raises, ApiError.reason is of type:
:class:`dropbox.team.ListTeamAppsError`
"""
warnings.warn(
'linked_apps/list_team_linked_apps is deprecated. Use linked_apps/list_members_linked_apps.',
DeprecationWarning,
)
arg = team.ListTeamAppsArg(cursor)
r = self.request(
team.linked_apps_list_team_linked_apps,
Expand Down
2 changes: 1 addition & 1 deletion stone

0 comments on commit b314dab

Please sign in to comment.