1111from citrine ._rest .resource import Resource , ResourceTypeEnum
1212from citrine ._serialization import properties
1313from citrine ._session import Session
14- from citrine ._utils .functions import format_escaped_url , use_teams , v1_deprecation_warn
14+ from citrine ._utils .functions import format_escaped_url , use_teams
1515from citrine .exceptions import NonRetryableException , ModuleRegistrationFailedException
1616from citrine .resources .api_error import ApiError
1717from citrine .resources .branch import BranchCollection
@@ -317,8 +317,6 @@ def pull_in_resource(self, *, resource: Resource):
317317 return True
318318
319319 @use_teams ("team.share" )
320- @v1_deprecation_warn ("This method will be deprecated with the Team's release. \
321- Once Teams are released, use team.share" )
322320 def share (self , * ,
323321 resource : Optional [Resource ] = None ,
324322 project_id : Optional [Union [str , UUID ]] = None ,
@@ -360,7 +358,6 @@ def share(self, *,
360358 })
361359
362360 @use_teams ("project.publish" )
363- @v1_deprecation_warn ()
364361 def transfer_resource (self , * , resource : Resource ,
365362 receiving_project_uid : Union [str , UUID ]) -> bool :
366363 """
@@ -394,8 +391,6 @@ def transfer_resource(self, *, resource: Resource,
394391 return True
395392
396393 @use_teams ("project.publish" )
397- @v1_deprecation_warn ("This method will be deprecated with the Team's release. \
398- Once Teams are released, use project.publish" )
399394 def make_public (self , resource : Resource ) -> bool :
400395 """
401396 Grant public access to a resource owned by this project.
@@ -421,8 +416,6 @@ def make_public(self, resource: Resource) -> bool:
421416 return True
422417
423418 @use_teams ("project.un_publish" )
424- @v1_deprecation_warn ("This method will be deprecated with the Team's release. \
425- Once Teams are released, use project.un_publish" )
426419 def make_private (self , resource : Resource ) -> bool :
427420 """
428421 Remove public access for a resource owned by this project.
@@ -511,8 +504,7 @@ def owned_table_config_ids(self) -> List[str]:
511504 result = self .session .get_resource (f"{ self ._path ()} /table_definition_ids" )
512505 return result ["table_definition_ids" ]
513506
514- @v1_deprecation_warn ("This method will be deprecated with the Team's release. \
515- Once Teams are released, use team.list_members" , True )
507+ @use_teams ("team.list_members" , deprecated = True )
516508 def list_members (self ) -> Union [List [ProjectMember ], List ["TeamMember" ]]:
517509 """
518510 List all of the members in the current project.
@@ -538,8 +530,6 @@ def list_members(self) -> Union[List[ProjectMember], List["TeamMember"]]:
538530 for m in members ]
539531
540532 @use_teams ("team.update_user_action" )
541- @v1_deprecation_warn ("This method will be deprecated with the Team's release. \
542- Once Teams are released, use team.update_user_action" )
543533 def update_user_role (self , * , user_uid : Union [str , UUID ], role : ROLES , actions : ACTIONS = []):
544534 """
545535 Update a User's role and action permissions in the Project.
@@ -559,8 +549,6 @@ def update_user_role(self, *, user_uid: Union[str, UUID], role: ROLES, actions:
559549 return True
560550
561551 @use_teams ("team.add_user" )
562- @v1_deprecation_warn ("This method will be deprecated with the Team's release. \
563- Once Teams are released, use team.add_user" )
564552 def add_user (self , user_uid : Union [str , UUID ]):
565553 """
566554 Add a User to a Project.
@@ -579,8 +567,6 @@ def add_user(self, user_uid: Union[str, UUID]):
579567 return True
580568
581569 @use_teams ("team.remove_user" )
582- @v1_deprecation_warn ("This method will be deprecated with the Team's release. \
583- Once Teams are released, use team.remove_user" )
584570 def remove_user (self , user_uid : Union [str , UUID ]) -> bool :
585571 """
586572 Remove a User from a Project.
@@ -697,8 +683,7 @@ def _register_in_team(self, name: str, *, description: Optional[str] = None):
697683 except NonRetryableException as e :
698684 raise ModuleRegistrationFailedException (project .__class__ .__name__ , e )
699685
700- @v1_deprecation_warn ("This method will be deprecated with the Team's release. \
701- Once Teams are released, use team.projects.register" , True )
686+ @use_teams ("team.projects.register" , deprecated = True )
702687 def register (self , name : str , * , description : Optional [str ] = None ) -> Project :
703688 """
704689 Create and upload new project.
0 commit comments