Skip to content

Conversation

@renatodellosso
Copy link
Contributor

No description provided.

BanEvading and others added 30 commits March 27, 2025 16:44
Bumps [jose](https://github.com/panva/jose) from 6.0.8 to 6.0.10.
- [Release notes](https://github.com/panva/jose/releases)
- [Changelog](https://github.com/panva/jose/blob/main/CHANGELOG.md)
- [Commits](panva/jose@v6.0.8...v6.0.10)

---
updated-dependencies:
- dependency-name: jose
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Bumps [react-icons](https://github.com/react-icons/react-icons) from 5.4.0 to 5.5.0.
- [Release notes](https://github.com/react-icons/react-icons/releases)
- [Commits](react-icons/react-icons@v5.4.0...v5.5.0)

---
updated-dependencies:
- dependency-name: react-icons
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
renatodellosso and others added 26 commits April 3, 2025 13:28
…/npm_and_yarn-9eaa48ee01

[npm]: Bump next from 15.2.3 to 15.2.4 in the npm_and_yarn group
Bumps [@eslint/js](https://github.com/eslint/eslint/tree/HEAD/packages/js) from 9.18.0 to 9.24.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/commits/v9.24.0/packages/js)

---
updated-dependencies:
- dependency-name: "@eslint/js"
  dependency-version: 9.24.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Bumps [resend](https://github.com/resendlabs/resend-node) from 4.1.2 to 4.2.0.
- [Release notes](https://github.com/resendlabs/resend-node/releases)
- [Commits](resend/resend-node@v4.1.2...v4.2.0)

---
updated-dependencies:
- dependency-name: resend
  dependency-version: 4.2.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.2.2 to 15.2.4.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.2.4/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.2.4
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Bumps [@serwist/next](https://github.com/serwist/serwist) from 9.0.11 to 9.0.13.
- [Release notes](https://github.com/serwist/serwist/releases)
- [Commits](https://github.com/serwist/serwist/compare/@serwist/next@9.0.11...@serwist/next@9.0.13)

---
updated-dependencies:
- dependency-name: "@serwist/next"
  dependency-version: 9.0.13
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
…/eslint/js-9.24.0

[npm]: Bump @eslint/js from 9.18.0 to 9.24.0
…/resend-4.2.0

[npm]: Bump resend from 4.1.2 to 4.2.0
…/eslint-config-next-15.2.4

[npm]: Bump eslint-config-next from 15.2.2 to 15.2.4
…/serwist/next-9.0.13

[npm]: Bump @serwist/next from 9.0.11 to 9.0.13
Comment on lines +5 to +42
timeout-minutes: 60
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
# Make sure to require each shard in GitHub!
shardIndex: [1, 2, 3, 4]
shardTotal: [4]
steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: lts/*

- name: Install dependencies
run: npm ci

- name: Install Playwright browsers
run: npx playwright install --with-deps

- name: Start MongoDB
uses: supercharge/mongodb-github-action@1.12.0
with:
mongodb-version: "8.0"

- name: Run Playwright tests
run: npx cross-env NODE_ENV=test playwright test --shard=${{ matrix.shardIndex }}/${{ matrix.shardTotal }}

- name: Upload blob report to GitHub Actions Artifacts
if: ${{ !cancelled() }}
uses: actions/upload-artifact@v4
with:
name: blob-report-${{ matrix.shardIndex }}
path: blob-report
retention-days: 1

merge_reports:

Check warning

Code scanning / CodeQL

Workflow does not contain permissions Medium

Actions job or workflow does not limit the permissions of the GITHUB_TOKEN. Consider setting an explicit permissions block, using the following as a minimal starting point: {contents: read}

Copilot Autofix

AI 5 days ago

In general, this issue is fixed by explicitly setting the permissions for the GITHUB_TOKEN at the workflow or job level, instead of relying on organization/repository defaults. For test workflows like this one, contents: read is typically sufficient, as the workflow only checks out code and uses artifacts, and does not need to write to the repository, issues, or pull requests.

The best fix here, without changing existing functionality, is to add a permissions block at the top level of .github/workflows/e2e_test.yml, just below name: (or immediately after on:). This root-level permissions configuration will apply to all jobs (e2e_tests and merge_reports) since neither defines its own permissions. The minimal safe starting point per CodeQL’s suggestion is contents: read, which allows actions/checkout@v4 to function while avoiding unnecessary write access. No additional imports or methods are needed; only the YAML configuration is updated.

Concretely: in .github/workflows/e2e_test.yml, insert:

permissions:
  contents: read

near the top of the file (e.g., after line 2), keeping indentation aligned with name: and on: keys.

Suggested changeset 1
.github/workflows/e2e_test.yml

Autofix patch

Autofix patch
Run the following command in your local git repository to apply this patch
cat << 'EOF' | git apply
diff --git a/.github/workflows/e2e_test.yml b/.github/workflows/e2e_test.yml
--- a/.github/workflows/e2e_test.yml
+++ b/.github/workflows/e2e_test.yml
@@ -1,5 +1,7 @@
 name: Playwright Tests
 on: [workflow_dispatch, workflow_call]
+permissions:
+  contents: read
 jobs:
   e2e_tests:
     timeout-minutes: 60
EOF
@@ -1,5 +1,7 @@
name: Playwright Tests
on: [workflow_dispatch, workflow_call]
permissions:
contents: read
jobs:
e2e_tests:
timeout-minutes: 60
Copilot is powered by AI and may make mistakes. Always verify output.
Comment on lines +44 to +71
if: ${{ !cancelled() }}
needs: [e2e_tests]

runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: lts/*
- name: Install dependencies
run: npm ci

- name: Download blob reports from GitHub Actions Artifacts
uses: actions/download-artifact@v4
with:
path: all-blob-reports
pattern: blob-report-*
merge-multiple: true

- name: Merge into HTML Report
run: npx playwright merge-reports --reporter html ./all-blob-reports

- name: Upload HTML report
uses: actions/upload-artifact@v4
with:
name: html-report--attempt-${{ github.run_attempt }}
path: playwright-report
retention-days: 14

Check warning

Code scanning / CodeQL

Workflow does not contain permissions Medium

Actions job or workflow does not limit the permissions of the GITHUB_TOKEN. Consider setting an explicit permissions block, using the following as a minimal starting point: {contents: read}

Copilot Autofix

AI 5 days ago

In general, the fix is to explicitly declare a permissions block in the workflow so that the GITHUB_TOKEN used by jobs has only the minimal scopes required. For this workflow, the jobs check out the code (actions/checkout) and interact with artifacts (actions/upload-artifact, actions/download-artifact). These operations only require contents: read plus the default access that Actions grants for artifacts; no repository write or administrative permissions are needed.

The best minimal fix without changing functionality is to add a top-level permissions block so it applies to all jobs (e2e_tests and merge_reports). This should be placed near the top of .github/workflows/e2e_test.yml, after the on: block, and set contents: read. No other permission scopes appear necessary from the provided snippet. No imports or additional methods are needed; we only modify the YAML workflow definition.

Specifically: edit .github/workflows/e2e_test.yml to insert:

permissions:
  contents: read

between the existing on: [workflow_dispatch, workflow_call] line and the jobs: line. This constrains the GITHUB_TOKEN for all jobs in this workflow while preserving existing behavior.

Suggested changeset 1
.github/workflows/e2e_test.yml

Autofix patch

Autofix patch
Run the following command in your local git repository to apply this patch
cat << 'EOF' | git apply
diff --git a/.github/workflows/e2e_test.yml b/.github/workflows/e2e_test.yml
--- a/.github/workflows/e2e_test.yml
+++ b/.github/workflows/e2e_test.yml
@@ -1,5 +1,7 @@
 name: Playwright Tests
 on: [workflow_dispatch, workflow_call]
+permissions:
+  contents: read
 jobs:
   e2e_tests:
     timeout-minutes: 60
EOF
@@ -1,5 +1,7 @@
name: Playwright Tests
on: [workflow_dispatch, workflow_call]
permissions:
contents: read
jobs:
e2e_tests:
timeout-minutes: 60
Copilot is powered by AI and may make mistakes. Always verify output.
@renatodellosso renatodellosso requested a review from Copilot April 13, 2025 18:34
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot reviewed 52 out of 55 changed files in this pull request and generated no comments.

Files not reviewed (3)
  • .env.production: Language not supported
  • .env.test: Language not supported
  • .vscode/extensions.json: Language not supported

@renatodellosso renatodellosso merged commit 452ad03 into offline-mode Apr 13, 2025
16 checks passed
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.

4 participants