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

Remove dead code from dataset.py #114

Merged
merged 1 commit into from
Jun 18, 2024
Merged

Remove dead code from dataset.py #114

merged 1 commit into from
Jun 18, 2024

Conversation

daverigby
Copy link
Collaborator

Problem

dataset.py was original inherited from another project (locust-pinecone) which had slighly different requirements for parquet
dataset usage. As new functionality has been added in VSB (iterator API, splitting batches), there is now code which is unused in dataset.py:

  • Generating queries by sampling passages (where a dataset doesn't have a queries set) - we expect a parquet dataset to always have a query set (and if not the actual workload subclass should provide one).

  • Directly upserting a parquet dataset into Pinecone (this is always done via the DB abstract base class to support multiple databases).

Solution

Delete the code related to this unused functionality to simplify maintenance of VSB.

Type of Change

  • Bug fix (non-breaking change which fixes an issue)

Test Plan

Rely on existing tests to ensure code is indeed all dead.

dataset.py was original inherited from another project
(locust-pinecone) which had slighly different requirements for parquet
dataset usage. As new functionality has been added in VSB (iterator
API, splitting batches), there is now code which is unused in
dataset.py:

* Generating queries by sampling passages (where a dataset doesn't
  have a queries set) - we expect a parquet dataset to always have a
  query set (and if not the actual workload subclass should provide
  one).

* Directly upserting a parquet dataset into Pinecone (this is always
  done via the DB abstract base class).

Delete the code related to this unused functionality to simplify
maintenance of VSB.
@daverigby
Copy link
Collaborator Author

Partially addresses #46 .

@daverigby daverigby merged commit a3fe6d4 into main Jun 18, 2024
4 checks passed
@daverigby daverigby deleted the dataset_cleanup branch June 18, 2024 10:37
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