Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .chronus/changes/fix-regen-baseline-path-2026-5-20.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
changeKind: internal
packages:
- "@typespec/http-client-python"
---

Update the baseline source for regeneration to use the `typespec-python-generated-tests` branch and `eng/tools/azure-sdk-tools/emitter/generated` path in `azure-sdk-for-python`, and enable `core.longpaths` on the temporary baseline clone to avoid Windows `MAX_PATH` errors during checkout.
Original file line number Diff line number Diff line change
Expand Up @@ -677,7 +677,7 @@ export async function preprocess(flavor: string, generatedFolder: string): Promi

/**
* Resets the `tests/generated/{azure,unbranded}` baseline by sparse-checking-out
* `eng/tools/emitter/gen` from the Azure/azure-sdk-for-python repo, then
* `eng/tools/azure-sdk-tools/emitter/generated` from the Azure/azure-sdk-for-python repo, then
* deleting a couple of fully-generated package folders so regeneration has to
* recreate them from scratch (smoke test of full-emit path).
*
Expand All @@ -686,8 +686,8 @@ export async function preprocess(flavor: string, generatedFolder: string): Promi
*/
export async function prepareBaselineOfGeneratedCode(generatedFolder: string): Promise<void> {
const repoUrl = "https://github.com/Azure/azure-sdk-for-python.git";
const branch = "main";
const sourceSubdir = "eng/tools/emitter/gen";
const branch = "typespec-python-generated-tests";
const sourceSubdir = "eng/tools/azure-sdk-tools/emitter/generated";
const testsGeneratedDir = resolve(generatedFolder, "../tests/generated");

console.log(pc.cyan(`\n${"=".repeat(60)}`));
Expand All @@ -708,6 +708,7 @@ export async function prepareBaselineOfGeneratedCode(generatedFolder: string): P
execSync(cmd, { cwd: tempDir, stdio: ["ignore", "ignore", "inherit"] });

run(`git init`);
run(`git config core.longpaths true`);
run(`git remote add origin ${repoUrl}`);
run(`git config core.sparseCheckout true`);
run(`git sparse-checkout init --cone`);
Expand Down
Loading