-
-
Notifications
You must be signed in to change notification settings - Fork 82
Prevent disabled configured vote sites from being auto-enabled #1546
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
Closed
Closed
Changes from all commits
Commits
Show all changes
22 commits
Select commit
Hold shift + click to select a range
0ae6645
Preserve disabled vote site configuration
BenCodez d9a2aa7
Skip queued offline votes for disabled sites
BenCodez 5a0b1d1
Harden vote-delay rejection compatibility and replay retention
BenCodez 0abb8d2
Harden vote-delay rejection compatibility and replay retention
BenCodez b718034
Keep compatibility changes scoped to the vote-site fix
BenCodez 8370a4e
Keep compatibility changes scoped to the vote-site fix
BenCodez efc9184
Exclude unavailable Velocity Brigadier snapshot
BenCodez 67590de
Exclude unavailable Velocity Brigadier from Velocity API
BenCodez 2ef7939
Fix Velocity annotation processor dependency resolution
BenCodez 536eda8
Avoid validating disabled vote-site keys during lookups
BenCodez c2865c2
Avoid validating disabled vote-site keys during lookups
BenCodez ff0d5cd
Address remaining Codex review findings
BenCodez e00a756
Address remaining Codex review findings
BenCodez 52803a8
Filter malformed raw vote-site entries
BenCodez 1637784
Sync Maven dependency configuration with master
BenCodez 7889fa3
Normalize and validate configured vote-site aliases
BenCodez ef057f3
Add disabled vote-site lookup regression tests
BenCodez 9be4317
Merge master into disabled vote-site fix
BenCodez a2cc69b
Add one-shot PR 1546 line-ending cleanup
BenCodez e7a9deb
Trigger one-shot PR 1546 line-ending cleanup
BenCodez 3e92dd6
Add one-shot PR 1546 line-ending cleanup test
BenCodez d72e62f
Run verified PR 1546 line-ending cleanup
BenCodez File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,59 @@ | ||
| name: PR 1546 line-ending cleanup | ||
| # Registered in a prior commit so this push reliably triggers the one-shot workflow. | ||
|
|
||
| on: | ||
| push: | ||
| branches: | ||
| - codex/review-pr-response | ||
|
|
||
| permissions: | ||
| contents: write | ||
|
|
||
| jobs: | ||
| normalize: | ||
| if: github.actor != 'github-actions[bot]' | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Check out PR branch | ||
| uses: actions/checkout@v4 | ||
| with: | ||
| ref: codex/review-pr-response | ||
| fetch-depth: 0 | ||
|
|
||
| - name: Restore CRLF endings in the two affected source files | ||
| shell: python | ||
| run: | | ||
| from pathlib import Path | ||
|
|
||
| paths = [ | ||
| Path("VotingPlugin/src/main/java/com/bencodez/votingplugin/config/ConfigVoteSites.java"), | ||
| Path("VotingPlugin/src/main/java/com/bencodez/votingplugin/user/VotingPluginUser.java"), | ||
| ] | ||
| for path in paths: | ||
| data = path.read_bytes() | ||
| normalized = data.replace(b"\r\n", b"\n").replace(b"\r", b"\n") | ||
| path.write_bytes(normalized.replace(b"\n", b"\r\n")) | ||
|
|
||
| - name: Verify line endings and commit cleanup | ||
| shell: bash | ||
| run: | | ||
| python - <<'PY' | ||
| from pathlib import Path | ||
|
|
||
| paths = [ | ||
| Path("VotingPlugin/src/main/java/com/bencodez/votingplugin/config/ConfigVoteSites.java"), | ||
| Path("VotingPlugin/src/main/java/com/bencodez/votingplugin/user/VotingPluginUser.java"), | ||
| ] | ||
| for path in paths: | ||
| data = path.read_bytes() | ||
| assert b"\n" not in data.replace(b"\r\n", b""), f"non-CRLF newline remains in {path}" | ||
| PY | ||
|
|
||
| git config user.name "github-actions[bot]" | ||
| git config user.email "41898282+github-actions[bot]@users.noreply.github.com" | ||
| git rm .github/workflows/pr1546-line-ending-cleanup.yml | ||
| git add VotingPlugin/src/main/java/com/bencodez/votingplugin/config/ConfigVoteSites.java | ||
| git add VotingPlugin/src/main/java/com/bencodez/votingplugin/user/VotingPluginUser.java | ||
| git diff --cached --check | ||
| git commit -m "Restore Java source line endings" | ||
| git push origin HEAD:codex/review-pr-response |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For a pull request from a fork,
github.head_refcontains only the fork's branch name, whileactions/checkoutstill fetches from the basegithub.repositorybecause norepositoryinput is supplied. Unless the base repository happens to have an identically named branch, checkout fails before Maven runs, blocking CI for external contributors. Keep the default pull-request checkout for ordinary builds, or provide both the head repository and an appropriate ref.Useful? React with 👍 / 👎.