Skip to content

[python] fix: use azure-http-specs check for spec flavor detection#10554

Open
iscai-msft wants to merge 5 commits intomicrosoft:mainfrom
iscai-msft:python/fix-azure-spec-detection
Open

[python] fix: use azure-http-specs check for spec flavor detection#10554
iscai-msft wants to merge 5 commits intomicrosoft:mainfrom
iscai-msft:python/fix-azure-spec-detection

Conversation

@iscai-msft
Copy link
Copy Markdown
Member

spec.includes('azure') falsely matches when the working directory contains 'azure' (e.g. running from azure-sdk-for-python), causing all specs to be treated as azure specs and producing incorrect package names like ..-..-..-@typespec-http-specs-specs-.

Changed to spec.includes('azure-http-specs') which only matches actual azure spec paths from @azure-tools/azure-http-specs.

spec.includes('azure') falsely matches when the working directory
contains 'azure' (e.g. running from azure-sdk-for-python), causing
all specs to be treated as azure specs and producing incorrect
package names like ..-..-..-@typespec-http-specs-specs-<name>.

Changed to spec.includes('azure-http-specs') which only matches
actual azure spec paths from @azure-tools/azure-http-specs.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@microsoft-github-policy-service microsoft-github-policy-service Bot added the emitter:client:python Issue for the Python client emitter: @typespec/http-client-python label Apr 29, 2026
Merge regenerate-common.ts into regenerate.ts since it had only one
consumer. Also fix spec.includes('azure') which falsely matched when
the working directory contained 'azure' (e.g. azure-sdk-for-python),
causing incorrect package names for unbranded specs.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@iscai-msft iscai-msft enabled auto-merge April 29, 2026 17:01
Comment thread packages/http-client-python/eng/scripts/ci/regenerate.ts Outdated
@pkg-pr-new
Copy link
Copy Markdown

pkg-pr-new Bot commented Apr 29, 2026

Open in StackBlitz

npm i https://pkg.pr.new/@typespec/http-client-python@10554

commit: 7be89fe

@azure-sdk
Copy link
Copy Markdown
Collaborator

azure-sdk commented Apr 29, 2026

You can try these changes here

🛝 Playground 🌐 Website 🛝 VSCode Extension

iscai-msft and others added 2 commits April 29, 2026 13:19
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Apr 29, 2026

All changed packages have been documented.

  • @typespec/http-client-python
Show changes

@typespec/http-client-python - internal ✏️

Consolidate regenerate-common.ts into regenerate.ts and fix azure spec detection using azure-http-specs path check

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

emitter:client:python Issue for the Python client emitter: @typespec/http-client-python

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants