Skip to content

Conversation

@hunter-ni
Copy link
Contributor

@hunter-ni hunter-ni commented Sep 17, 2025

What does this Pull Request accomplish?

This PR provides an initial pass at a broader Python API for the Data Store. This includes handling the responsibilities of the lower-level DataStoreClient, MetadataStoreClient, and MonikerClient through a unified Clientinterface.

The PR broadens the existing Publish support for a number of data types beyond the bool and double analog waveform types that were previous supported. It also continues to iterate on the Read API to allow for flexibility in either returning a strongly type-hinted value or a generic object when the type isn't known beforehand.

Furthermore, it implements support for operations related to Steps, TestResultss, and various types of metadata owned by the MetadataStoreClient.

Why should this Pull Request be merged?

We believe these changes move us closer to having a fully featured high-level Python API for the Data Store present as part of the datastore-python repo. We plan to continue iterating on this as needed.

What testing has been done?

  • Added a few new unit tests to handle a few trickier cases that were brought up during review related to Publish timestamps for waveforms.
  • No manual testing against an actual Data Store Service yet. We plan to do this once the renaming work for the server has been submitted (and the renamed entry-points are present).

@hunter-ni hunter-ni requested a review from a team September 18, 2025 14:28
… doesn't require the client to know what type of data to expect. Review feedback.
Copy link
Collaborator

@dixonjoel dixonjoel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Waiting for some resolutions on whether we wrap timestamp types. Generally looks good and I'm happy we're getting this much API surface reviewed at this point.

@mjohanse-emr mjohanse-emr requested review from mjohanse-emr and removed request for mjohanse-emr September 18, 2025 22:21
Copy link
Collaborator

@mjohanse-emr mjohanse-emr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since I'm out tomorrow, I'm going to approve this just so my "Changes requested" isn't blocking this PR. This review doesn't mean you can submit, please get approvals from others.

If it's still open on Monday, I'd be happy to take another look.

@hunter-ni hunter-ni marked this pull request as ready for review September 19, 2025 20:56
Copilot AI review requested due to automatic review settings September 19, 2025 20:56
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR broadens the Python API for the Data Store by providing a unified Client interface that consolidates functionality from lower-level clients. It expands support for various data types beyond boolean and double analog waveform types, implements support for steps, test results, and metadata operations, and enhances the read API with flexible type handling.

  • Added support for publishing/reading multiple data types including scalars, vectors, waveforms, spectrums, and digital waveforms
  • Implemented comprehensive metadata store operations for UUTs, operators, test descriptions, hardware/software items, etc.
  • Enhanced timestamp handling for waveforms with validation and automatic t0 detection

Reviewed Changes

Copilot reviewed 3 out of 4 changed files in this pull request and generated 1 comment.

File Description
pyproject.toml Added hightime dependency for improved timestamp handling
src/ni/datastore/client.py Major expansion of Client class with unified API, extensive data type support, and metadata operations
tests/unit/test_ni_datastore_client.py Updated tests for new API and added timestamp validation test cases

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@hunter-ni hunter-ni requested a review from bkeryan September 19, 2025 21:00
@hunter-ni
Copy link
Contributor Author

After discussion with @csjall and @dixonjoel, we've decided to go ahead and push this through so that we can more easily start collaborating on iterative improvements and additions.

@hunter-ni hunter-ni merged commit e28fc83 into main Sep 22, 2025
12 checks passed
@hunter-ni hunter-ni deleted the users/hunter-ni/expand-data-store-service-api-support branch September 22, 2025 15:30
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.

6 participants