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

Project Team not updating #67

Closed
barroca opened this issue May 26, 2020 · 10 comments · Fixed by #172
Closed

Project Team not updating #67

barroca opened this issue May 26, 2020 · 10 comments · Fixed by #172
Assignees
Labels

Comments

@barroca
Copy link

barroca commented May 26, 2020

Hello, when I run a plan to change the team for a project, i see the changes like this:

sentry_project.serviceA team: "teamA" => "teamB"

But when applying they don't affect Sentry (I cannot see the change on their side).

I have a guess that we are missing the team information on the code here:

func resourceSentryProjectUpdate(d *schema.ResourceData, meta interface{}) error {

@brandonweng-db
Copy link

Also seeing the same thing for our use case.

Would this just be adding this in resourceSentryProjectUpdate?

	platform := d.Get("team").(string)
	if platform != "" {
		params.Team = team
	}

@taiidani
Copy link

Running into the same problem on my side. The apply will no-op and the drift will persist into the next plan.

Slight iteration on @brandonweng-db

team := d.Get("team").(string)
if team != "" {
    params.Team = team
}

@bilalahmad99
Copy link

facing same issue

@semangard
Copy link

same issue

@jianyuan
Copy link
Owner

It seems that the team name has been deprecated. Sentry just needs a unique slug, which is reflected in the web UI. I will look into this.

@jianyuan jianyuan self-assigned this Aug 30, 2021
@jianyuan jianyuan added the bug label Aug 30, 2021
@everops-billm
Copy link

I'm having this issue too. It would also be helpful to be able to add additional teams to a project using the project provider, like you can from the web UI, or conversely add projects to the teams resources, also like you can do in the Web UI.

@jebeaudet
Copy link

Any update on this? Thanks

@mogagnon
Copy link

The problem comes from the way the API handles the addition of a team. Updating a team with the same call the provider does is deprecated.

The slug of new team for the project. Note, will be deprecated soon when multiple teams can have access to a project.

As far as I understand, the new way of managing a team for a project is with those two calls.

POST /projects/org_slug/project_slug/teams/teams_slug
DELETE /projects/org_slug/project_slug/teams/teams_slug

I have a fix on the way but as @everops-billm mentioned it would be nice to support multiple teams

@mogagnon
Copy link

Follows up for those that are interested. There are two pr to fix this bug, one is in sentry-go and the other one which is still a draft is here.

@jianyuan jianyuan linked a pull request Jun 26, 2022 that will close this issue
@jianyuan
Copy link
Owner

Thanks for your draft PR, @mogagnon! I've adapted your changes to #172.

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

Successfully merging a pull request may close this issue.

9 participants