diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1af05e8ff8965b..1bcb3b64b33d63 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,6 +14,8 @@ jobs: test: name: Lint, Unit, Unit addons, Circular dependencies & Examples testing runs-on: ubuntu-latest + permissions: + contents: read steps: - name: Git checkout uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6 @@ -41,6 +43,8 @@ jobs: name: E2E testing runs-on: ${{ matrix.os }} timeout-minutes: 30 + permissions: + contents: read strategy: fail-fast: false matrix: diff --git a/.github/workflows/codeql-code-scanning.yml b/.github/workflows/codeql-code-scanning.yml index 26197c0ae1574a..6bec2a91b974f9 100644 --- a/.github/workflows/codeql-code-scanning.yml +++ b/.github/workflows/codeql-code-scanning.yml @@ -10,6 +10,9 @@ on: - cron: '29 23 * * 0' workflow_dispatch: +permissions: + contents: read + jobs: analyze: name: Analyze diff --git a/.github/workflows/protected-folders.yml b/.github/workflows/protected-folders.yml index d57b8f8f1e5eb4..1f334b7360287b 100644 --- a/.github/workflows/protected-folders.yml +++ b/.github/workflows/protected-folders.yml @@ -6,12 +6,12 @@ on: - 'build/**' - 'docs/**' -permissions: - contents: read +permissions: {} jobs: check: runs-on: ubuntu-latest + permissions: {} steps: - name: Check for protected folder changes if: ${{ github.event.pull_request.author_association != 'OWNER' && github.event.pull_request.author_association != 'COLLABORATOR' }} diff --git a/.github/workflows/read-size.yml b/.github/workflows/read-size.yml index 352e9c1be124b7..12c2cb1a4796e9 100644 --- a/.github/workflows/read-size.yml +++ b/.github/workflows/read-size.yml @@ -18,6 +18,8 @@ jobs: read-size: name: Tree-shaking runs-on: ubuntu-latest + permissions: + contents: read steps: - name: Git checkout uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6 diff --git a/.github/workflows/report-size.yml b/.github/workflows/report-size.yml index 1929192b06c85f..987de1fb9ee71e 100644 --- a/.github/workflows/report-size.yml +++ b/.github/workflows/report-size.yml @@ -6,18 +6,20 @@ on: types: - completed -# This workflow needs to be run with "pull-requests: write" permissions to -# be able to comment on the pull request. We can't checkout the PR code -# in this workflow. -# Reference: -# https://securitylab.github.com/research/github-actions-preventing-pwn-requests/ permissions: - pull-requests: write + contents: read jobs: report-size: name: Comment on PR runs-on: ubuntu-latest + # This job needs "pull-requests: write" permissions to be able to comment + # on the pull request. We can't checkout the PR code in this workflow. + # Reference: + # https://securitylab.github.com/research/github-actions-preventing-pwn-requests/ + permissions: + contents: read + pull-requests: write if: github.event.workflow_run.event == 'pull_request' && github.event.workflow_run.conclusion == 'success' steps: diff --git a/src/extras/PMREMGenerator.js b/src/extras/PMREMGenerator.js index 05ac5d6eae2db8..2dff4c0e72544a 100644 --- a/src/extras/PMREMGenerator.js +++ b/src/extras/PMREMGenerator.js @@ -142,8 +142,8 @@ class PMREMGenerator { /** * Generates a PMREM from an equirectangular texture, which can be either LDR - * or HDR. The ideal input image size is 1k (1024 x 512), - * as this matches best with the 256 x 256 cubemap output. + * or HDR. The ideal input image size is 1k (1024 x 512), as this matches best + * with the 256 x 256 cubemap output. The minimum supported resolution is 64 x 32. * * @param {Texture} equirectangular - The equirectangular texture to be converted. * @param {?WebGLRenderTarget} [renderTarget=null] - The render target to use. @@ -157,8 +157,9 @@ class PMREMGenerator { /** * Generates a PMREM from an cubemap texture, which can be either LDR - * or HDR. The ideal input cube size is 256 x 256, - * as this matches best with the 256 x 256 cubemap output. + * or HDR. The ideal input cube size is 256 x 256, as this matches best + * with the 256 x 256 cubemap output. The minimum supported resolution is + * 16 x 16 per face. * * @param {Texture} cubemap - The cubemap texture to be converted. * @param {?WebGLRenderTarget} [renderTarget=null] - The render target to use. diff --git a/src/renderers/common/extras/PMREMGenerator.js b/src/renderers/common/extras/PMREMGenerator.js index 6c0eb8bf9b21a2..3d016da3986609 100644 --- a/src/renderers/common/extras/PMREMGenerator.js +++ b/src/renderers/common/extras/PMREMGenerator.js @@ -214,8 +214,8 @@ class PMREMGenerator { /** * Generates a PMREM from an equirectangular texture, which can be either LDR - * or HDR. The ideal input image size is 1k (1024 x 512), - * as this matches best with the 256 x 256 cubemap output. + * or HDR. The ideal input image size is 1k (1024 x 512), as this matches best + * with the 256 x 256 cubemap output. The minimum supported resolution is 64 x 32. * * @param {Texture} equirectangular - The equirectangular texture to be converted. * @param {?RenderTarget} [renderTarget=null] - The render target to use. @@ -265,8 +265,9 @@ class PMREMGenerator { /** * Generates a PMREM from an cubemap texture, which can be either LDR - * or HDR. The ideal input cube size is 256 x 256, - * as this matches best with the 256 x 256 cubemap output. + * or HDR. The ideal input cube size is 256 x 256, as this matches best + * with the 256 x 256 cubemap output. The minimum supported resolution is + * 16 x 16 per face. * * @param {Texture} cubemap - The cubemap texture to be converted. * @param {?RenderTarget} [renderTarget=null] - The render target to use. diff --git a/src/renderers/webgpu/utils/WebGPUBindingUtils.js b/src/renderers/webgpu/utils/WebGPUBindingUtils.js index 7871c35c99ad18..734aa12e982286 100644 --- a/src/renderers/webgpu/utils/WebGPUBindingUtils.js +++ b/src/renderers/webgpu/utils/WebGPUBindingUtils.js @@ -190,6 +190,8 @@ class WebGPUBindingUtils { const array = binding.buffer; // cpu const buffer = backend.get( binding ).buffer; // gpu + if ( buffer === undefined ) return; // see #33461 + const updateRanges = binding.updateRanges; if ( updateRanges.length === 0 ) {