-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
Initial ModelsRepositoryClient #17180
Conversation
removed partial expanded fallback logic Black formatting Removed unnecessary comment New structure, added nspkg wip removed nspkg Refactored (again) black formatting Implementation
This pull request is protected by Check Enforcer. What is Check Enforcer?Check Enforcer helps ensure all pull requests are covered by at least one check-run (typically an Azure Pipeline). When all check-runs associated with this pull request pass then Check Enforcer itself will pass. Why am I getting this message?You are getting this message because Check Enforcer did not detect any check-runs being associated with this pull request within five minutes. This may indicate that your pull request is not covered by any pipelines and so Check Enforcer is correctly blocking the pull request being merged. What should I do now?If the check-enforcer check-run is not passing and all other check-runs associated with this PR are passing (excluding license-cla) then you could try telling Check Enforcer to evaluate your pull request again. You can do this by adding a comment to this pull request as follows: What if I am onboarding a new service?Often, new services do not have validation pipelines associated with them, in order to bootstrap pipelines for a new service, you can issue the following command as a pull request comment: |
Updated README + removed unnecessary dependencies
sdk/iot/azure-iot-modelsrepository/azure/iot/modelsrepository/__init__.py
Outdated
Show resolved
Hide resolved
sdk/iot/azure-iot-modelsrepository/azure/iot/modelsrepository/client.py
Outdated
Show resolved
Hide resolved
sdk/iot/azure-iot-modelsrepository/azure/iot/modelsrepository/client.py
Outdated
Show resolved
Hide resolved
sdk/iot/azure-iot-modelsrepository/azure/iot/modelsrepository/pseudo_parser.py
Outdated
Show resolved
Hide resolved
sdk/iot/azure-iot-modelsrepository/azure/iot/modelsrepository/resolver.py
Outdated
Show resolved
Hide resolved
sdk/iot/azure-iot-modelsrepository/azure/iot/modelsrepository/resolver.py
Outdated
Show resolved
Hide resolved
sdk/iot/azure-iot-modelsrepository/azure/iot/modelsrepository/client.py
Outdated
Show resolved
Hide resolved
sdk/iot/azure-iot-modelsrepository/azure/iot/modelsrepository/client.py
Outdated
Show resolved
Hide resolved
sdk/iot/azure-iot-modelsrepository/azure/iot/modelsrepository/client.py
Outdated
Show resolved
Hide resolved
sdk/iot/azure-iot-modelsrepository/azure/iot/modelsrepository/client.py
Outdated
Show resolved
Hide resolved
more doc fixes
sdk/iot/azure-iot-modelsrepository/azure/iot/modelsrepository/_constants.py
Outdated
Show resolved
Hide resolved
sdk/iot/azure-iot-modelsrepository/azure/iot/modelsrepository/_client.py
Outdated
Show resolved
Hide resolved
sdk/iot/azure-iot-modelsrepository/azure/iot/modelsrepository/_client.py
Outdated
Show resolved
Hide resolved
sdk/iot/azure-iot-modelsrepository/azure/iot/modelsrepository/dtmi_conventions.py
Outdated
Show resolved
Hide resolved
sdk/iot/azure-iot-modelsrepository/samples/get_models_sample.py
Outdated
Show resolved
Hide resolved
sdk/iot/azure-iot-modelsrepository/azure/iot/modelsrepository/_client.py
Outdated
Show resolved
Hide resolved
sdk/iot/azure-iot-modelsrepository/azure/iot/modelsrepository/_client.py
Outdated
Show resolved
Hide resolved
Can we append at least you and me from the IoT D&D team as code owners for this project? |
sdk/iot/tests.yml
Outdated
BuildTargetingString: $(BuildTargetingString) | ||
ServiceDirectory: iot | ||
EnvVars: | ||
TEST_MODE: 'RunLiveNoRecord' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Normally we'd want to run recordings in the pipeline. The live tests happen locally and test recordings would be checked-in.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Recordings have not yet been generated due to a what appears to be a bug in the testing infrastructure. This will be changed once recordings can be generated.
"file:///myrepository/dtmi/com/somedomain/example/foodtdl-1.json", | ||
id="Filesystem URI", | ||
), | ||
pytest.param( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would be good to add a test case for basic windows UNC path...as an example getting the model uri for "dtmi:com:example:Thermostat;1" in the repository location of "\\server\repository" should net the uri of "file://server/repository/dtmi/com/example/thermostat-1.json"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The function .get_model_uri()
has been scoped to require the base path to already be provided in URI format (as opposed to the ModelsRepositoryClient itself, which does support non-URI filepaths). If you wish to expand it's functionality to support absolute paths (including UNC path format) being converted to file URI, this would be an additional feature that can be added at a later date.
@cartertinney The failure for
To unblock the check. Prior to your actual release, you'll need to update the date, something like.
Or the like. |
sdk/iot/azure-iot-modelsrepository/azure/iot/modelsrepository/_client.py
Outdated
Show resolved
Hide resolved
sdk/iot/azure-iot-modelsrepository/samples/get_models_sample.py
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have a number of follow up topics but I think we are at a solid baseline to build on.
Added yml infrastructure Commented links to pass CI removed artifact? Basic integration tests (local only) Added context manager support + integration tests Integration tests Added unittests Black formatting Infrastructure + py27 fixes Removed unnecessary file Addressed PR updated readme Added required fields to README packaging adjustments Added MANIFEST and updated version string updated logging details Version string updated to use b instead of rc Addressing PR DTDL -> model added greater requirement specificity remove duplicate pytest requirement from local dev_requirements.txt. update readme to correct match capitalization and add missing examples section. Address PR comments nspkg naming? Linting fixes More linting Linter suppression + fixes Fixed formatting line error that broke pylint Addressing PR feedback
yml fixes removed tests.yml from iot CODEOWNERS change restored original iot ci.yml
Co-authored-by: Sean Kane <[email protected]>
/check-enforcer override |
Overriding check enforcer, this is the initial cut at the new SDK, and no build definition yet exists. @cartertinney will submit PRs to deal with any failures AFTER the build definition exists. |
…into azure_purview_catalog * 'master' of https://github.com/Azure/azure-sdk-for-python: [Tables] hot fix for pipelines (Azure#18273) [Tables] Updates for apiview & sphinx docs (Azure#18134) override purview deps in shared reqs (Azure#18270) [Service Bus] fix deadletter sample + update README (Azure#18261) Update credential docstrings (Azure#18205) Refactor ImdsCredential to use ManagedIdentityClient (Azure#18120) [Key Vault] Target multiple API versions with tests (keys) (Azure#18149) Initial ModelsRepositoryClient (Azure#17180) [Communication]: Enabled Phone Number Search Test (Azure#18247) [Key Vault] Update default MHSM location for tests Update identity migration guide (Azure#18239) [AutoRelease] t2-managedservices-2021-04-22-08436(wave4) (Azure#18224) [AutoRelease] t2-hybridnetwork-2021-04-20-93742 (Azure#18169) Add Key Vault cert suppression (Azure#18245) update to aab1fb9 (Azure#18246) Enable retain runs. (Azure#18200) [formrecognizer] add testcases for labeled tables - fixed/variable rows (Azure#18214) Add caching support to verify-links (Azure#18231) add reading order for logging (Azure#18233) [purview] allow purview pylint failures (Azure#18237)
Initial ModelsRepositoryClient
Unittests + some integration tests will be added after API review signoff