Skip to content

Commit

Permalink
Bump core from 7452fe9 to afd3772 (#246)
Browse files Browse the repository at this point in the history
Bumps [core](https://github.com/microsoft/typespec) from `7452fe9` to
`afd3772`.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/microsoft/typespec/commit/afd377242ea73eaace3460cd327ee74c52d5933f"><code>afd3772</code></a>
Include tmlanguage computed file in repo as we'll need it for github
linguist...</li>
<li><a
href="https://github.com/microsoft/typespec/commit/24d3ba0add5bf315b902bdd97226cc0aa0e6c0c3"><code>24d3ba0</code></a>
Update docs to clarify range of <code>numeric</code>,
<code>integer</code>, etc. and meaning of uni...</li>
<li><a
href="https://github.com/microsoft/typespec/commit/71fa90963466e4ab8da5ed287bc64de546fc67fe"><code>71fa909</code></a>
Fix: No colors when using <code>--watch</code> (<a
href="https://redirect.github.com/microsoft/typespec/issues/2886">#2886</a>)</li>
<li><a
href="https://github.com/microsoft/typespec/commit/a1eb851cc3cd6919fe7a341210fefe185167bbe9"><code>a1eb851</code></a>
Enable spell check for all files and fix (<a
href="https://redirect.github.com/microsoft/typespec/issues/2881">#2881</a>)</li>
<li>See full diff in <a
href="https://github.com/microsoft/typespec/compare/7452fe9a5793554e5fd7b3337a356024cc89fd50...afd377242ea73eaace3460cd327ee74c52d5933f">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 Feb 9, 2024
1 parent ea1b225 commit 6493de9
Show file tree
Hide file tree
Showing 45 changed files with 115 additions and 85 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
changeKind: internal
packages:
- "@azure-tools/typespec-client-generator-core"
---

3 changes: 3 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -70,3 +70,6 @@ core/packages/compiler/templates/__snapshots__/
# Skip formatting tsp files

*.noformat.tsp

# Tm Grammars generated files
core/grammars/
2 changes: 1 addition & 1 deletion core
Submodule core updated 28 files
+3 −0 .changeset/docs-update-types-descriptions-2024-1-7-21-24-55.md
+6 −0 .chronus/changes/docs-update-types-descriptions-2024-1-9-0-53-22.md
+6 −0 .chronus/changes/fix-spellcheck-2024-1-8-23-16-15.md
+8 −0 .chronus/changes/tmlanguage-published-2024-1-9-1-17-15.md
+8 −0 .chronus/changes/watch-color-2024-1-8-23-15-57.md
+3 −0 .prettierignore
+0 −1 .vscode/settings.json
+15 −0 cspell.yaml
+8 −4 docs/language-basics/built-in-types.md
+1,271 −0 grammars/typespec.json
+1 −1 package.json
+2 −1 packages/compiler/lib/decorators.tsp
+0 −1 packages/compiler/lib/lib.tsp
+5 −4 packages/compiler/src/core/cli/actions/compile/compile.ts
+3 −3 packages/compiler/src/core/cli/actions/compile/watch.ts
+5 −0 packages/compiler/src/server/tmlanguage.ts
+1 −1 packages/http/lib/auth.tsp
+2 −2 packages/samples/specs/binary/binary.tsp
+1 −1 packages/samples/specs/documentation/docs.tsp
+1 −1 packages/samples/specs/encoded-names/encoded-names.tsp
+2 −2 packages/samples/specs/string-template/main.tsp
+2 −2 packages/samples/specs/testserver/body-complex/body-complex.tsp
+1 −0 packages/samples/specs/testserver/body-string/body-string.tsp
+2 −2 packages/samples/test/output/binary/@typespec/openapi3/openapi.yaml
+1 −1 packages/samples/test/output/documentation/@typespec/openapi3/openapi.yaml
+1 −1 packages/samples/test/output/encoded-names/@typespec/openapi3/openapi.yaml
+2 −2 packages/samples/test/output/testserver/body-complex/@typespec/openapi3/openapi.yaml
+2 −0 packages/website/src/css/custom.css
21 changes: 17 additions & 4 deletions cspell.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,18 @@ ignorePaths:
- "**/CHANGELOG.md"
- common/scripts/*
- packages/website/build/*
- pnpm-lock.yaml
- eng/feeds/**/examples/**
- packages/samples/test/output/**
useGitignore: true
enableFiletypes:
- cadl
- tsp
- typespec
words:
- allof
- apim
- apos
- armId
- azsdk
- Bazs
- byos
Expand All @@ -29,20 +35,27 @@ words:
- foos
- horiz
- Howtos
- infile
- kvset
- liftr
- logz
- LRO
- lropaging
- Lucene
- msazure
- msdata
- mylocation
- nupkg
- odata
- Onco
- oncophenotype
- PAYG
- prismjs
- qnas
- regionality
- Reranker
- rpaasoneboxacr
- rpass
- SERVICERP
- userrp
- lropaging
- armId
- tcgc
- userrp
4 changes: 2 additions & 2 deletions eng/scripts/new_service_adoption.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,9 +74,9 @@ def pr_for_new_service(pr, files: list[dict]):
# Make sure there are at least 4 path segments
pattern = r'specification/[a-z-]+/(data-plane|resource-manager)/.*/.*'
filenames = [x['filename'] for x in files]
xfiles = [x for x in filenames if re.match(pattern, x) and 'common' not in x]
x_files = [x for x in filenames if re.match(pattern, x) and 'common' not in x]
# The namespace is the combined 3 path segments after "specification"
namespaces = list({'/'.join(x.split('/')[1:4]) for x in xfiles})
namespaces = list({'/'.join(x.split('/')[1:4]) for x in x_files})
for namespace in namespaces:
if non_public(namespace):
continue
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"check-version-mismatch": "syncpack list-mismatches",
"change": "chronus",
"clean": "pnpm run-all run clean",
"cspell": "cspell --no-progress \"**/*.{md,ts,tsx}\" ",
"cspell": "cspell --no-progress .",
"dogfood": "pnpm install && pnpm build && pnpm run-all dogfood",
"fix-version-mismatch": "syncpack fix-mismatches",
"format": "pnpm run prettier --write",
Expand Down
2 changes: 1 addition & 1 deletion packages/samples/specs/data-plane/formrecognizer/main.tsp
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,7 @@ enum AnalyzeResultOperationStatus {
notStarted,

@doc("Operation is running.")
runnning,
running,

@doc("Operation has failed.")
failed,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -272,9 +272,8 @@ interface Projects {
>;

#suppress "@azure-tools/typespec-azure-core/long-running-polling-operation-required" "This operation does not follow the standard long-running operation pattern."
// NOTE: `import` is a reserved keyword
@doc("Triggers a job to export a project's data.")
importx is Operations.ResourceAction<
`import` is Operations.ResourceAction<
Project,
ExportedProject,
TypeSpec.Http.AcceptedResponse & Foundations.LongRunningStatusLocation
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ import "@typespec/http";
import "@typespec/rest";
import "@typespec/openapi";

// cspell:ignore qnas

using TypeSpec.Http;
using TypeSpec.OpenAPI;

Expand Down Expand Up @@ -93,7 +95,7 @@ model MaxPageSizeParameter {
@extension("x-ms-parameter-location", "method")
@doc("The maximum number of resources to include in a single response")
@query
mazpagesize?: int32;
maxpagesize?: int32;
}

alias ListParameters = TopParameter & SkipParameter & MaxPageSizeParameter;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ interface Synonyms
interface Sources
extends ResourceUpdate<QnaSourceRecord, ODataError>,
ResourceList<QnaSourceRecord, ODataError> {
// TODO: Singlton Resource not represented correctly
// TODO: Singleton Resource not represented correctly
@get
@route("{projectName}/sources/jobs/{jobId}")
GetJob(...ResourceParameters<QnaSourceRecord>, ...JobIdParameter): JobState | ODataError;
Expand Down
1 change: 0 additions & 1 deletion packages/samples/specs/data-plane/languageqna/Raw/main.tsp
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,6 @@ namespace QuestionAnsweringProjects {
JobMetadata
>;

// TODO: ok resonse code is incorrect
@post
@doc("Update Active Learning feedback.")
@action("feedback")
Expand Down
6 changes: 4 additions & 2 deletions packages/samples/specs/data-plane/searchindex/main.tsp
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
// ISSUE: Can't set service description: https://github.com/Azure/typespec-azure/issues/1032
// ISSUE: @extension on parameter doesn't work: https://github.com/Azure/typespec-azure/issues/1121

// cspell:ignore Viet

import "@typespec/http";
import "@typespec/rest";
import "@typespec/openapi";
Expand Down Expand Up @@ -37,7 +39,7 @@ enum AutocompleteMode {
@doc("Only one term is suggested. If the query has two terms, only the last term is completed. For example, if the input is 'washington medic', the suggested terms could include 'medicaid', 'medicare', and 'medicine'.")
OneTerm: "oneTerm",

@doc("Matching two-term phrases in the index will be suggested. For example, if the inpu.t is 'medic', the suggested terms could include 'medicare coverage' and 'medical assistant'.")
@doc("Matching two-term phrases in the index will be suggested. For example, if the input is 'medic', the suggested terms could include 'medicare coverage' and 'medical assistant'.")
TwoTerms: "twoTerms",

@doc("Completes the last term in a query with two or more terms, where the last two terms are a phrase that exists in the index. For example, if the input is 'washington medic', the suggested terms could include 'washington medicaid' and 'washington medical'.")
Expand Down Expand Up @@ -1041,7 +1043,7 @@ interface Documents {
}

// ISSUE: Can't respond with empty object: https://github.com/Azure/typespec-azure/issues/1122.
// They probably meant to have additonalProperties here? Surely this doesn't literally return `{}` always?
// They probably meant to have additionalProperties here? Surely this doesn't literally return `{}` always?
@tag("Documents")
@route("/docs('{key}')")
interface DocumentsByKey {
Expand Down
2 changes: 2 additions & 0 deletions packages/samples/specs/data-plane/searchservice/languages.tsp
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
namespace Azure.SearchService;

// cspell:ignore Bangla Bokmaal Bokmål Piqd Kiswahili Yucatec Otomi

@doc("The language codes supported for input text by KeyPhraseExtractionSkill.")
enum KeyPhraseExtractionSkillLanguage {
@doc("Danish") da,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ using TypeSpec.Rest.Resource;
@tag("DataSources")
interface DatasourcesApis {
@route("/datasources")
@doc("Lists all indexe data sources available for a search service.")
@doc("Lists all indexes data sources available for a search service.")
@get
list(...SelectParameter, ...ClientRequestIdParameter, ...ApiVersionParameter): CollectionResult<
SearchIndexerDataSource,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
import "./searchservice.models.tsp";

// cspell:ignore Bangla Bokmaal Bokmål kstem Sorani Decompounder TFIDF

using TypeSpec.OpenAPI;
using TypeSpec.Rest;

Expand Down Expand Up @@ -628,7 +630,7 @@ enum LexicalTokenizerName {
@doc("Grammar-based tokenizer that is suitable for processing most European-language documents. See http://lucene.apache.org/core/4_10_3/analyzers-common/org/apache/lucene/analysis/standard/ClassicTokenizer.html")
Classic: "classic",

@doc("Tokenizes the input from an edge into n-grams of the given size(s). See https://lucene.apache.org/core/4_10_3/analyzers-common/org/apache/lucene/analysis/ngram/EdgeNGramTokenizer.html")
@doc("Tokenize the input from an edge into n-grams of the given size(s). See https://lucene.apache.org/core/4_10_3/analyzers-common/org/apache/lucene/analysis/ngram/EdgeNGramTokenizer.html")
EdgeNGram: "edgeNGram",

@doc("Emits the entire input as a single token. See http://lucene.apache.org/core/4_10_3/analyzers-common/org/apache/lucene/analysis/core/KeywordTokenizer.html")
Expand All @@ -646,7 +648,7 @@ enum LexicalTokenizerName {
@doc("Divides text using language-specific rules and reduces words to their base forms.")
MicrosoftLanguageStemmingTokenizer: "microsoft_language_stemming_tokenizer",

@doc("Tokenizes the input into n-grams of the given size(s). See http://lucene.apache.org/core/4_10_3/analyzers-common/org/apache/lucene/analysis/ngram/NGramTokenizer.html")
@doc("Tokenize the input into n-grams of the given size(s). See http://lucene.apache.org/core/4_10_3/analyzers-common/org/apache/lucene/analysis/ngram/NGramTokenizer.html")
NGram: "nGram",

@doc("Tokenizer for path-like hierarchies. See http://lucene.apache.org/core/4_10_3/analyzers-common/org/apache/lucene/analysis/path/PathHierarchyTokenizer.html")
Expand All @@ -658,7 +660,7 @@ enum LexicalTokenizerName {
@doc("Standard Lucene analyzer; Composed of the standard tokenizer, lowercase filter and stop filter. See http://lucene.apache.org/core/4_10_3/analyzers-common/org/apache/lucene/analysis/standard/StandardTokenizer.html")
Standard: "standard_v2",

@doc("Tokenizes urls and emails as one token. See http://lucene.apache.org/core/4_10_3/analyzers-common/org/apache/lucene/analysis/standard/UAX29URLEmailTokenizer.html")
@doc("Tokenize urls and emails as one token. See http://lucene.apache.org/core/4_10_3/analyzers-common/org/apache/lucene/analysis/standard/UAX29URLEmailTokenizer.html")
UaxUrlEmail: "uax_url_email",

@doc("Divides text at whitespace. See http://lucene.apache.org/core/4_10_3/analyzers-common/org/apache/lucene/analysis/core/WhitespaceTokenizer.html")
Expand Down Expand Up @@ -819,7 +821,7 @@ model ClassicTokenizer extends LexicalTokenizer {
maxTokenLength?: int32 = 255;
}

@doc("Tokenizes the input from an edge into n-grams of the given size(s). This tokenizer is implemented using Apache Lucene.")
@doc("Tokenize the input from an edge into n-grams of the given size(s). This tokenizer is implemented using Apache Lucene.")
model EdgeNGramTokenizer extends LexicalTokenizer {
`@odata.type`: "#Microsoft.Azure.Search.EdgeNGramTokenizer";

Expand Down Expand Up @@ -1164,7 +1166,7 @@ enum MicrosoftStemmingTokenizerLanguage {
Vietnamese: "vietnamese",
}

@doc("Tokenizes the input into n-grams of the given size(s). This tokenizer is implemented using Apache Lucene.")
@doc("Tokenize the input into n-grams of the given size(s). This tokenizer is implemented using Apache Lucene.")
model NGramTokenizer extends LexicalTokenizer {
`@odata.type`: "#Microsoft.Azure.Search.NGramTokenizer";

Expand Down Expand Up @@ -1236,7 +1238,7 @@ model LuceneStandardTokenizerV2 extends LexicalTokenizer {
maxTokenLength?: int32 = 255;
}

@doc("Tokenizes urls and emails as one token. This tokenizer is implemented using Apache Lucene.")
@doc("Tokenize urls and emails as one token. This tokenizer is implemented using Apache Lucene.")
model UaxUrlEmailTokenizer extends LexicalTokenizer {
`@odata.type`: "#Microsoft.Azure.Search.UaxUrlEmailTokenizer";

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
import "@typespec/http";
import "@typespec/rest";

// cspell:ignore adls adlsgen

import "./dataIdentity.model.tsp";
import "./dataPolicy.model.tsp";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ interface TenantOperations
extends ProxyResourceOperations<TestTenantResource>,
ResourceUpdate<TestTenantResource, TestTenantProperties> {}

@doc("rp-specific proeprties for the resource")
@doc("rp-specific properties for the resource")
model TestTenantProperties {
@doc("The status of the last operation performed on this resource.")
provisioningState: ResourceProvisioningState;
Expand All @@ -107,7 +107,7 @@ interface ExtensionOperations
extends ProxyResourceOperations<TestExtensionResource>,
ResourceUpdate<TestExtensionResource, TestExtensionProperties> {}

@doc("rp-specific proeprties for the resource")
@doc("rp-specific properties for the resource")
model TestExtensionProperties {
@doc("The status of the last operation performed on this resource.")
provisioningState: ResourceProvisioningState;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ interface Tracked2Operations {
listBySubscription is ArmListBySubscription<TestTrackedResource2>;
}

@doc("rp-specific proeprties for the resource with all envelope properties")
@doc("rp-specific properties for the resource with all envelope properties")
model TestTrackedProperties2 {
@doc("The status of the last operation performed on this resource.")
provisioningState: ResourceProvisioningState;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,11 +122,11 @@ model Dependent is ProxyResource<DependentProperties> {
name: string;
}

/** Depedent properties */
/** Dependent properties */
model DependentProperties {
/** Age of depedent */
/** Age of dependent */
age: int32;

/** Gender of depedent */
/** Gender of dependent */
gender: string;
}
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace Microsoft.UpdateTests;

interface Operations extends Azure.ResourceManager.Operations {}

@doc("Widget Resoruce")
@doc("Widget Resource")
model WidgetResource is TrackedResource<WidgetResourceProperties> {
@doc("The name of the widget.")
@key("widgetName")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ model AllPropertiesResource is TrackedResource<AllPropertiesProperties> {
interface AllProperties
extends TrackedResourceOperations<AllPropertiesResource, AllPropertiesProperties> {}

@doc("rp-specific proeprties for the resource with all envelope properties")
@doc("rp-specific properties for the resource with all envelope properties")
model AllPropertiesProperties {
@doc("The status of the last operation performed on this resource.")
provisioningState: EnvelopeProvisioningState;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@ namespace Organization
{
@get op get(@path subscription: string, @path resourceGroup: string, @path name: string) : ArmResponse<Organization>;

@slro("/operations", OperationStatus)
@lro("/operations", OperationStatus)
@put op createOrUpdate(@path subscription: string, @path resourceGroup: string, @path name: string, Organization) : ArmResponse<Organization>;
@patch op update(@path subscription: string, @path resourceGroup: string, @path name: string, OrganizationUpdate) : ArmResponse<Organization>;

@slro("/operations", OperationStatus)
@lro("/operations", OperationStatus)
@delete op delete(@path subscription: string, @path resourceGroup: string, @path name: string) : ArmResponse;

@post op getKeys(@path subscription: string, @path resourceGroup: string, @path name: string) : ArmResponse<OrganizationKeys>;
Expand Down
2 changes: 1 addition & 1 deletion packages/samples/specs/resource-manager/logz/models.tsp
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ model FilteringTag {
@doc("The value of the tag.")
value: string;

@doc("The action associated with thsi tag.")
@doc("The action associated with this tag.")
action: TagAction;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ interface TenantOperations
extends ProxyResourceOperations<TestTenantResource>,
ResourceUpdate<TestTenantResource, TestTenantProperties> {}

@doc("rp-specific proeprties for the resource")
@doc("rp-specific properties for the resource")
model TestTenantProperties {
@doc("The status of the last operation performed on this resource.")
provisioningState: EnvelopeProvisioningState;
Expand Down Expand Up @@ -137,7 +137,7 @@ interface ExtensionOperations
extends ProxyResourceOperations<TestExtensionResource>,
ResourceUpdate<TestExtensionResource, TestExtensionProperties> {}

@doc("rp-specific proeprties for the resource")
@doc("rp-specific properties for the resource")
model TestExtensionProperties {
@doc("The status of the last operation performed on this resource.")
provisioningState: EnvelopeProvisioningState;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ interface Tracked2Operations {
listBySubscription is ArmListBySubscription<TestTrackedResource2>;
}

@doc("rp-specific proeprties for the resource with all envelope properties")
@doc("rp-specific properties for the resource with all envelope properties")
model TestTrackedProperties2 {
@doc("The status of the last operation performed on this resource.")
provisioningState: EnvelopeProvisioningState;
Expand Down Expand Up @@ -86,7 +86,7 @@ interface TenantOperations2 {
listByParent is ArmResourceListByParent<TestTenantResource2>;
}

@doc("rp-specific proeprties for the resource")
@doc("rp-specific properties for the resource")
model TestTenantProperties2 {
@visibility("read")
@doc("The status of the last operation performed on this resource.")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ model LinkerProperties {
...DefaultProvisioningStateProperty;
}

@doc("The kmind of authentication used for this linker.")
@doc("The kind of authentication used for this linker.")
enum AuthType {
@doc("System assigned identity")
systemAssignedIdentity,
Expand Down
Loading

0 comments on commit 6493de9

Please sign in to comment.