Skip to content

Conversation

@mplsgrant
Copy link
Collaborator

plugin.py should just be ingested by python instead doing what we do today which is chmod-ing plugin.py and calling it via bash.

Also, when deciding between using python and python3, I did some research and python3 is allegedly the sure-fire way to call python on both linux and macos.

Addresses #678

@pinheadmz pinheadmz mentioned this pull request Mar 7, 2025
Copy link
Contributor

@pinheadmz pinheadmz left a comment

Choose a reason for hiding this comment

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

concept ACK


cmd = (
f"{network_file_path.parent / entrypoint_path / Path('plugin.py')} entrypoint "
f"python3 {network_file_path.parent / entrypoint_path / Path('plugin.py')} entrypoint "
Copy link
Contributor

Choose a reason for hiding this comment

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

there's a trick to this, see how bitcoin test runner calls python from inside python:

https://github.com/bitcoin/bitcoin/blob/ee68b05f3d639b28b9d23b48324bc5f20ccfe49c/test/functional/test_runner.py#L783

`python3` seems to be the right way to call python from both linux and macos.
@mplsgrant mplsgrant force-pushed the 2025-03-let-python-do-it branch from 7b3cf4c to 6f642e3 Compare March 11, 2025 18:35
@pinheadmz
Copy link
Contributor

LGTM, merge when you're happy

@mplsgrant mplsgrant merged commit 8e621be into bitcoin-dev-project:main Mar 11, 2025
15 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.

2 participants