Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Raise an error when there are multiple local libraries with the same basename used #2297

Merged
merged 5 commits into from
Feb 7, 2025

Conversation

andrewnester
Copy link
Contributor

Changes

Raise an error when there are multiple local libraries with the same basename used

Fixes #1674

Tests

Added an unit test

bundle/libraries/same_name_libraries_test.go Outdated Show resolved Hide resolved
bundle/libraries/same_name_libraries.go Outdated Show resolved Hide resolved
bundle/libraries/same_name_libraries.go Outdated Show resolved Hide resolved
bundle/libraries/same_name_libraries_test.go Show resolved Hide resolved
@denik denik self-requested a review February 7, 2025 16:44
@andrewnester andrewnester requested a review from pietern February 7, 2025 17:39
@andrewnester andrewnester added this pull request to the merge queue Feb 7, 2025
Merged via the queue into main with commit 2a97dca Feb 7, 2025
9 checks passed
@andrewnester andrewnester deleted the fix/same-name-wheels branch February 7, 2025 18:03
andrewnester added a commit that referenced this pull request Feb 12, 2025
Bundles:
 * Added support to generate Git based jobs ([#2304](#2304)).
 * Added support for run_as in pipelines ([#2287](#2287)).
 * Raise an error when there are multiple local libraries with the same basename used ([#2297](#2297)).
 * Fix env variable for AzureCli local config ([#2248](#2248)).
 * Accept JSON files in includes section ([#2265](#2265)).
 * Always print warnings and errors; clean up format ([#2213](#2213))

API Changes:
 * Added `databricks account budget-policy` command group.
 * Added `databricks lakeview-embedded` command group.
 * Added `databricks query-execution` command group.
 * Changed `databricks serving-endpoints http-request` command to type `databricks serving-endpoints http-request` command.
 * Added `databricks account enable-ip-access-lists` command group.
 * Added `databricks redash-config` command group.

OpenAPI commit c72c58f97b950fcb924a90ef164bcb10cfcd5ece (2025-02-03)
Dependency updates:
 * Upgrade to TF provider 1.65.1 ([#2328](#2328)).
 * Bump golangci/golangci-lint-action from 6.1.1 to 6.2.0 ([#2273](#2273)).
 * Bump astral-sh/ruff-action from 3.0.1 to 3.1.0 ([#2274](#2274)).
 * Bump actions/stale from 9.0.0 to 9.1.0 ([#2275](#2275)).
 * Bump actions/create-github-app-token from 1.11.1 to 1.11.2 ([#2276](#2276)).
 * Bump github.com/hashicorp/terraform-exec from 0.21.0 to 0.22.0 ([#2237](#2237)).
 * Bump github.com/spf13/pflag from 1.0.5 to 1.0.6 ([#2281](#2281)).
 * Bump github.com/databricks/databricks-sdk-go from 0.56.1 to 0.57.0 ([#2321](#2321)).
 * Bump golang.org/x/oauth2 from 0.25.0 to 0.26.0 ([#2322](#2322)).
 * Bump golang.org/x/term from 0.28.0 to 0.29.0 ([#2325](#2325)).
 * Bump golang.org/x/text from 0.21.0 to 0.22.0 ([#2323](#2323)).
 * Bump golang.org/x/mod from 0.22.0 to 0.23.0 ([#2324](#2324)).
andrewnester added a commit that referenced this pull request Feb 12, 2025
Bundles:
* Added support to generate Git based jobs
([#2304](#2304)).
* Added support for run_as in pipelines
([#2287](#2287)).
* Raise an error when there are multiple local libraries with the same
basename used ([#2297](#2297)).
* Fix env variable for AzureCli local config
([#2248](#2248)).
* Accept JSON files in includes section
([#2265](#2265)).
* Always print warnings and errors; clean up format
([#2213](#2213))

API Changes:
 * Added `databricks account budget-policy` command group.
 * Added `databricks lakeview-embedded` command group.
 * Added `databricks query-execution` command group.
 * Added `databricks account enable-ip-access-lists` command group.
 * Added `databricks redash-config` command group.

OpenAPI commit c72c58f97b950fcb924a90ef164bcb10cfcd5ece (2025-02-03)
Dependency updates:
* Upgrade to TF provider 1.65.1
([#2328](#2328)).
* Bump github.com/hashicorp/terraform-exec from 0.21.0 to 0.22.0
([#2237](#2237)).
* Bump github.com/spf13/pflag from 1.0.5 to 1.0.6
([#2281](#2281)).
* Bump github.com/databricks/databricks-sdk-go from 0.56.1 to 0.57.0
([#2321](#2321)).
* Bump golang.org/x/oauth2 from 0.25.0 to 0.26.0
([#2322](#2322)).
* Bump golang.org/x/term from 0.28.0 to 0.29.0
([#2325](#2325)).
* Bump golang.org/x/text from 0.21.0 to 0.22.0
([#2323](#2323)).
* Bump golang.org/x/mod from 0.22.0 to 0.23.0
([#2324](#2324)).
andrewnester added a commit that referenced this pull request Feb 12, 2025
…pes (#2341)

## Changes

The CheckForSameNameLibraries mutator incorrectly assumed all resource
libraries define libraries as paths of the `string` type, but some
libraries, such as PyPi and Maven, define them as objects.

This PR addresses this issue. It was introduced in #2297.

## Tests

Added regression test.
pietern added a commit that referenced this pull request Feb 12, 2025
pietern added a commit that referenced this pull request Feb 12, 2025
## Changes

These changes break the use of non-local libraries (such as PyPI
libraries).

This reverts the set so we can cut a patch release and take a closer
look later.

Original PRs are #2297 and #2341.

Issue reported in #2343.

## Tests

Manually confirmed that a bundle with PyPI package in libraries now
deploys fine.
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.

Libraries with the same name but different path override each other
3 participants