Skip to content

Conversation

@Sl1mb0
Copy link
Contributor

@Sl1mb0 Sl1mb0 commented Nov 18, 2025

Closes #152

Describe your proposed changes here.

  • I've read the contributing section of the project CONTRIBUTING.md.
  • Signed CLA (if not already signed).

@Sl1mb0 Sl1mb0 marked this pull request as ready for review November 18, 2025 22:56
@Sl1mb0 Sl1mb0 requested review from Copilot and crepererum November 18, 2025 22:56
Copilot finished reviewing on behalf of Sl1mb0 November 18, 2025 22:58
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR adds configurability for CPython source downloads by introducing environment variables that allow users to specify custom URLs for Python SDK downloads. This is useful for environments with restricted internet access, custom package repositories, or mirrors.

  • Adds three new configurable environment variables with sensible defaults
  • Maintains backward compatibility by defaulting to the original brettcannon/cpython-wasi-build URLs
  • Refactors hardcoded URLs to use the new configurable variables

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.


PYTHON_VERSION_FULL := PYTHON_VERSION_MAJOR + "." + PYTHON_VERSION_MINOR + "." + PYTHON_VERSION_MICRO

# Configurable URLs for Python SDK downloads (with defaults)
Copy link

Copilot AI Nov 18, 2025

Choose a reason for hiding this comment

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

The new environment variables PYTHON_SDK_BASE_URL, PYTHON_SDK_URL, and BUILD_PYTHON_SDK_URL should be documented so users know they can configure custom download locations. Consider adding a section to guests/python/README.md under the "Build" section or to CONTRIBUTING.md explaining these configuration options and their use cases (e.g., using custom mirrors, air-gapped environments).

Suggested change
# Configurable URLs for Python SDK downloads (with defaults)
# Python SDK download URL configuration
#
# The following environment variables can be set to customize the download locations for the Python WASM SDK:
# - PYTHON_SDK_BASE_URL: Base URL for Python SDK releases (default: official GitHub release)
# - PYTHON_SDK_URL: Full URL for the pre-built Python SDK zip file
# - BUILD_PYTHON_SDK_URL: Full URL for the build Python SDK zip file
#
# These variables are useful for:
# - Using custom mirrors or internal artifact repositories
# - Building in air-gapped or restricted network environments
# - Overriding the default download source for testing or reliability
#
# Example usage:
# export PYTHON_SDK_BASE_URL="https://my-mirror.local/python-wasi"
# just build-release
#

Copilot uses AI. Check for mistakes.
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.

Optionally Pull CPython binary from InfluxData

2 participants