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

modified: src/automerge.py #5

Merged
merged 11 commits into from
Dec 4, 2024

Conversation

F-WRunTime
Copy link
Member

@F-WRunTime F-WRunTime commented Nov 27, 2024

  • Simplified Check: The updated code retrieves the combined status of the latest commit directly.
  • Single Condition: It checks if the combined status state is 'success' to determine if all checks have passed.
  • Logging: It logs a single message if the checks are not passing, indicating the overall state.

Benefits of the Change:

  • Efficiency: The new approach reduces the complexity by avoiding the need to manually iterate over each required check.
  • Readability: The code is more concise and easier to understand, focusing on the overall status rather than individual checks.
  • Performance: By using the combined status, it potentially reduces the number of API calls and processing required.
  • This change streamlines the process of determining if a PR is ready to be merged based on its status checks, making the code more maintainable and efficient.

Minimum requirements
image
image
image
image

- Modify api end points used to check status. Previous did not have a
  permission option with fine-grained tokens.
- This reduces permissioni requirements to use automerger
@F-WRunTime F-WRunTime self-assigned this Nov 27, 2024
- Update tests to use the new less permissive token.
- Checking the 'chech' statuses per commit
- Ccombined commit was not
  always accurate to the mergeable state of  a PR due to annotations and
other items checked not important to basic check passed? Approved? Up to
datae? Yes? Merge.
src/automerge.py Outdated Show resolved Hide resolved
- Rework logic.
- New dependency for infrastructure to run. Install Github App
  AutomergePR Permission Control to have access to check statuses. Bug
in Github fine-grained tokens or deprecated documentaiton never removed.
- Updating workflow test to use the GH APP credentials
modified:   README.md
- Modifying instructions and informating need for github and what
  permissions are needed for the github App
README.md Outdated Show resolved Hide resolved
Grammar fix in readme.

Co-authored-by: Tamás Tóth <[email protected]>
@F-WRunTime F-WRunTime merged commit 60aae35 into master Dec 4, 2024
2 checks passed
@F-WRunTime F-WRunTime deleted the feature/check-status-permissions-api branch December 4, 2024 19:51
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.

2 participants