@alint-js/config 0.0.24 → 0.0.27

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -1,5 +1,4 @@
1
1
  import { AlintConfig, AlintConfig as AlintConfig$1, AlintConfigItem, ModelSize, PluginDefinition, ProviderDefinition, ProviderType, RunnerConfig, RunnerStatsConfig, SetupConfig, SetupConfig as SetupConfig$1, SetupModelDefinition } from "@alint-js/core";
2
-
3
2
  //#region src/plugins/spec.d.ts
4
3
  interface DirectoryPluginSpecifier {
5
4
  directory: string;
package/dist/index.mjs CHANGED
@@ -251,7 +251,8 @@ function createBasicStructuredRule(rule) {
251
251
  metering: ctx.metering,
252
252
  model,
253
253
  operation: `declarative-${rule.name}-structured`,
254
- schema: declarativeFindingResponseSchema
254
+ schema: declarativeFindingResponseSchema,
255
+ signal: ctx.signal
255
256
  });
256
257
  reportDeclarativeFindings({
257
258
  ctx,
@@ -1139,14 +1140,15 @@ async function loadAlintConfig(cwd, configFile) {
1139
1140
  } });
1140
1141
  }
1141
1142
  async function loadStaticConfig(cwd, configFile) {
1143
+ const jiti = createJiti(resolve(cwd, configFile ?? "alint.config"), {
1144
+ interopDefault: true,
1145
+ moduleCache: false
1146
+ });
1142
1147
  const result = await loadConfig({
1143
1148
  configFile,
1144
1149
  cwd,
1145
1150
  dotenv: true,
1146
- jiti: createJiti(resolve(cwd, configFile ?? "alint.config"), {
1147
- interopDefault: true,
1148
- moduleCache: false
1149
- }),
1151
+ import: (id) => jiti.import(id),
1150
1152
  name: "alint"
1151
1153
  });
1152
1154
  if (result._configFile === void 0) return parseStaticConfig(void 0);
@@ -1321,6 +1323,7 @@ function parseProvider(provider) {
1321
1323
  }
1322
1324
  function parseRunner(runner) {
1323
1325
  const parsedRunner = {};
1326
+ if (runner.agent_retries !== void 0) parsedRunner.agentRetries = readFiniteNumber(runner.agent_retries, "runner agent_retries");
1324
1327
  if (runner.cache !== void 0) parsedRunner.cache = parseRunnerCache(runner.cache);
1325
1328
  if (runner.file_concurrency !== void 0) parsedRunner.fileConcurrency = parsePositiveInteger(runner.file_concurrency, "runner file_concurrency");
1326
1329
  if (runner.rule_concurrency !== void 0) parsedRunner.ruleConcurrency = parsePositiveInteger(runner.rule_concurrency, "runner rule_concurrency");
@@ -1401,6 +1404,7 @@ function toTomlProvider(provider) {
1401
1404
  }
1402
1405
  function toTomlRunner(runner) {
1403
1406
  return {
1407
+ agent_retries: runner.agentRetries,
1404
1408
  cache: toTomlRunnerCache(runner.cache),
1405
1409
  file_concurrency: runner.fileConcurrency,
1406
1410
  rule_concurrency: runner.ruleConcurrency,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@alint-js/config",
3
3
  "type": "module",
4
- "version": "0.0.24",
4
+ "version": "0.0.27",
5
5
  "exports": {
6
6
  ".": {
7
7
  "types": "./dist/index.d.mts",
@@ -16,7 +16,7 @@
16
16
  "@moeru/std": "^0.1.0-beta.18",
17
17
  "@package-json/types": "^0.0.13",
18
18
  "apeira": "^0.0.7",
19
- "c12": "^3.3.4",
19
+ "c12": "^4.0.0-beta.5",
20
20
  "es-toolkit": "^1.49.0",
21
21
  "jiti": "^2.7.0",
22
22
  "minimatch": "^10.2.5",
@@ -25,10 +25,10 @@
25
25
  "resolve.exports": "2.0.3",
26
26
  "smol-toml": "^1.7.0",
27
27
  "tar-stream": "^3.2.0",
28
- "valibot": "^1.4.1",
28
+ "valibot": "^1.4.2",
29
29
  "xdg-basedir": "^5.1.0",
30
- "@alint-js/core": "0.0.24",
31
- "@alint-js/tools-fs": "0.0.24"
30
+ "@alint-js/core": "0.0.27",
31
+ "@alint-js/tools-fs": "0.0.27"
32
32
  },
33
33
  "devDependencies": {
34
34
  "@types/tar-stream": "^3.1.4",