Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Team class using legacy API endpoints #2946

Open
mxmehl opened this issue Apr 8, 2024 · 1 comment
Open

Team class using legacy API endpoints #2946

mxmehl opened this issue Apr 8, 2024 · 1 comment

Comments

@mxmehl
Copy link
Contributor

mxmehl commented Apr 8, 2024

I noticed that the Team class uses some legacy endpoints.

One example is Team.add_membership(), which calls PUT /teams/{id}/memberships/{user}. According to the REST API documentation, this endpoint is legacy:

Deprecation Notice: This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new Add or update team membership for a user endpoint.

PUT /orgs/{org}/teams/{team_slug}/memberships/{username}

Is this already on your radar? How do you generally handle such deprecations?

If this is a todo item for you, I'm not sure whether I can execute it alone. I already made a smaller contribution to this project, but I wouldn't know how to make such a big transition as definitely more than just this endpoint is deprecated.

@EnricoMi
Copy link
Collaborator

I think that should simply be fixed by changing the URL used. Updating the test data might be the most elaborate part.

You could draft a PR changing the URLs first and I can look into test data. Please consider all /team/{id} urls.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants