Skip to content
Open
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
38 changes: 38 additions & 0 deletions .chronus/changes/upgrade-deps-feb-2026-2026-1-17-10-39-16.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
---
changeKind: dependencies
packages:
- "@typespec/asset-emitter"
- "@typespec/bundler"
- "@typespec/compiler"
- "@typespec/eslint-plugin"
- "@typespec/events"
- "@typespec/html-program-viewer"
- "@typespec/http-canonicalization"
- "@typespec/http-client-js"
- "@typespec/http-client"
- "@typespec/http-server-csharp"
- "@typespec/http-server-js"
- "@typespec/http-specs"
- "@typespec/http"
- "@typespec/internal-build-utils"
- "@typespec/json-schema"
- "@typespec/library-linter"
- "@typespec/mutator-framework"
- "@typespec/openapi"
- "@typespec/openapi3"
- "@typespec/playground"
- "@typespec/protobuf"
- "@typespec/rest"
- "@typespec/spec-api"
- "@typespec/spec-coverage-sdk"
- "@typespec/spector"
- "@typespec/sse"
- "@typespec/streams"
- tmlanguage-generator
- "@typespec/tspd"
- typespec-vscode
- "@typespec/versioning"
- "@typespec/xml"
---

Bump dependencies
9 changes: 9 additions & 0 deletions .chronus/changes/upgrade-deps-feb-2026-2026-1-17-11-28-2.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
changeKind: internal
packages:
- "@typespec/emitter-framework"
- "@typespec/http-client-java"
- "@typespec/http-client-python"
---

fix lint issues
1 change: 1 addition & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,5 +57,6 @@
"typescript.tsdk": "./node_modules/typescript/lib",
"git.ignoreLimitWarning": true,
"vitest.rootConfig": "vitest.config.js",
"eslint.rules.customizations": [{ "rule": "*", "severity": "warn" }],
"typespec.tsp-server.path": "${workspaceFolder}/packages/compiler"
}
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,21 +43,21 @@
"@chronus/chronus": "^1.0.1",
"@chronus/github": "^1.0.1",
"@chronus/github-pr-commenter": "^1.0.1",
"@eslint/js": "^9.39.2",
"@eslint/js": "^10.0.1",
"@microsoft/api-extractor": "^7.55.2",
"@octokit/core": "^7.0.2",
"@octokit/plugin-paginate-graphql": "^6.0.0",
"@octokit/plugin-rest-endpoint-methods": "^17.0.0",
"@types/micromatch": "^4.0.9",
"@types/node": "~25.0.2",
"@types/node": "~25.2.3",
"@vitest/coverage-v8": "^4.0.15",
"@vitest/eslint-plugin": "^1.5.2",
"c8": "^10.1.3",
"cspell": "^9.4.0",
"eslint": "^9.39.2",
"eslint": "^10.0.0",
"eslint-plugin-import": "^2.31.0",
"eslint-plugin-react-hooks": "7.0.1",
"eslint-plugin-unicorn": "^62.0.0",
"eslint-plugin-unicorn": "^63.0.0",
"micromatch": "^4.0.8",
"picocolors": "~1.1.1",
"playwright": "^1.57.0",
Expand All @@ -69,7 +69,7 @@
"syncpack": "^13.0.3",
"tsx": "^4.21.0",
"typescript": "~5.9.2",
"typescript-eslint": "^8.49.0",
"typescript-eslint": "^8.56.0",
"vite-plugin-node-polyfills": "^0.25.0",
"vitest": "^4.0.15",
"yaml": "~2.8.2"
Expand Down
2 changes: 1 addition & 1 deletion packages/asset-emitter/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
"@typespec/compiler": "workspace:^"
},
"devDependencies": {
"@types/node": "~25.0.2",
"@types/node": "~25.2.3",
"@typespec/compiler": "workspace:^",
"@vitest/coverage-v8": "^4.0.15",
"@vitest/ui": "^4.0.15",
Expand Down
2 changes: 1 addition & 1 deletion packages/best-practices/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
"@typespec/compiler": "workspace:^"
},
"devDependencies": {
"@types/node": "~25.0.2",
"@types/node": "~25.2.3",
"@typespec/compiler": "workspace:^",
"@vitest/coverage-v8": "^4.0.15",
"@vitest/ui": "^4.0.15",
Expand Down
4 changes: 2 additions & 2 deletions packages/bundle-uploader/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,15 +38,15 @@
],
"dependencies": {
"@azure/identity": "~4.13.0",
"@azure/storage-blob": "~12.30.0",
"@azure/storage-blob": "~12.31.0",
"@pnpm/workspace.find-packages": "^1000.0.24",
"@typespec/bundler": "workspace:^",
"json5": "^2.2.3",
"picocolors": "~1.1.1",
"semver": "^7.7.1"
},
"devDependencies": {
"@types/node": "~25.0.2",
"@types/node": "~25.2.3",
"@types/semver": "^7.5.8",
"@vitest/coverage-v8": "^4.0.15",
"@vitest/ui": "^4.0.15",
Expand Down
2 changes: 1 addition & 1 deletion packages/bundler/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
"yargs": "~18.0.0"
},
"devDependencies": {
"@types/node": "~25.0.2",
"@types/node": "~25.2.3",
"@types/yargs": "~17.0.33",
"@vitest/coverage-v8": "^4.0.15",
"@vitest/ui": "^4.0.15",
Expand Down
8 changes: 4 additions & 4 deletions packages/compiler/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -105,11 +105,11 @@
"lint:fix": "eslint . --fix"
},
"dependencies": {
"@babel/code-frame": "~7.28.6",
"@babel/code-frame": "~7.29.0",
"@inquirer/prompts": "^8.0.1",
"ajv": "~8.17.1",
"ajv": "~8.18.0",
"change-case": "~5.4.4",
"env-paths": "^3.0.0",
"env-paths": "^4.0.0",
"globby": "~16.1.0",
"is-unicode-supported": "^2.1.0",
"mustache": "~4.2.0",
Expand All @@ -126,7 +126,7 @@
"devDependencies": {
"@types/babel__code-frame": "~7.27.0",
"@types/mustache": "~4.2.5",
"@types/node": "~25.0.2",
"@types/node": "~25.2.3",
"@types/semver": "^7.5.8",
"@types/yargs": "~17.0.33",
"@typespec/internal-build-utils": "workspace:^",
Expand Down
4 changes: 2 additions & 2 deletions packages/compiler/src/core/scanner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1274,6 +1274,7 @@ export function createScanner(
if (isCrlf(end - 2, 0, end)) {
end--;
}
// eslint-disable-next-line no-useless-assignment
end--;
}

Expand Down Expand Up @@ -1473,7 +1474,6 @@ export function createScanner(

function scanIdentifierOrKeyword(): Token {
let count = 0;
let ch = input.charCodeAt(position);

while (true) {
position++;
Expand All @@ -1483,7 +1483,7 @@ export function createScanner(
break;
}

ch = input.charCodeAt(position);
const ch = input.charCodeAt(position);
if (count < KeywordLimit.MaxLength && isLowercaseAsciiLetter(ch)) {
continue;
}
Expand Down
6 changes: 3 additions & 3 deletions packages/compiler/src/experimental/mutators.ts
Original file line number Diff line number Diff line change
Expand Up @@ -421,11 +421,11 @@ function createMutatorEngine(
continue;
}

let mutationFn: MutatorFn<T> | null = null;
let mutationFn: MutatorFn<T> | null;
let replaceFn: MutatorReplaceFn<T> | null = null;

let mutate = false;
let recurse = false;
let mutate;
let recurse;

if (typeof record === "function") {
mutationFn = record;
Expand Down
2 changes: 1 addition & 1 deletion packages/compiler/src/server/server-compile-manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ export class ServerCompileManager {
compileOptions: CompilerOptions = {},
serverCompileOptions: ServerCompileOptions,
): Promise<CompileTracker> {
let cache = undefined;
let cache;
const curId = this.compileId++;
const err = new Error();
const lines = err.stack?.split("\n") ?? [];
Expand Down
1 change: 1 addition & 0 deletions packages/compiler/src/utils/fs-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ export async function mkTempDir(host: CompilerHost, base: string, prefix: string
if ((error as any).code === `EACCES`) {
throw new Error(
`Cannot create temporary folder at ${path}. Permission denied. Please check your permissions.`,
{ cause: error },
);
} else {
throw error;
Expand Down
2 changes: 2 additions & 0 deletions packages/compiler/test/checker/references.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -570,6 +570,8 @@ describe("compiler: references", () => {
}));

describe("reference sibling members", () => {
// Those tests look broken https://github.com/microsoft/typespec/issues/9731
// eslint-disable-next-line no-unassigned-vars
let linkedValue: Operation | undefined;
beforeEach(() => {
testHost.addJsFile("./test-link.js", {
Expand Down
2 changes: 2 additions & 0 deletions packages/compiler/test/config/config.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,7 @@ describe("compiler: config file loading", () => {
});

it("deep clones defaults when not found", async () => {
// eslint-disable-next-line no-useless-assignment
let config = await loadTestConfig("empty", false, false);
config = await loadTestConfig("empty", false, false);
deepStrictEqual(config, {
Expand All @@ -121,6 +122,7 @@ describe("compiler: config file loading", () => {
});

it("deep clones defaults when found", async () => {
// eslint-disable-next-line no-useless-assignment
let config = await loadTestConfig("simple", false, false);

config = await loadTestConfig("simple");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ export function TypeExpression(props: TypeExpressionProps) {
case "Operation": {
// Render function types as typing.Callable[[ArgTypes...], ReturnType]
// If parameters cannot be enumerated, fall back to Callable[..., ReturnType]
let paramTypes: Type[] | null = null;
let paramTypes: Type[] | null;
const op: any = type as any;
if (op.parameters) {
try {
Expand Down Expand Up @@ -276,18 +276,19 @@ const pythonTypeToImport = new Map<string, any>([
function getScalarIntrinsicExpression($: Typekit, type: Scalar | IntrinsicType): string | null {
let intrinsicName: string;
if ($.scalar.is(type)) {
if ($.scalar.isUtcDateTime(type) || $.scalar.extendsUtcDateTime(type)) {
const encoding = $.scalar.getEncoding(type);
intrinsicName = "utcDateTime";
switch (encoding?.encoding) {
case "unixTimestamp":
case "rfc7231":
case "rfc3339":
default:
intrinsicName = `utcDateTime`;
break;
}
}
// This was always is overridden below?
// if ($.scalar.isUtcDateTime(type) || $.scalar.extendsUtcDateTime(type)) {
// const encoding = $.scalar.getEncoding(type);
// intrinsicName = "utcDateTime";
// switch (encoding?.encoding) {
// case "unixTimestamp":
// case "rfc7231":
// case "rfc3339":
// default:
// intrinsicName = `utcDateTime`;
// break;
// }
// }
intrinsicName = $.scalar.getStdBase(type)?.name ?? "";
} else {
intrinsicName = type.name;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ function getScalarIntrinsicExpression($: Typekit, type: Scalar | IntrinsicType):
if ($.scalar.is(type)) {
if ($.scalar.isUtcDateTime(type) || $.scalar.extendsUtcDateTime(type)) {
const encoding = $.scalar.getEncoding(type);
let emittedType = "Date";
let emittedType;
switch (encoding?.encoding) {
case "unixTimestamp":
case "rfc7231":
Expand Down
6 changes: 3 additions & 3 deletions packages/eslint-plugin-typespec/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,17 +37,17 @@
"!dist/test/**"
],
"peerDependencies": {
"eslint": "^9.39.2"
"eslint": "^10.0.0"
},
"devDependencies": {
"@types/node": "~25.0.2",
"@types/node": "~25.2.3",
"@typescript-eslint/parser": "^8.49.0",
"@typescript-eslint/rule-tester": "^8.49.0",
"@typescript-eslint/types": "^8.49.0",
"@vitest/coverage-v8": "^4.0.15",
"@vitest/ui": "^4.0.15",
"c8": "^10.1.3",
"eslint": "^9.39.2",
"eslint": "^10.0.0",
"rimraf": "~6.1.2",
"typescript": "~5.9.2",
"vitest": "^4.0.15"
Expand Down
2 changes: 1 addition & 1 deletion packages/events/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
"@typespec/compiler": "workspace:^"
},
"devDependencies": {
"@types/node": "~25.0.2",
"@types/node": "~25.2.3",
"@typespec/compiler": "workspace:^",
"@typespec/library-linter": "workspace:^",
"@typespec/tspd": "workspace:^",
Expand Down
4 changes: 2 additions & 2 deletions packages/html-program-viewer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
"@typespec/compiler": "workspace:^"
},
"dependencies": {
"@fluentui/react-components": "~9.72.3",
"@fluentui/react-components": "~9.73.0",
"@fluentui/react-icons": "^2.0.292",
"@fluentui/react-list": "^9.1.2",
"react": "~19.2.3",
Expand All @@ -63,7 +63,7 @@
"@testing-library/dom": "^10.4.0",
"@testing-library/jest-dom": "^6.6.3",
"@testing-library/react": "^16.2.0",
"@types/node": "~25.0.2",
"@types/node": "~25.2.3",
"@types/react": "~19.2.7",
"@types/react-dom": "~19.2.2",
"@typespec/compiler": "workspace:^",
Expand Down
2 changes: 1 addition & 1 deletion packages/http-canonicalization/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
"@typespec/http": "workspace:^"
},
"devDependencies": {
"@types/node": "~25.0.2",
"@types/node": "~25.2.3",
"concurrently": "^9.1.2",
"prettier": "~3.8.0"
}
Expand Down
2 changes: 1 addition & 1 deletion packages/http-client-csharp/emitter/src/emitter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ export async function $onEmit(context: EmitContext<CSharpEmitterOptions>) {
} catch (error: any) {
const isValid = await _validateDotNetSdk(sdkContext, _minSupportedDotNetSdkVersion);
// if the dotnet sdk is valid, the error is not dependency issue, log it as normal
if (isValid) throw new Error(error);
if (isValid) throw new Error(error, { cause: error });
}
if (!options["save-inputs"]) {
// delete
Expand Down
6 changes: 3 additions & 3 deletions packages/http-client-java/emitter/src/code-model-builder.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1879,6 +1879,8 @@ export class CodeModelBuilder {

// group schema

// TODO: double check this suppression
// eslint-disable-next-line no-useless-assignment
let coreNamespace = this.namespace;
if (this.isAzureV1()) {
coreNamespace = "com.azure.core.http";
Expand Down Expand Up @@ -2201,10 +2203,8 @@ export class CodeModelBuilder {
// TODO: what to do if more than 1 response?
// It happens when the response type is Union, on one status code.
// let response: Response;
let headers: Array<HttpHeader> | undefined = undefined;
const headers: Array<HttpHeader> = [];

// headers
headers = [];
if (sdkResponse.headers) {
for (const header of sdkResponse.headers) {
const schema = this.processSchema(header.type, header.name);
Expand Down
2 changes: 1 addition & 1 deletion packages/http-client-js/eng/scripts/emit-e2e.js
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ async function processFile(file, options) {
console.log(pc.yellow(`Skipping: ${relativePath}`));
} else if (action === "abort") {
console.log(pc.red("Aborting processing."));
throw new Error("Processing aborted by user");
throw new Error("Processing aborted by user", { cause: error });
}
}
return { status: "failed", relativePath, errorDetails };
Expand Down
2 changes: 1 addition & 1 deletion packages/http-client-js/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
"@typespec/http": "workspace:^",
"@typespec/http-specs": "workspace:^",
"@typespec/spector": "workspace:^",
"@typespec/ts-http-runtime": "0.3.2",
"@typespec/ts-http-runtime": "0.3.3",
"@typespec/tspd": "workspace:^",
"@typespec/versioning": "workspace:^",
"@vitest/ui": "^4.0.15",
Expand Down
Loading
Loading