Skip to content

Commit

Permalink
Bump core from b2dc525 to e80bdce (#1648)
Browse files Browse the repository at this point in the history
Bumps [core](https://github.com/microsoft/typespec) from `b2dc525` to
`e80bdce`.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/microsoft/typespec/commit/e80bdce69982922b79cc59229432c769e93fe8c8"><code>e80bdce</code></a>
Fix: Passing <code>const</code> of model type to <code>@example</code>
(<a
href="https://redirect.github.com/microsoft/typespec/issues/4574">#4574</a>)</li>
<li><a
href="https://github.com/microsoft/typespec/commit/68c94a715bc84a2a0a782cbf42ced52a81224b4f"><code>68c94a7</code></a>
Add url property to diagnostic (<a
href="https://redirect.github.com/microsoft/typespec/issues/4442">#4442</a>)</li>
<li><a
href="https://github.com/microsoft/typespec/commit/7c425cdb08d1fadd00fda539966da5ce2b292e33"><code>7c425cd</code></a>
Fix enum in union example (<a
href="https://redirect.github.com/microsoft/typespec/issues/4462">#4462</a>)</li>
<li><a
href="https://github.com/microsoft/typespec/commit/0d1b320d70c8ec223d925a84f2d7389df8067630"><code>0d1b320</code></a>
<code>tsp compile --watch</code> watch config file (<a
href="https://redirect.github.com/microsoft/typespec/issues/4563">#4563</a>)</li>
<li><a
href="https://github.com/microsoft/typespec/commit/5145b902ff3fa691d741344ec6fab41cec18bc77"><code>5145b90</code></a>
Support customizing client accessibility (<a
href="https://redirect.github.com/microsoft/typespec/issues/4605">#4605</a>)</li>
<li><a
href="https://github.com/microsoft/typespec/commit/5e126782d508bbf48b7f1e286f06b8443aeaf232"><code>5e12678</code></a>
Add support for nested emitter options (<a
href="https://redirect.github.com/microsoft/typespec/issues/4539">#4539</a>)</li>
<li>See full diff in <a
href="https://github.com/microsoft/typespec/compare/b2dc52555f2b00250860821f37f1e5eafaa941bb...e80bdce69982922b79cc59229432c769e93fe8c8">compare
view</a></li>
</ul>
</details>
<br />


Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Timothee Guerin <[email protected]>
  • Loading branch information
dependabot[bot] and timotheeguerin authored Oct 4, 2024
1 parent 22aa5ee commit 433735c
Show file tree
Hide file tree
Showing 4 changed files with 41 additions and 41 deletions.
2 changes: 1 addition & 1 deletion core
Submodule core updated 48 files
+7 −0 .chronus/changes/config-invalid-name-2024-8-25-19-8-41.md
+8 −0 .chronus/changes/diagnostic-url-2024-8-13-19-59-26.md
+8 −0 .chronus/changes/fix-enum-in-union-example-2024-8-17-18-25-2.md
+8 −0 .chronus/changes/fix-examples-const-2024-8-30-17-28-17.md
+8 −0 .chronus/changes/fix-watch-config-2024-8-27-22-7-45.md
+7 −0 .chronus/changes/support-variable-base-nested-config-2024-8-25-19-8-41.md
+1 −0 docs/extending-typespec/emitters-basics.md
+14 −1 docs/handbook/configuration/configuration.md
+25 −0 docs/standard-library/diags/triple-quote-indent.md
+12 −0 docs/standard-library/examples.md
+57 −13 packages/compiler/src/config/config-interpolation.ts
+56 −5 packages/compiler/src/config/config-to-options.ts
+2 −1 packages/compiler/src/core/checker.ts
+2 −0 packages/compiler/src/core/cli/actions/compile/args.ts
+45 −23 packages/compiler/src/core/cli/actions/compile/compile.ts
+5 −1 packages/compiler/src/core/diagnostic-creator.ts
+1 −1 packages/compiler/src/core/logger/console-sink.ts
+9 −0 packages/compiler/src/core/messages.ts
+26 −0 packages/compiler/src/core/types.ts
+2 −3 packages/compiler/src/lib/examples.ts
+43 −0 packages/compiler/test/config/config-interpolation.test.ts
+76 −0 packages/compiler/test/config/config-to-options.test.ts
+17 −0 packages/compiler/test/config/resolve-compiler-option.test.ts
+17 −0 packages/compiler/test/config/scenarios/custom/myConfigNested.yaml
+36 −0 packages/compiler/test/decorators/examples.test.ts
+32 −0 packages/compiler/test/e2e/cli/cli.e2e.ts
+23 −0 packages/compiler/test/e2e/cli/scenarios/with-option/emitter.js
+1 −0 packages/compiler/test/e2e/cli/scenarios/with-option/main.tsp
+25 −0 packages/compiler/test/e2e/cli/scenarios/with-option/tspconfig.yaml
+2 −0 .../http-client-csharp/generator/Microsoft.Generator.CSharp.ClientModel/src/Providers/ClientOptionsProvider.cs
+2 −0 packages/http-client-csharp/generator/Microsoft.Generator.CSharp.ClientModel/src/Providers/ClientProvider.cs
+2 −0 ...ges/http-client-csharp/generator/Microsoft.Generator.CSharp.ClientModel/src/Providers/RestClientProvider.cs
+15 −8 ...client-csharp/generator/Microsoft.Generator.CSharp.ClientModel/src/Providers/ScmMethodProviderCollection.cs
+72 −1 ...r/Microsoft.Generator.CSharp.ClientModel/test/Providers/ClientProviders/ClientProviderCustomizationTests.cs
+0 −3 ...Model/test/Providers/ClientProviders/TestData/ClientProviderCustomizationTests/CanAddMethod/CanAddMethod.cs
+0 −3 ...ders/ClientProviders/TestData/ClientProviderCustomizationTests/CanAddMethodSameName/CanAddMethodSameName.cs
+0 −3 ...rs/ClientProviders/TestData/ClientProviderCustomizationTests/CanAddMultipleMethods/CanAddMultipleMethods.cs
+8 −0 ...ders/TestData/ClientProviderCustomizationTests/CanChangeClientAccessibility/CanChangeClientAccessibility.cs
+12 −0 ...ClientProviderCustomizationTests/CanChangeClientOptionsAccessibility/CanChangeClientOptionsAccessibility.cs
+1 −4 ...roviders/ClientProviders/TestData/ClientProviderCustomizationTests/CanReplaceOpMethod/CanReplaceOpMethod.cs
+1 −4 .../ClientProviders/TestData/ClientProviderCustomizationTests/CanReplaceStructMethod/CanReplaceStructMethod.cs
+0 −1 ...ers/MrwSerializationTypeDefinitions/TestData/SerializationCustomizationTests/CanChangePropertyName/Model.cs
+0 −1 ...nTypeDefinitions/TestData/SerializationCustomizationTests/CanCustomizeSerializationMethod/MockInputModel.cs
+0 −1 ...estData/SerializationCustomizationTests/CanCustomizeSerializationMethodForRenamedProperty/MockInputModel.cs
+0 −1 ...TypeDefinitions/TestData/SerializationCustomizationTests/ReadOnlyMemPropertyType/ReadOnlyMemPropertyType.cs
+1 −1 packages/http-client-csharp/generator/Microsoft.Generator.CSharp/src/Providers/TypeProvider.cs
+19 −0 packages/openapi3/test/examples.test.ts
+10 −0 packages/website/sidebars.ts
22 changes: 11 additions & 11 deletions packages/typespec-azure-core/generated-defs/Azure.Core.Traits.ts
Original file line number Diff line number Diff line change
@@ -1,15 +1,5 @@
import type { DecoratorContext, EnumMember, Model, ModelProperty, Type } from "@typespec/compiler";

/**
* `@trait` marks a model type as representing a 'trait' and performs basic validation
* checks.
*
* @param target The model type to mark as a trait.
* @param traitName An optional name to uniquely identify the trait. If unspecified,
* the model type name is used.
*/
export type TraitDecorator = (context: DecoratorContext, target: Model, traitName?: string) => void;

/**
* `@traitLocation` sets the applicable location for a trait on its envelope property.
*
Expand All @@ -36,6 +26,16 @@ export type TraitContextDecorator = (
contexts: Type,
) => void;

/**
* `@trait` marks a model type as representing a 'trait' and performs basic validation
* checks.
*
* @param target The model type to mark as a trait.
* @param traitName An optional name to uniquely identify the trait. If unspecified,
* the model type name is used.
*/
export type TraitDecorator = (context: DecoratorContext, target: Model, traitName?: string) => void;

/**
* Sets the version for when the trait was added to the specification. Can be applied
* to either a trait model type or its envelope property.
Expand All @@ -49,8 +49,8 @@ export type TraitAddedDecorator = (
) => void;

export type AzureCoreTraitsDecorators = {
trait: TraitDecorator;
traitLocation: TraitLocationDecorator;
traitContext: TraitContextDecorator;
trait: TraitDecorator;
traitAdded: TraitAddedDecorator;
};
12 changes: 6 additions & 6 deletions packages/typespec-azure-core/generated-defs/Azure.Core.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,6 @@ export type PollingLocationDecorator = (
options?: Type,
) => void;

/**
* Marks a Model as a paged collection.
*/
export type PagedResultDecorator = (context: DecoratorContext, entity: Model) => void;

/**
* Identifies the ModelProperty that contains the paged items. Can only be used on a Model marked with `@pagedResult`.
*/
Expand All @@ -60,6 +55,11 @@ export type ItemsDecorator = (context: DecoratorContext, entity: ModelProperty)
*/
export type NextLinkDecorator = (context: DecoratorContext, entity: ModelProperty) => void;

/**
* Marks a Model as a paged collection.
*/
export type PagedResultDecorator = (context: DecoratorContext, entity: Model) => void;

/**
* Marks an Enum as being fixed since enums in Azure are
* assumed to be extensible.
Expand Down Expand Up @@ -193,9 +193,9 @@ export type AzureCoreDecorators = {
lroStatus: LroStatusDecorator;
finalLocation: FinalLocationDecorator;
pollingLocation: PollingLocationDecorator;
pagedResult: PagedResultDecorator;
items: ItemsDecorator;
nextLink: NextLinkDecorator;
pagedResult: PagedResultDecorator;
fixed: FixedDecorator;
lroSucceeded: LroSucceededDecorator;
lroCanceled: LroCanceledDecorator;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,24 @@ import type { DecoratorContext, Model, ModelProperty, Operation, Type } from "@t
*
*
*
* @param propertyName Name of the property to omit
* @param values Values
*/
export type ResourceBaseParametersOfDecorator = (
export type ResourceParameterBaseForDecorator = (
context: DecoratorContext,
target: Model,
propertyName: Model,
target: ModelProperty,
values: Type,
) => void;

/**
*
*
*
* @param values Values
* @param propertyName Name of the property to omit
*/
export type ResourceParameterBaseForDecorator = (
export type ResourceBaseParametersOfDecorator = (
context: DecoratorContext,
target: ModelProperty,
values: Type,
target: Model,
propertyName: Model,
) => void;

/**
Expand All @@ -32,6 +32,19 @@ export type ResourceParameterBaseForDecorator = (
*/
export type AzureResourceBaseDecorator = (context: DecoratorContext, target: Model) => void;

/**
* Please DO NOT USE in RestAPI specs.
* Internal decorator that deprecated direct usage of `x-ms-client-flatten` OpenAPI extension.
* It will programatically enabled/disable client flattening with
*
* @flattenProperty with autorest
* emitter flags to maintain compatibility in swagger.
*/
export type ConditionalClientFlattenDecorator = (
context: DecoratorContext,
target: ModelProperty,
) => void;

/**
* Omit a property in the target model.
*
Expand All @@ -46,19 +59,6 @@ export type OmitIfEmptyDecorator = (
propertyName: string,
) => void;

/**
* Please DO NOT USE in RestAPI specs.
* Internal decorator that deprecated direct usage of `x-ms-client-flatten` OpenAPI extension.
* It will programatically enabled/disable client flattening with
*
* @flattenProperty with autorest
* emitter flags to maintain compatibility in swagger.
*/
export type ConditionalClientFlattenDecorator = (
context: DecoratorContext,
target: ModelProperty,
) => void;

/**
*
*
Expand Down Expand Up @@ -154,11 +154,11 @@ export type ArmResourcePropertiesOptionalityDecorator = (
) => void;

export type AzureResourceManagerPrivateDecorators = {
resourceBaseParametersOf: ResourceBaseParametersOfDecorator;
resourceParameterBaseFor: ResourceParameterBaseForDecorator;
resourceBaseParametersOf: ResourceBaseParametersOfDecorator;
azureResourceBase: AzureResourceBaseDecorator;
omitIfEmpty: OmitIfEmptyDecorator;
conditionalClientFlatten: ConditionalClientFlattenDecorator;
omitIfEmpty: OmitIfEmptyDecorator;
assignProviderNameValue: AssignProviderNameValueDecorator;
armUpdateProviderNamespace: ArmUpdateProviderNamespaceDecorator;
armResourceInternal: ArmResourceInternalDecorator;
Expand Down

0 comments on commit 433735c

Please sign in to comment.