Skip to content

fix(azure): update DatastoreType import#4181

Open
fengjikui wants to merge 1 commit into
microsoft:mainfrom
fengjikui:fix-azure-datastore-type-import
Open

fix(azure): update DatastoreType import#4181
fengjikui wants to merge 1 commit into
microsoft:mainfrom
fengjikui:fix-azure-datastore-type-import

Conversation

@fengjikui

Copy link
Copy Markdown

Summary

  • Stop importing DatastoreType from the removed azure.ai.ml._restclient.v2022_10_01 namespace.
  • Add a small promptflow-azure compat module that uses the available v2022_10_01_preview namespace and falls back to the old namespace for older SDK layouts.
  • Update the two promptflow-azure call sites to share the compat import.

Fixes #4176.

Verification

  • uv run --with azure-ai-ml==1.33.0 python - <<'PY' ... verified the compat module resolves AzureBlob, AzureDataLakeGen2, and AzureFile under azure-ai-ml==1.33.0.
  • python3 -m py_compile src/promptflow-azure/promptflow/azure/_utils/_datastore_type.py src/promptflow-azure/promptflow/azure/operations/_artifact_utilities.py src/promptflow-azure/promptflow/azure/_storage/blob/client.py src/promptflow-azure/tests/sdk_cli_azure_test/unittests/test_blob_client.py
  • uvx black --check src/promptflow-azure/promptflow/azure/_utils/_datastore_type.py src/promptflow-azure/promptflow/azure/operations/_artifact_utilities.py src/promptflow-azure/promptflow/azure/_storage/blob/client.py src/promptflow-azure/tests/sdk_cli_azure_test/unittests/test_blob_client.py
  • git diff --check

I also tried the repository's poetry install --with ci,test from src/promptflow-azure, but dependency resolution did not complete locally after several minutes, so I kept local validation focused on the import compatibility path.

@fengjikui

Copy link
Copy Markdown
Author

@microsoft-github-policy-service agree

@github-actions

Copy link
Copy Markdown

Hi, thank you for your interest in helping to improve the prompt flow experience and for your contribution. We've noticed that there hasn't been recent engagement on this pull request. If this is still an active work stream, please let us know by pushing some changes or leaving a comment.

@github-actions github-actions Bot added the no-recent-activity There has been no recent activity on this issue/pull request label Jun 21, 2026
@fengjikui

Copy link
Copy Markdown
Author

Still active from my side. I rechecked that the PR is mergeable and the visible checks are green; happy to adjust if the DatastoreType compatibility import should follow a different preferred path.

@github-actions github-actions Bot removed the no-recent-activity There has been no recent activity on this issue/pull request label Jun 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] promptflow-azure fails with azure-ai-ml 1.33.0 due to private DatastoreType import

1 participant