-
Notifications
You must be signed in to change notification settings - Fork 4
fix: five fixes from the python-parity audit (two source-breaking) #368
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
Merged
Merged
Changes from all commits
Commits
Show all changes
16 commits
Select commit
Hold shift + click to select a range
55b0693
fix: Multi2VecGoogleGemini emitted a module name no server has
g-despot 0e83cd9
feat: send incremental_base_backup_id on backup create
g-despot 6c64793
fix: backup list dropped Size and the incremental base id it had parsed
g-despot 4ef693c
feat: add the generative-deepseek module (Weaviate 1.39)
g-despot 4356731
fix: aggregate reported 0/0.0/false where the server sent nothing
g-despot ccab7a5
fix: drop vectorizeCollectionName from the Multi2VecGoogleGemini fact…
g-despot a1430ec
docs: mark vectorizeCollectionName obsolete on the multivector vector…
g-despot e7df693
style: put the CS0618 suppression reason on the pragma, as the repo does
g-despot 8852339
Merge remote-tracking branch 'origin/main' into fix/client-parity-batch
g-despot ed398d0
fix: correct the incremental-backup version floors
g-despot 40c6cdf
fix: presence-check aggregate Count alongside the other scalars
g-despot 4fa7d5a
revert: drop the vectorizeCollectionName deprecation sweep
g-despot b40902a
docs: add the changelog entries for this release
g-despot 4554e42
Merge branch 'main' into fix/client-parity-batch
g-despot 3cb5430
test: gate the Gemini vectorizer test on 1.34.20
g-despot d12049f
Potential fix for pull request finding
g-despot File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,95 @@ | ||
| namespace Weaviate.Client.Tests.Integration; | ||
|
|
||
| using Weaviate.Client.Models; | ||
|
|
||
| /// <summary> | ||
| /// The vectorizer module tests class. Covers vectorizer configurations end to end, i.e. that the | ||
| /// module name and settings the client emits are ones a real server accepts. | ||
| /// </summary> | ||
| /// <seealso cref="IntegrationTests"/> | ||
| public class TestVectorizers : IntegrationTests | ||
| { | ||
| /// <summary> | ||
| /// Tests that the Google Gemini multimodal factory produces a collection the server accepts. | ||
| /// </summary> | ||
| [Fact] | ||
| public async Task Test_Multi2VecGoogleGemini_Creates_Collection() | ||
| { | ||
| RequireModule("multi2vec-google"); | ||
| // The module is on every lane, but its Gemini path (apiEndpoint) only lands in 1.34.20; | ||
| // older builds still demand the Vertex projectId/location this factory omits. | ||
| RequireVersion("1.34.20"); | ||
|
|
||
| var collection = await CollectionFactory( | ||
| name: "TestMulti2VecGoogleGemini", | ||
| properties: [Property.Text("text"), Property.Blob("image")], | ||
| vectorConfig: Configure.Vector( | ||
| "default", | ||
| v => | ||
| v.Multi2VecGoogleGemini( | ||
| imageFields: ["image"], | ||
| textFields: ["text"], | ||
| dimensions: 512 | ||
| ) | ||
| ) | ||
| ); | ||
|
|
||
| var config = await collection.Config.Get( | ||
| cancellationToken: TestContext.Current.CancellationToken | ||
| ); | ||
|
|
||
| Assert.NotNull(config); | ||
| var vectorizer = config.VectorConfig["default"].Vectorizer; | ||
| var google = Assert.IsType<Vectorizer.Multi2VecGoogle>(vectorizer); | ||
|
|
||
| Assert.Equal("multi2vec-palm", google.Identifier); | ||
| Assert.Equal("generativelanguage.googleapis.com", google.ApiEndpoint); | ||
| Assert.Equal(512, google.Dimensions); | ||
| // The factory has no vectorizeClassName: nothing is sent, nothing stored or defaulted back. | ||
| Assert.Null(google.VectorizeCollectionName); | ||
| Assert.NotNull(google.ImageFields); | ||
| Assert.Equal(["image"], google.ImageFields); | ||
| Assert.NotNull(google.TextFields); | ||
| Assert.Equal(["text"], google.TextFields); | ||
| // Vertex-only settings: the Gemini API has neither, and the server must not echo them. | ||
| Assert.Null(google.ProjectId); | ||
| Assert.Null(google.Location); | ||
| } | ||
|
|
||
| /// <summary> | ||
| /// Tests that the Vertex AI factory creates a collection with project id and location intact. | ||
| /// </summary> | ||
| [Fact] | ||
| public async Task Test_Multi2VecGoogle_Vertex_Creates_Collection() | ||
| { | ||
| RequireModule("multi2vec-google"); | ||
|
|
||
| var collection = await CollectionFactory( | ||
| name: "TestMulti2VecGoogleVertex", | ||
| properties: [Property.Text("text"), Property.Blob("image")], | ||
| vectorConfig: Configure.Vector( | ||
| "default", | ||
| v => | ||
| v.Multi2VecGoogle( | ||
| projectId: "my-project", | ||
| location: "us-central1", | ||
| imageFields: ["image"], | ||
| textFields: ["text"] | ||
| ) | ||
| ) | ||
| ); | ||
|
|
||
| var config = await collection.Config.Get( | ||
| cancellationToken: TestContext.Current.CancellationToken | ||
| ); | ||
|
|
||
| Assert.NotNull(config); | ||
| var vectorizer = config.VectorConfig["default"].Vectorizer; | ||
| var google = Assert.IsType<Vectorizer.Multi2VecGoogle>(vectorizer); | ||
|
|
||
| Assert.Equal("multi2vec-palm", google.Identifier); | ||
| Assert.Equal("my-project", google.ProjectId); | ||
| Assert.Equal("us-central1", google.Location); | ||
| Assert.Null(google.ApiEndpoint); | ||
| } | ||
| } |
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.