refactor(stack): use as_file() for package resource copying#937
Merged
mergify[bot] merged 1 commit intomainfrom Jan 27, 2026
Merged
Conversation
This was referenced Jan 25, 2026
Member
Author
|
This pull request is part of a stack:
|
Contributor
Merge ProtectionsYour pull request matches the following merge protections and will not be merged until they are valid. 🟢 🤖 Continuous IntegrationWonderful, this rule succeeded.
🟢 👀 Review RequirementsWonderful, this rule succeeded.
🟢 Enforce conventional commitWonderful, this rule succeeded.Make sure that we follow https://www.conventionalcommits.org/en/v1.0.0/
🟢 🔎 ReviewsWonderful, this rule succeeded.
🟢 📕 PR descriptionWonderful, this rule succeeded.
|
Contributor
🧪 CI InsightsHere's what we observed from your CI run for 82b0e00. 🟢 All jobs passed!But CI Insights is watching 👀 |
remyduthu
previously approved these changes
Jan 26, 2026
5bf5d8b to
b99cacb
Compare
1afef78 to
a8eec96
Compare
Pull request has been modified.
b99cacb to
d31a4b9
Compare
a8eec96 to
173c3d4
Compare
d31a4b9 to
9be7898
Compare
173c3d4 to
26479bc
Compare
9be7898 to
67a94f2
Compare
26479bc to
1509d9b
Compare
Base automatically changed from
devs/jd/version-hooks/I565f0651b22e1cc13c66015638df799796d7e819
to
main
January 27, 2026 09:44
Contributor
|
@jd this pull request is now in conflict 😩 |
Change git hook installation to use importlib.resources.as_file() context manager for copying resources. This ensures compatibility with zip/PEX-style package installations where resources aren't directly accessible as filesystem paths. - Rename _get_script_resource_path() to _get_script_resource() returning Traversable instead of str - Add _get_wrapper_resource() helper - Update _script_needs_update() to accept Traversable - Use as_file() context manager in _install_git_hook() and ensure_hooks_updated() This makes git hook handling consistent with Claude hook handling which already uses as_file(). Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> Change-Id: I0a5ac49101c080fc9cee0ee84fae84c43ec28a64 Claude-Session-Id: 3dabd187-059b-40b7-9a52-a2542a27c752
1509d9b to
82b0e00
Compare
sileht
approved these changes
Jan 27, 2026
remyduthu
approved these changes
Jan 27, 2026
Contributor
Merge Queue Status✅ The pull request has been merged at 82b0e00 This pull request spent 8 seconds in the queue, including 1 second running CI. Required conditions to merge
|
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Change git hook installation to use importlib.resources.as_file()
context manager for copying resources. This ensures compatibility
with zip/PEX-style package installations where resources aren't
directly accessible as filesystem paths.
returning Traversable instead of str
ensure_hooks_updated()
This makes git hook handling consistent with Claude hook handling
which already uses as_file().
Co-Authored-By: Claude Opus 4.5 noreply@anthropic.com