Skip to content

Improve the forbidden env vars check#542

Merged
edmorley merged 1 commit intomainfrom
forbidden-env-vars-check
Apr 7, 2026
Merged

Improve the forbidden env vars check#542
edmorley merged 1 commit intomainfrom
forbidden-env-vars-check

Conversation

@edmorley
Copy link
Copy Markdown
Member

@edmorley edmorley commented Apr 6, 2026

  • Now reports all forbidden env vars found in one go, rather than only the first found.
  • Now checks for known problematic Poetry env vars too.
  • Uses a const slice instead of a fixed size array to avoid having to manually update the array every time entries are added/removed.
  • Uses a static str slice in the error to avoid an unnecessary string allocation.
  • Adds additional unit test coverage.

GUS-W-21914465.

@edmorley edmorley self-assigned this Apr 6, 2026
@edmorley edmorley added the enhancement New feature or request label Apr 6, 2026
@edmorley edmorley force-pushed the forbidden-env-vars-check branch from eeec09b to 1682f69 Compare April 6, 2026 14:29
@edmorley edmorley marked this pull request as ready for review April 6, 2026 14:38
@edmorley edmorley requested a review from a team as a code owner April 6, 2026 14:38
@edmorley edmorley enabled auto-merge (squash) April 6, 2026 14:41
@edmorley edmorley force-pushed the forbidden-env-vars-check branch from 1682f69 to e766ac6 Compare April 6, 2026 14:52
- Now reports all forbidden env vars found in one go,
  rather than only the first found.
- Now checks for known problematic Poetry env vars too.
- Uses a const slice instead of a fixed size array to avoid having to
  manually update the array every time entries are added/removed.
- Uses a static str slice in the error to avoid an unnecessary
  string allocation.
- Adds additional unit test coverage.

GUS-W-21914465.
@edmorley edmorley force-pushed the forbidden-env-vars-check branch from e766ac6 to c587780 Compare April 6, 2026 15:37
@edmorley edmorley disabled auto-merge April 6, 2026 15:37
@edmorley edmorley enabled auto-merge (squash) April 6, 2026 15:37
@edmorley edmorley merged commit 2e52618 into main Apr 7, 2026
6 checks passed
@edmorley edmorley deleted the forbidden-env-vars-check branch April 7, 2026 11:32
heroku-linguist bot added a commit that referenced this pull request Apr 7, 2026
## heroku/python

### Changed

- The Python 3.14 version alias now resolves to Python 3.14.4. ([#548](#548))
- The Python 3.13 version alias now resolves to Python 3.13.13. ([#548](#548))
- The forbidden env vars check now reports all forbidden env vars found rather than only the first. ([#542](#542))
- The forbidden env vars check now checks for known problematic Poetry env vars too. ([#542](#542))
@heroku-linguist heroku-linguist bot mentioned this pull request Apr 7, 2026
heroku-linguist bot added a commit to heroku/cnb-builder-images that referenced this pull request Apr 7, 2026
## heroku/python

### Changed

- The Python 3.14 version alias now resolves to Python 3.14.4. ([#548](heroku/buildpacks-python#548))
- The Python 3.13 version alias now resolves to Python 3.13.13. ([#548](heroku/buildpacks-python#548))
- The forbidden env vars check now reports all forbidden env vars found rather than only the first. ([#542](heroku/buildpacks-python#542))
- The forbidden env vars check now checks for known problematic Poetry env vars too. ([#542](heroku/buildpacks-python#542))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants