mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-06 05:50:43 +00:00
chore(lint): enable low-noise rules
This commit is contained in:
@@ -20,12 +20,12 @@
|
||||
"typescript/consistent-return": "error",
|
||||
"typescript/no-explicit-any": "error",
|
||||
"typescript/no-extraneous-class": "error",
|
||||
"typescript/no-meaningless-void-operator": "off",
|
||||
"typescript/no-unnecessary-type-assertion": "off",
|
||||
"typescript/no-meaningless-void-operator": "error",
|
||||
"typescript/no-unnecessary-type-assertion": "error",
|
||||
"typescript/no-unnecessary-type-conversion": "error",
|
||||
"typescript/no-unnecessary-type-parameters": "off",
|
||||
"typescript/no-unsafe-type-assertion": "off",
|
||||
"typescript/no-useless-default-assignment": "off",
|
||||
"typescript/no-useless-default-assignment": "error",
|
||||
"unicorn/consistent-function-scoping": "off",
|
||||
"unicorn/prefer-set-size": "error",
|
||||
"unicorn/require-post-message-target-origin": "error"
|
||||
|
||||
@@ -254,7 +254,7 @@ async function resolveDiscordModelPickerRouteState(params: {
|
||||
client: interaction.client,
|
||||
threadChannel: {
|
||||
id: rawChannelId,
|
||||
name: "name" in channel ? (channel.name as string | undefined) : undefined,
|
||||
name: "name" in channel ? channel.name : undefined,
|
||||
parentId: "parentId" in channel ? (channel.parentId ?? undefined) : undefined,
|
||||
parent: undefined,
|
||||
},
|
||||
|
||||
@@ -1733,7 +1733,7 @@ export async function runEmbeddedPiAgent(
|
||||
source: "planning_only_retry",
|
||||
},
|
||||
});
|
||||
void params.onAgentEvent?.({
|
||||
params.onAgentEvent?.({
|
||||
stream: "plan",
|
||||
data: {
|
||||
phase: "update",
|
||||
|
||||
@@ -493,7 +493,7 @@ describe("callGateway url resolution", () => {
|
||||
},
|
||||
start() {
|
||||
sawYieldBeforeStart = preConnectYieldRan;
|
||||
void opts.onHelloOk?.({
|
||||
opts.onHelloOk?.({
|
||||
features: {
|
||||
methods: helloMethods ?? [],
|
||||
events: [],
|
||||
|
||||
@@ -96,7 +96,7 @@ beforeEach(() => {
|
||||
|
||||
async function invokeUpdateRun(
|
||||
params: Record<string, unknown>,
|
||||
respond: ((ok: boolean, response?: unknown) => void) | undefined = undefined,
|
||||
respond?: (ok: boolean, response?: unknown) => void,
|
||||
) {
|
||||
const { updateHandlers } = await import("./update.js");
|
||||
const onRespond = respond ?? (() => {});
|
||||
|
||||
@@ -731,10 +731,7 @@ describe("listSessionsFromStore selected model display", () => {
|
||||
});
|
||||
|
||||
describe("resolveSessionModelIdentityRef", () => {
|
||||
const resolveLegacyIdentityRef = (
|
||||
cfg: OpenClawConfig,
|
||||
modelProvider: string | undefined = undefined,
|
||||
) =>
|
||||
const resolveLegacyIdentityRef = (cfg: OpenClawConfig, modelProvider?: string) =>
|
||||
resolveSessionModelIdentityRef(cfg, {
|
||||
sessionId: "legacy-session",
|
||||
updatedAt: Date.now(),
|
||||
|
||||
Reference in New Issue
Block a user