[MCC-1489710] Python Lib - Boilerplate Code [Dev Only]#3
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
Introduces an initial Python SDK (dataconnect) for the Medidata DataConnect service (Arrow Flight / gRPC), replacing/augmenting the prior template scaffolding and adding offline unit tests plus updated packaging/docs.
Changes:
- Added the
dataconnectpackage (client, connection helpers, datasets APIs, publishing APIs, models, error hierarchy, and a lazy data frame abstraction). - Switched packaging/config to a PEP 621 + Hatch setup and added Ruff + strict mypy configuration.
- Added a comprehensive
tests/test_dataconnect.pysuite and updated template tests with more type annotations.
Reviewed changes
Copilot reviewed 19 out of 21 changed files in this pull request and generated 21 comments.
Show a summary per file
| File | Description |
|---|---|
dataconnect/__init__.py |
Exposes the public SDK surface (client, models, errors, init() factory). |
dataconnect/_client.py |
Implements DataConnectClient public methods (studies/datasets/versions/fetch/publish). |
dataconnect/_connection.py |
Builds FlightClient + per-call metadata headers (incl. network-identification). |
dataconnect/_datasets.py |
Implements list APIs over list_flights and parses tickets/app_metadata. |
dataconnect/_errors.py |
Adds SDK exception hierarchy and Flight error parsing helpers. |
dataconnect/_frame.py |
Adds DataConnectFrame lazy head()/collect() abstraction over do_get. |
dataconnect/_models.py |
Adds pydantic v2 models for typed responses. |
dataconnect/_publishing.py |
Implements publish/dry-publish over do_put plus local row counting. |
pyproject.toml |
Moves to Hatch/PEP621 and defines runtime/dev deps + Ruff/mypy/pytest config. |
pyproject_orig.toml |
Keeps the prior Poetry-based template config for reference. |
README.md |
Replaces template README with DataConnect SDK docs and examples. |
README_orig.md |
Keeps the prior template README for reference. |
TODO |
Documents intended package layout and design decisions. |
tests/test_dataconnect.py |
Adds offline unit tests using mocked FlightClient. |
tests/conftest.py |
Updates fixtures typing and imports for the template tests. |
tests/test_reversers.py |
Adds type annotations to template tests. |
tests/test_python_template.py |
Adds a return type annotation to the import test. |
tests/test_benchmark_reverser.py |
Adds type annotation to word argument in benchmark test. |
python_template/reverse.py |
Modernizes typing imports and return type annotations. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
butsyk-mdsol
force-pushed
the
develop
branch
22 times, most recently
from
April 28, 2026 16:13
3e89077 to
6577e24
Compare
slingampalli-mdsol
approved these changes
Apr 29, 2026
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.
feature/bug/enhance/refactor/tech_debt/hotfix
Python Lib - Boilerplate Code.MCC-1489710Checklist
git commit --amend --no-editcommand to reduce commit messages when making small file changes (like changing linespacing).tests/folder.doc/folder.Changes Summary
Deployment Notes
In addition to IAC/code, add any notes for reviewer should know.