mirror of
https://github.com/renovatebot/renovate.git
synced 2026-10-30 17:27:26 +00:00
183ee9caac
The manager emitted `logger.warn` four times during extraction and returned `null` for content that is valid but not updatable. A `rust-toolchain.toml` using `path` instead of `channel` is a legitimate file, yet it failed schema validation and produced a maintainer-facing warning. Per the logging guidance in `docs/development/best-practices.md`, WARN is consumed by metrics and error catching services, so it should not fire for user content Renovate simply cannot update. The manager guide also asks for a `skipReason` rather than silently dropping a dependency. The schema now accepts an optional `channel` and an optional `path`, and extraction reports: - `invalid-version` when a channel cannot be parsed - `path-dependency` when the file points at a local toolchain - `unspecified-version` when neither field is set `channel` takes precedence when both are present, since rustup rejects that combination and `channel` is the actionable field. Files that are not toolchain files at all still return `null`: TOML that does not parse, TOML without a `[toolchain]` table, and legacy plain text files that are empty or hold more than one line. The file pattern matches any file named `rust-toolchain`, so these are treated as false matches. All remaining logs are DEBUG.
14 lines
318 B
TypeScript
14 lines
318 B
TypeScript
import { z } from 'zod/v4';
|
|
import { Toml } from '../../../util/schema-utils/index.ts';
|
|
|
|
export const RustToolchain = Toml.pipe(
|
|
z.object({
|
|
toolchain: z.object({
|
|
channel: z.string().optional(),
|
|
path: z.string().optional(),
|
|
}),
|
|
}),
|
|
);
|
|
|
|
export type RustToolchain = z.infer<typeof RustToolchain>;
|