Azure / typespec-azure

About TypeSpec Azure Libraries
https://azure.github.io/typespec-azure/
MIT License
9 stars 29 forks source link

location type should be azureLocation instead of string #1139

Closed live1206 closed 1 week ago

live1206 commented 2 weeks ago

resolves https://github.com/Azure/typespec-azure/issues/1138

azure-sdk commented 2 weeks ago

All changed packages have been documented.

Show changes ### `@azure-tools/typespec-azure-resource-manager` - _fix_ [✏️](https://github.com/live1206/typespec-azure/edit/azure-location/.chronus/changes/azure-location-2024-6-9-16-54-5.md?pr=/Azure/typespec-azure/pull/1139) > LocationResourceParameter should be azureLocation instead of string
azure-sdk commented 2 weeks ago

You can try these changes at https://cadlplayground.z22.web.core.windows.net/typespec-azure/prs/1139/

Check the website changes at https://tspwebsitepr.z22.web.core.windows.net/typespec-azure/prs/1139/

live1206 commented 2 weeks ago

looks liek the ci need to regen the common types pnpm regen-samples

@timotheeguerin pnpm regen-samples is failing for me as below, is there any existing issue or am I missing any step here?

│  ❯ |azure-samples| test/samples.test.ts  (53 tests | 16 failed) 48112ms
│    ❯ test/samples.test.ts > TypeSpec Azure Samples > Azure Resource Manager > arm-library
│      → Unexpected diagnostics:
│ C:/src/typespec-azure/packages/typespec-azure-resource-manager/lib/private.decorators.tsp:76:12 - error missing-implementation: Extern declaration must have an implementation in JS file.
│    ❯ test/samples.test.ts > TypeSpec Azure Samples > Azure Resource Manager > contoso
│      → Unexpected diagnostics:
│ C:/src/typespec-azure/packages/typespec-azure-resource-manager/lib/private.decorators.tsp:76:12 - error missing-implementation: Extern declaration must have an implementation in JS file.
│    ❯ test/samples.test.ts > TypeSpec Azure Samples > Azure Resource Manager > legacy/managed-identity
│      → Unexpected diagnostics:
│ C:/src/typespec-azure/packages/typespec-azure-resource-manager/lib/private.decorators.tsp:76:12 - error missing-implementation: Extern declaration must have an implementation in JS file.
│    ❯ test/samples.test.ts > TypeSpec Azure Samples > Azure Resource Manager > operations/nobody-action
│      → Unexpected diagnostics:
│ C:/src/typespec-azure/packages/typespec-azure-resource-manager/lib/private.decorators.tsp:76:12 - error missing-implementation: Extern declaration must have an implementation in JS file.

I had a look at the file image

So, seems like there is an existing issue here?

timotheeguerin commented 1 week ago

regen samples is run as part of the CI so highly doubt there is an issue, have you built the entire repo following the CONTRIBUTING guide

allenjzhang commented 1 week ago

1138

live1206 commented 1 week ago

regen samples is run as part of the CI so highly doubt there is an issue, have you built the entire repo following the CONTRIBUTING guide

I did this a while ago, need to do it again, and the samples are updated now.

live1206 commented 1 week ago

@allenjzhang If you don't have any objection on this, I will merge this PR tomorrow.