Skip to content

Conversation

@giner
Copy link

@giner giner commented Jan 31, 2025

Resource: github_repository_file

When deleting a file errors (such as 409 Could not delete file: Changes must be made through a pull request) should not be silently ignored leaving the file undeleted from the repo but deleted from the state

Resolves #2464


Before the change?

Resource github_repository_file ignores any errors when deleting files which results in inconsistencies

After the change?

Resource github_repository_file stops on errors if any when deleting files

Pull request checklist

  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been reviewed and added / updated if needed (for bug fixes / features)

Does this introduce a breaking change?

Please see our docs on breaking changes to help!

  • Yes
  • No

@giner
Copy link
Author

giner commented Jan 31, 2025

I've just found a similar change which has not been merged yet #2465

@nickfloyd nickfloyd moved this from 🆕 Triage to 👀 In review in 🧰 Octokit Active Feb 27, 2025
@Arlington1985
Copy link

There should be functionality to be able to mute error as well. For example in our setup we only want to create file but not deleted with it.

When deleting a file errors (such as "409 Could not delete file: Changes must be made through a pull request") should not be silently ignored leaving the file undeleted from the repo but deleted from the state
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

Successfully merging this pull request may close these issues.

[BUG]: Deleting github_repository_file resource might not remove the file

2 participants