feat!: lazy usearch initialization (v0.1.0 BREAKING)#10
Open
27Bslash6 wants to merge 2 commits intoKarthik777:mainfrom
Open
feat!: lazy usearch initialization (v0.1.0 BREAKING)#1027Bslash6 wants to merge 2 commits intoKarthik777:mainfrom
27Bslash6 wants to merge 2 commits intoKarthik777:mainfrom
Conversation
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.
Summary
BREAKING CHANGE:
usearch_fix()no longer runs automatically on import.This PR removes the subprocess call that runs on every
import litesearch, making imports clean and side-effect free.Why This Matters
The current behavior runs
install_name_tool(macOS) on every import, which:Migration
Changes
usearch_fix()call from__init__.pyusearch_fiximportable for explicit useDependencies
setup_db()and idempotent flag inusearch_fix()from fix: bug fixes, error handling, and test infrastructure (v0.0.6) #9 make this safeTest Plan
test_import_does_not_run_subprocessverifies no side effectssetup_db(sem_search=False)works without usearchsetup_db(sem_search=True)still loads usearch correctly