Skip to content

[MCC-1489710] Python Lib - Boilerplate Code [Dev Only]#3

Merged
slingampalli-mdsol merged 4 commits into
mainfrom
develop
Apr 29, 2026
Merged

[MCC-1489710] Python Lib - Boilerplate Code [Dev Only]#3
slingampalli-mdsol merged 4 commits into
mainfrom
develop

Conversation

@butsyk-mdsol

@butsyk-mdsol butsyk-mdsol commented Apr 23, 2026

Copy link
Copy Markdown
Contributor

feature/bug/enhance/refactor/tech_debt/hotfix

Checklist

  • Review the pull request to fix typos and ensure variable/function names are intuitive, etc.
  • Make sure the pull request does not have excessive number of unnecessary commits. Utilize the git commit --amend --no-edit command to reduce commit messages when making small file changes (like changing linespacing).
  • Make sure you have added unit tests for the code changes. Tests should be added in the tests/ folder.
  • Modify docs, if required. Add any new documentation in the doc/ folder.
  • Rebase on latest active development branch (develop/main).

Changes Summary

  • Create foundation for all developers in Team 348 to contribute to this repository, and create a code library similar to R-Lib. 
  • Code structure should be strict, variables should all have types defined etc.
  • Dependencies (such as pyarrow) should be defined in the toml file. 
  • Clean up or hide any excessive files generated by the Python Template during repo creation. 

 

Deployment Notes

In addition to IAC/code, add any notes for reviewer should know.

Copilot AI review requested due to automatic review settings April 23, 2026 10:54
@butsyk-mdsol butsyk-mdsol changed the title Initial commit Boilerplate Code Apr 23, 2026

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

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 dataconnect package (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.py suite 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.

Comment thread tests/test_reversers.py Outdated
Comment thread tests/test_reversers.py Outdated
Comment thread dataconnect/_connection.py Outdated
Comment thread dataconnect/_datasets.py Outdated
Comment thread tests/conftest.py Outdated
Comment thread tests/test_benchmark_reverser.py Outdated
Comment thread tests/test_dataconnect.py Outdated
Comment thread tests/test_dataconnect.py Outdated
Comment thread dataconnect/_datasets.py Outdated
Comment thread dataconnect/_errors.py Outdated
@butsyk-mdsol
butsyk-mdsol force-pushed the develop branch 22 times, most recently from 3e89077 to 6577e24 Compare April 28, 2026 16:13
@ibaig-mdsol ibaig-mdsol changed the title Boilerplate Code [MCC-1489710] Python Lib - Boilerplate Code [Dev Only] Apr 29, 2026
@slingampalli-mdsol
slingampalli-mdsol merged commit 6109baa into main Apr 29, 2026
3 checks passed
@slingampalli-mdsol
slingampalli-mdsol deleted the develop branch April 29, 2026 11:51
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.

5 participants