Skip to content

fix(zipapp): guard against null runtime files - #4119

Merged
aignas merged 1 commit into
bazel-contrib:mainfrom
rickeylev:fix_zipapp_runtime_files_null
Aug 29, 2026
Merged

fix(zipapp): guard against null runtime files#4119
aignas merged 1 commit into
bazel-contrib:mainfrom
rickeylev:fix_zipapp_runtime_files_null

Conversation

@rickeylev

Copy link
Copy Markdown
Collaborator

When building a zipapp archive with a Python runtime whose `files`
attribute is `None` (such as a system interpreter), adding
`py_runtime.files` to the runfiles builder raises an error.

Only add `py_runtime.files` to the runfiles builder when it is not
`None`.

When creating a zipapp with a Python runtime whose `files` attribute is
None (such as a system interpreter), adding `py_runtime.files` to the
runfiles builder raises an error.

Add a guard to only add `py_runtime.files` if it is not None.
@rickeylev
rickeylev requested a review from aignas as a code owner August 28, 2026 17:18
@rickeylev

Copy link
Copy Markdown
Collaborator Author

/backport

@github-actions github-actions Bot mentioned this pull request Aug 28, 2026
5 tasks
@aignas
aignas added this pull request to the merge queue Aug 29, 2026
Merged via the queue into bazel-contrib:main with commit 3da7faf Aug 29, 2026
5 checks passed
@rickeylev
rickeylev deleted the fix_zipapp_runtime_files_null branch August 29, 2026 04:31
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