Skip to content

[DRAFT] Refactor PyPI packages version query#2371

Draft
ashenm wants to merge 1 commit intodatabrickslabs:mainfrom
ashenm:refactor/pypi-version-query
Draft

[DRAFT] Refactor PyPI packages version query#2371
ashenm wants to merge 1 commit intodatabrickslabs:mainfrom
ashenm:refactor/pypi-version-query

Conversation

@ashenm
Copy link
Copy Markdown

@ashenm ashenm commented Apr 10, 2026

Changes

What does this PR do?

Replaces the previous direct requests.get call to PyPI for package version lookup with a pip invocation instead. This allows the lookup to automatically respect the existing pip.conf configuration, including custom indexes, mirrors, proxies, and authentication settings.

Relevant implementation details

Package version resolution now uses pip index versions --json and parses the structured output instead of calling the package index directly over HTTP. This makes the behaviour consistent with the user’s configured Python packaging environment and avoids maintaining separate logic for custom PyPI endpoint handling.

Caveats/things to watch out for when reviewing:

Linked issues

Functionality

  • added relevant user documentation
  • added new CLI command
  • modified existing command: databricks labs lakebridge ...
  • ... +add your own

Tests

  • manually tested
  • added unit tests
  • added integration tests

@ashenm ashenm requested a review from a team as a code owner April 10, 2026 18:24
@ashenm ashenm marked this pull request as draft April 10, 2026 18:24
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.

1 participant