Repository navigation
chore(deps): update dependency fallow to v3.46.0 - #1006
Merged
Merged
Conversation
|
Important Review skippedBot user detected. To trigger a single review, invoke the
|
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
commit: |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #1006 +/- ##
=======================================
Coverage 95.07% 95.07%
=======================================
Files 10 10
Lines 751 751
Branches 235 235
=======================================
Hits 714 714
Misses 34 34
Partials 3 3 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Note
This PR body was truncated due to platform limits.
This PR contains the following updates:
3.45.0→3.46.0Release Notes
fallow-rs/fallow (fallow)
v3.46.0Compare Source
Added
A
deprecatedfield for deprecated commands and options.fallow schemaandfallow schema --cli-referencegive each deprecated command and option adeprecatedobject with thereplacement. The field is absent on a current command or option.A CodeRabbit plugin and a GNOME Shell extension plugin. The
coderabbitplugin keeps.coderabbit.config.tsin use when the project depends on@coderabbitai/config. Thegnome-shell-extensionplugin makesextension.jsandprefs.jsentry points in each folder whosemetadata.jsonhas theuuidandshell-versionkeys that GNOME Shell requires. Ametadata.jsonof another tool seeds nothing.(Refs #4912)
Unused exports in generated files and in shadcn/ui folders now name the config entry that hides them. Fallow keeps these findings in the report. In the human report, the "Unused exports" section prints one hint for each group of 3 findings or more, with the
ignoreExportsentry to add: one pattern for the generated files, and one for each shadcn/ui folder that acomponents.jsonnames. In JSON, each such finding has anadd-to-configaction with theignoreExportsrule. An unused export or unused type in a generated file hasauto_fixable: falseon itsremove-exportaction and nosuppress-lineaction, because the generator writes the file again and removes the edit or the comment.(Refs #4912)
fallow schematells source edits apart from report writes. Eachmcp_toolsrow and eachfallow://toolsrow has a newmodifies_sourcefield. It istrueonly forfix_apply, which edits source files.analyze,check_changed,find_dupesandcheck_healthkeepread_only: false, because they write a report or baseline file on request, and they havemodifies_source: false. Theread_onlyfield and the MCPreadOnlyHintannotation do not change.(Refs #4845)
fallow explainshows a tested code example for each rule. Next to the sentence that describes the example,fallow explain <id>now prints the files of a small project that makes the rule report a finding. A rule offallow auditshows the files before the change and after it.--format jsonhas the files in two new arrays,example_filesandexample_base_files, each with apathand thecodeof the file;fallow schema --cli-referencehas the same arrays for each issue type. A test runs fallow on each example and checks that the rule reports it. A rule has no example when it needs data that a small project does not have, such as production runtime data or a test run.(Closes #4932)
A
fallow-override-threshold-next-linecomment sets the health ceilings of one function. Write// fallow-override-threshold-next-line maxCognitive=40 maxCrap=45 -- <reason>on the line before the function. The keys are the keys ofhealth.thresholdOverrides(maxCyclomatic,maxCognitive,maxCrap,maxUnitSize), and the reason is required. For each ceiling that it sets, the comment wins over a config entry. The comment keeps the function visible with a numeric ceiling, so the exception lives next to the code and the root config stays small in a monorepo. The health report lists each comment in the new optionalinline_threshold_overridesarray with the states ofthreshold_overrides:active,stale,insufficientandno_match. A comment with a problem, for example a missing reason, has no effect and goes to the new optionalinline_threshold_override_problemsarray. A finding that a comment ceiling applies to carriesoverride_comment_line, and the human report showsoverride (comment, line N)oroverride (config). The new config keyhealth.inlineThresholdOverrides(defaulttrue) turns the comment form off.fallow auditreports a new comment through theadded-suppressiondiff-risk rule. The extraction cache version moves, so the first run after the upgrade parses every file again. Thanks to @DiefBell for the request.(Closes #4898)
Thanks @DiefBell for the request.
Changed
Rust crates:
ConfigLoadOptionsandConfigFileOptionscarry the time limit of a remoteextendsfetch. Both types are#[non_exhaustive]. Build them withfallow_config::ConfigLoadOptions::new(allow_remote_extends)(withwith_extends_timeout) andfallow_engine::project_config::ConfigFileOptions::new(allow_remote_extends, &env), which readsFALLOW_EXTENDS_TIMEOUT_SECSfrom anEnvSnapshot. The fetcher reads the option, not the process environment. New:fallow_config::extends_timeout_from_env_valueandEnvSnapshot::extends_timeout. The value ofFALLOW_EXTENDS_TIMEOUT_SECShas the same effect on each command as before. The error for a refused remoteextendsentry now namesConfigLoadOptions::new(true)for library callers.Rust crates: the
ResolvedConfigmutators that the resolver applies are hidden from the docs.force_include_entry_exports,apply_package_baselines_env,override_cache_dirandscope_shared_cache_dir_to_rootstay callable and are#[doc(hidden)].A config with
minimumVersion3.34.0 or higher no longer gets the single-segment glob warning. Since 3.34.0, a single*or?in a config path glob matches in one folder level only. For a glob that matches fewer files than before, fallow prints a warning on stderr on each run. A config that is written for the new rule had no way to stop this warning. Now"minimumVersion": "3.34.0"or higher tells fallow that the config is written for the new rule, and fallow prints no warning for the globs of that config. The globs of plugins and rule packs keep the warning. The warning text now names this setting. (Closes #4851)The built-in ignore list now has the root
fallow-viz.html.fallow vizwrites its map tofallow-viz.htmlin the project root. Discovery parsed that file as an HTML source file on the next run, and the next map showed the map itself. A file of this name in the project root is now not analyzed. Add"!fallow-viz.html"toignorePatternsto analyze it again. The rule does not apply to a file of this name in a subfolder.(Refs #4845)
A dead-code report with findings that are all warnings says why the exit code stays 0. The human report prints one line under the status line of the dead-code findings: "Warnings do not change the exit code. Set a rule to
errorto fail on it." The line shows in the default,--summaryand--group-byreports, and in the dead-code part offallow auditand of a barefallowrun. The machine formats and--quietruns do not change.(Refs #4905)
An entry point from a CI file now names that CI file as its source.
fallow list --entry-pointsprintedtools/release.ts (scripts)for a file that.github/workflows/ci.ymlruns. It now printstools/release.ts (.github/workflows/ci.yml). The value of thesourcefield inlist --entry-points --format jsonchanges fromscriptsto the CI file path for these entry points. A script that matchessource == "scripts"must also accept a CI file path. The label is the project-root-relative path of the CI file:.gitlab-ci.yml, a.github/workflows/file, or theaction.ymlof a composite action. When more CI files run one file, the label is the first CI file in this order:.gitlab-ci.yml, then the workflow files by name, then the composite actions. Entry points frompackage.jsonscripts keep their label.(Refs #4845)
fallow fix --format jsonhas new skip reasons for catalog records. Itno longer emits
skip_reason: "line_out_of_range". It emitsnot_found,not_empty,unsupported_yaml_styleandunsafe_edit. An edit that wouldchange other parts of
pnpm-workspace.yamlis now a skip withunsafe_edit, not a write error with exit code 2.The docs link of each issue type opens its rule page.
fallow explain,the
_meta.rulesdocs of--explain, the SARIFhelpUri, the LSP codedescription, the MCP
fallow://issue-typesresource,fallow schema, thesection footers of the human report and the rows of the GitHub summary now
link to
https://fallow.tools/docs/rules/<id>/. The rule page has thefacts of the rule, an example, the fix and the suppression comment. The
old headings on the explanation pages stay, so the links of older versions
still work.
(Closes #4894)
fallow fix --dry-runreports an unused exported enum with only unused members one time. Before, the preview listed tworemove_exportrecords for such an enum: one for the unused export and one for its members. The apply run removes the enum one time, so the preview now shows one record.fallow fixremoves theexportkeyword of a declaration only in a file that parses without an error. A file with a syntax error, an MDX file and a Glimmer file keep the keyword, and the finding stays in the report. Export lists such asexport { a, b }are not affected.The editor quick fix "Remove unused export" is not offered in a document with a syntax error. The quick fix reads the declarations from the parsed document text. The finding stays in the report.
The editor quick fix "Remove unused export" is offered for the second declaration on a line. For
export function live() {} export function dead() {}withdeadunused, the quick fix removes theexportofdead. Before, it offered no quick fix.fallow fixremoves an enum member only in a file that parses without an error. The fix reads the members from the syntax tree. In a file with a syntax error the finding stays in the report.Deprecated
fallow dead-codeoptions for the architecture issue types print a warning.--circular-deps,--re-export-cycles,--package-cycles,--boundary-violationsand--policy-violationsprint one stderr warning each, with thefallow architectureoption to use.--quietremoves the warning. The next major version removes these options.Removed
testingfeature of their crate:fallow_engine::session::AnalysisSession::{load, load_with_config, load_with_config_options, load_default, load_default_with_config, from_config},fallow_engine::project_config::{config_for_project, config_for_project_with_load_options, config_for_project_with_production, ProjectConfig}andfallow_api::EditorAnalysisSession::{load, load_with_config, load_with_config_options, load_with_production, load_default, load_default_with_config}.fallow_engine::project_config::{config_for_project_analysis, config_for_project_readiness, ProjectConfigOptions, ProjectConfigReadiness}are removed: they had no caller outside the tests of the engine. Open a session from a resolved run:fallow_api::run::resolve_run, thenRunnable::open_sessionorEditorAnalysisSession::open.fallow_config::cache_dir_env_overrideandProductionEnv::from_processare removed. ReadFALLOW_CACHE_DIRwithEnvSnapshot::cache_dirand the production variables withProductionEnv::from_lookup.Fixed
A
>in a brace attribute of a Svelte markup<script>element no longer breaks the parse. Svelte markup can hold a<script>element with an attribute expression such asonload={() => {}}ordata-big={2 > 1}. Fallow ended the opening tag at the first>, read the rest of the expression as a script body, and reported the file assource-parse-degraded. That diagnostic then gave every finding of the run theincomplete-import-graphcaveat. The script tag scan now skips brace expressions, also when they nest or hold quoted strings.(Closes #4828)
fallow auditno longer reports an old unused export behind a SvelteKit path alias as introduced. The base snapshot offallow auditdid not have the gitignored.svelte-kit/tsconfig.json, which holds the path aliases of a SvelteKit app. On the base, a file that the app imports only through such an alias was an unused file, so its unused exports looked introduced in the head. The base snapshot now gets a copy of.svelte-kit/tsconfig.jsonfor the root and for each workspace package. It also links thenode_modulesof each workspace package that the base has, because pnpm installs the dependencies of a workspace package there and not in the rootnode_modules.(Closes #4790)
The GitLab template now works with a fallow version range or
latestwhenFALLOW_COMMENT,FALLOW_REVIEWorFALLOW_MUTATIONis on.npm install -D fallowwrites a^range topackage.json, and the job stopped with exit code 2. The template now reads the exact version of the installed fallow and downloads the merge request scripts of that release. When the template cannot read the installed version, the error names the three fixes: an exact version inpackage.json, an exactFALLOW_VERSION, or a vendored template.(Closes #4841)
An expired or invalid license no longer blocks a single local runtime coverage capture. A single local capture needs no license, but
--runtime-coveragestopped with exit code 3 when the license file was expired or invalid. Fallow now prints the license problem as a warning and runs the analysis without the license. A run with more than one capture still needs a valid license and still exits 3.(Closes #4843)
A function without V8 tracking no longer gets the
safe_to_deleteverdict. The verdict needs V8 tracking. Whenevidence.v8_trackingisuntracked, the local runtime coverage report now givesreview_requiredwith thereview-runtimeaction.(Closes #4843)
publicPackagesno longer hides dead code that the public surface of a package cannot reach. Fallow keeps the entry points of a public package and each declaration that they export or re-export as used. A class or an enum on that surface keeps all of its members. Fallow now reports the other unused exports, types, class members and enum members in the package. Before, fallow removed every such finding in a public package. Unused-file findings do not change.(Closes #4849)
A bare
fallow --format badgerun prints one error and exits with code 2. The run stops before the analysis when it includes the dead-code or the duplication analysis, because only the health analysis renders a badge. A health-only badge run without--scorealso stops with one error and exit code 2. Before, each analysis printed the same error and the run exited with code 1.fallow --only health --score --format badgestill renders the badge.(Refs #4845)
Small CLI output defects.
fallow trace --pathwith no route prints "No import path." once.fallow config-schema,plugin-schemaandrule-pack-schemaexit cleanly when the reader closes the pipe, for example| head. The--filewarning offallow dead-codenames the path that is missing.--quiethides the "boundary zone matched 0 files" and "Cache was built under different extraction config" warnings.fallow fixwalks the files of each fix type in path order, so--dry-runlines and JSON fix entries have a stable order. The human section of test-only production dependencies has a description and a docs link.(Refs #4845)
The output schema and the issue registry describe the JSON that the
commands print.
docs/output-schema.jsonchanges:CheckOutput,DupesOutput,HealthOutput,AuditOutputandFeatureFlagsOutput, has an optionalkindproperty with the value of its command. An envelope nested inanother envelope has no
kind.feature-flagsbranch text namesfeature_flagsandtotal_flags.HealthOutput.health_scoreandfile_scoressay that a plainfallow healthrun prints them.Metaand the_metafield texts say that a--format jsonrunalways sets
telemetry.analysis_run_id.BoundaryViolation.import_specifiersays that the field holds theresolved project-root-relative path.
fallow schemachanges:unused-catalog-entryis suppressible, with the YAML comment# fallow-ignore-next-line unused-catalog-entry.fallow architecturealso reports them.The
fallow explain constant-parametertext says that the rule reportseach option key of an object-pattern parameter. The JSON output of the
commands does not change.
(Closes #4846)
The Git pre-commit hook that
fallow init --hooksandfallow hooks install --target gitwrite, and the Lefthook and existing-hook hints, print the version floor message on one line. The npm launcher of fallow prints averified:line after the version line. The resolver of the hook read both lines as the version, so the message that blocks a fallow below 3.43.0 broke over two lines. The resolver now reads the version from the first line only, as the commit gate script does.fallow dead-code --performancenow puts the config load and the workspace discovery in theconfigspan. The config load ran before theconfigspan started, soconfig_msshowed almost no time and the load counted as unmeasured time. The span tree also putworkspacesunderanalysis, but the config load discovers the workspaces before the analysis starts.workspacesis now a child ofconfig, and the other stages always fit inside theanalysisspan.fallow auditno longer passes silently in a shallow clone without a base.A CI checkout with
fetch-depth: 1has only the HEAD commit, so theauto-detected base is HEAD and the audit compares HEAD with itself. The
audit now prints a warning on stderr, also under
--quiet. The warningnames the two fixes:
fetch-depth: 0or--base <ref>. The JSON outputreports
gate_outcomes["audit-verdict"].statusasskipped, so a CIintegration shows that the run checked nothing. The exit code stays 0. An
explicit
--baseorFALLOW_AUDIT_BASEkeeps the old behavior.(Closes #4839)
The summary lines of the human output now agree with the result of the run.
The
Failed:line of a barefallowrun names only the analyses whose gatefails the run. Clone groups below the duplication threshold and health
findings that a baseline accepts no longer appear on it. The health status
line counts only the functions that the baseline does not accept, and names
the accepted functions, for example
✓ 0 above threshold (3 in the baseline).fallow health --cssadds the count of styling findings to the status line.fallow auditends withNo introduced issueswhen the gate leaves outinherited findings. The health score tip names
duplicates.ignore, the keythat removes files from the duplication analysis.
(Closes #4837)
fallow dead-codeno longer reports a CSS Modules file as unused when another CSS Modules file composes from it. Acomposes: base rounded from "./shared.module.css"declaration now adds an import edge toshared.module.css, andbaseandroundedcount as used classes of that file.composes: name from globalandcomposeswithoutfromadd no edge. The extraction cache version changes, so the first run after the update parses CSS files again.(Closes #4844)
fallow dead-codeno longer reports a type that a held binding gives to the inferred type of a used export. Inconst entryBox: Box<Entry> = ...; export const status = { latency: entryBox };, the inferred type ofstatuscontainsBox<Entry>. A declaration file of a module that holdsstatus.latencymust importBoxandEntry, so the two types are not unused whilestatushas a use. Fallow follows object property values, array elements, conditional and logical branches,satisfiesandas const. It does not follow a member read, a call, or a spread. The extraction cache version changes.(Refs #4850)
The description of
ignoreDependenciesstates how*matches. Thetext said that a glob uses the
ignorePatternssyntax, where*stops at/. In a dependency glob,*also matches/, so@acme*covers eachpackage in the
@acmescope.The description of
codeownersnames--group-by. The key also setsthe CODEOWNERS file for
--group-by ownerand--group-by section, notonly for
fallow health --hotspots --ownership.The description of
effect.schemaExportsAsTypesnamesHttpApiSchema.A
pipeargument can also be a call of anHttpApiSchematransform, suchas
HttpApiSchema.status(201).The VS Code extension no longer fills a view with a result that the user no longer wants. A Health, Security Candidates or Runtime Coverage run that ended after the user disabled the feature, ran Clear Coverage or started a newer run filled the view again. The extension now drops such a result.
The VS Code Health and Security Candidates views load again when an input of their run changes. A loaded Health view kept the data of the old settings after a change of
fallow.production,fallow.configPath,fallow.changedSince,fallow.workspaceorfallow.allowRemoteExtends, and after a change in the workspace picker. The Health view now runs again. A visible Security Candidates view scans again, and a hidden one scans again when the user opens it.--sarif-filenow exits 2 on a command that writes no SARIF file. Only barefallow,fallow dead-code,fallow architectureandfallow securitywrite the file. Before,fallow audit --sarif-file out.sarifand other commands accepted the flag, exited 0 and wrote nothing. Now the command prints one error line and exits 2. To get SARIF fromfallow audit, use--format sarifwith--output-file.(Refs #4845)
The GitHub Action and the GitLab template now add the workspace name to the sticky comment marker. With
workspace: appand nocomment-id(orFALLOW_COMMENT_ID), the marker is nowfallow-results-app, as the input descriptions state. Before, the scripts always passedfallow-results, so parallel jobs for different workspaces edited the same comment. Upgrade note: a job that sets a workspace and no comment id gets a new marker. The first run after the upgrade posts a new comment and leaves the old comment in place. Delete the old comment, or setcomment-id: fallow-resultsto keep it.(Refs #4845)
fallow dead-codeno longer reports the class members of a local that a computed key reads when a sibling function has a local of the same name. Two functions in one file can each declare a local with the same name that holds another class, for exampleconst view = new A()andconst view = new B(). A computed call such asview[key as keyof A]()is a use of the whole object, so each member of the class is used. Fallow now credits the class that the local holds at the read, and no longer reports each member of both classes as unused.(Closes #4824)
fallow dead-codeno longer reports a manual mock and its module as duplicate exports. A manual mock at<dir>/__mocks__/<file>repeats the exports of the module at<dir>/<file>on purpose. Fallow now removes the mock from aduplicate-exportsgroup when the group also holds that module. The rule applies to Jest, Vitest and Rstest mocks. A mock that repeats an export of a different file is still reported, and unused exports and unused files in mock files are still reported.(Closes #4855)
fallow security --gate newnow fails when a change adds a secret read or a server-only import below line 1 of an existing client module. Aclient-server-leakcandidate now points at the env read or at the server-only import, not at line 1, column 0. The JSONline,col,candidate.sinkand trace hops move to that location, and SARIF and the editor follow. Asecret-sourcetrace hop has a newsecret_readsarray that lists each read with itsname,lineandcol, and the gate checks each of these lines. So a read that a change adds to a module with an older read also fails the gate. Thestable_finding_iddoes not change. Thefinding_idof aclient-server-leakcandidate does change, because it holds the line and column, so a verdict file saved before the upgrade does not match these candidates again. A suppression comment for such a candidate must be at the new line. The first run after the upgrade rebuilds the extraction cache.(Closes #4881)
A secret read in a React Router
loaderno longer gives aclient-server-leakcandidate in the computed or the destructured form. The route split now checksprocess.env['X']andconst { X } = process.envthe same asprocess.env.X, so the documented limit for these forms is gone. TheNext:step of a direct secret read now talks about the env read, not about an import, in the CLI and in the editor hover.(Closes #4882)
A leading
./on a path glob matches the same files as the pattern without it. This coversentry,supportEntry,dynamicallyLoaded,overrides[].files,ignoreExports[].file, boundary zone patterns and the other path glob fields. Before, such a pattern passed validation and then matched no file. Lists that reject./still reject it.boundariesautoDiscoverzones match a directory whose name has glob characters. A Next.js folder such asapp/[id]gets a zone that matches onlyapp/[id], notapp/iorapp/d. The zone name staysapp/[id]. The zone patterns infallow list --boundariesshow the escaped glob, for exampleapp/[[]id[]]/**.A negated workspace pattern keeps
*inside one folder level.!packages/*excludespackages/aand no longer excludespackages/a/b. Write!packages/**to exclude each level.!./packages/skipexcludespackages/skip.A recursive workspace pattern works in a checkout whose path has
[,*or?, and with a wildcard before**, such aspkg-*/**. A single*in such a pattern stays inside one folder level. The member patterns of a nested pnpm project in a folder such astool[1]match only that folder.A tsconfig
includeorexcludeentry keeps*and?inside one folder level, as tsc does.src/*.tsno longer claimssrc/nested/a.ts.The Convex
functionsfolder, the Wranglermainfile and the Mintlify docs folder are literal paths. A[in the name matches only itself.--save-regression-baselinekeeps the other settings of a JSON config. The save edits theregression.baselineproperty through the parsed document. Before, a string value"regression", for example inignorePatterns, made the save replace the object after it. A config that does not parse now stops the save with an error and exit code 2.The regression baseline in
fallow.tomlholds the analysis identity and all counts. The save writesanalysisIdentityand the counts of boundary, policy, re-export cycle and package cycle findings. Before, a type-aware run rejected its own saved baseline, and these counts reloaded as zero. The save also keeps a commented# [regression.baseline]line and the tables after the section.fallow migrate --tomlwrites each migrated setting. The TOML output now holdsincludeEntryExports,supportEntry,ignoreBinaries,ignoreExports,overrides,workspaces.settingsandduplicates.normalization, the same as the JSONC output. Before, the TOML output skipped them with no warning.fallow init --tomlescapes workspace globs. A workspace pattern with a"or a\character now gives a validfallow.toml.fallow dead-codeno longer reports the class members of a typed parameter that a computed key reads. A function can call a member of a typed parameter through a computed key, for exampleview[action](). Whenactionhas a type that is a union of string literals, such as"zoomIn" | "zoomOut", fallow credits only the members that the union names. A key of another type, for exampleview[action as keyof View](), can name any member, so fallow counts the call as a use of the whole object. A string-literal key such asview["zoomIn"]()still credits only the member that it names.(Closes #4812)
Four option texts no longer mislead. The first sentence of the
--leanhelp now names the commands that accept the flag: dead-code, health and the combined report. The help also says that other commands and other output formats exit with code 2. Theabouttext offallow setup-hooksnow starts with "Deprecated", sofallow schema --cli-referenceand short command lists show the deprecation. Theduplicates.ignoreDefaultsconfig text now lists every built-in pattern, including the test and mock files (**/*.test.*,**/*.spec.*,**/__tests__/**,**/__mocks__/**). The GitHub Action inputsproduction,production-dead-code,production-health,production-dupes,skip-local,cross-languageandignore-importsnow say thattruepasses the flag and thatfalsekeeps the config value. Forignore-imports, the config value excludes imports by default.(Refs #4856)
fallow reportno longer erases the saved report when--output-filenames the--fromfile. The command opened the output file, which truncates it, before it read--from. With the same file for both, the saved report was lost and the run failed on an empty file. The command now refuses an--output-filethat names the--fromor--mutation-reportfile, through the same path, another spelling, a symlink or a hard link, and exits 2 before it opens anything.fallow coverage setupno longer overwrites a coverage recipe that it did not write. Setup wrotedocs/collect-coverage.mdover any existing file when its setup state was missing or the framework changed. It now replaces the file only while its bytes match the recipe that setup recorded, and keeps any other file. The final step says whether setup wrote the recipe, found it already in place, or kept a different file.fallow agent installkeeps the other MCP servers in an inlinemcp_serverstable. A Codexconfig.tomlwithmcp_servers = { other = { ... } }lost its other servers on install, and uninstall did not find the fallow entry in that form. Both commands now change only the fallow entry. A server section that is not a table or object is refused unless--forceis given.fallow dead-codeno longer reports a type that the inferred type of a used export needs through a return, a class field, a call, a default export or a property read. Fallow now follows a held module binding in these shapes: an arrow or a function that returns it (export const getBox = () => entryBox), a class field without a type annotation (readonly latency = entryBox), a call of a module function with a return type ({ latency: makeBox() }),export default { latency: entryBox }, and a static property read of a module object (holder.box). Declaration emit fails with TS4029 when such a type loses its export. Fallow also reads the method and arrow signatures inside an exported object literal. A call argument does not count, because only the type checker knows the result type of a generic call or a library call such asz.object(...). Withprivate-type-leakson, a type that is not exported and that is in one of these positions is now a private type leak. The extraction cache version changes.(Refs #4850)
fallow list --boundariesshows therootof a zone. The human output prints(root <folder>)after the patterns of a zone that has aroot. The JSON zone object has a new optionalrootfield, which is omitted when the zone has noroot.(Refs #4845)
fallow migratekeeps the gate of the source config. A source config for unused code reports each issue type as an error unless itsrulessay otherwise. Some fallow rules default towarn, so a migrated project could pass a run that failed before, for example on an unuseddevDependenciesentry. The migrated config now setsunused-dev-dependencies,unused-namespace-members,unlisted-binariesandduplicate-export-aliasestoerror, unless the source config sets another severity or turns the issue type off. The migration prints one note that names these rules.dependenciesin anincludeorexcludelist of the source config now also coversdevDependencies. Before,include: ["files", "dependencies"]wrote"unused-dev-dependencies": "off". The fallow default severities do not change. A config that an earlier version migrated stays as it is: set these rules toerrorby hand to get the same gate.(Closes #4905)
A flow-style catalog group is no longer reported as empty. A group such
as
ui: { react: "18" }inpnpm-workspace.yamlgave anempty-catalog-groupfinding, andfallow fixdeleted the line. Itsentries now resolve
catalog:uireferences. A catalog group that is a YAMLalias of another group is also no longer reported as empty.
A flow-style
packageslist inpnpm-workspace.yamldeclaresworkspaces.
packages: [packages/*, apps/*]gave no workspace. A trailingcomment on a
packagesentry is no longer part of the pattern.fallow initreads the same list.Flow-style
overridesinpnpm-workspace.yamlare read. Theircatalog:values now count as catalog consumers, and the override checkssee them.
fallow flagsno longer reportsboundaries-not-configuredandrule-packs-not-configured. The flag scan runs the dead-code pass to match flags with unused exports, and that pass recorded the two kinds.fallow flagsruns no boundary or policy check, so its JSONworkspace_diagnosticsnow omits them. Other diagnostics, for examplenode-modules-missing, stay.(Refs #4845)
A report or baseline path in
/tmpnow works on macOS. On macOSTMPDIRnames a per-user folder, so--save-baseline /tmp/x.jsonexited 2. Each Unix now allows/tmpfor baselines, snapshots and report files, as Linux already did.(Refs #4845)
The human output of
fallow inspectprints the target and identity as fields. Each field is on its ownkey: valueline, not in raw JSON. A field with no value prints asunknown.(Refs #4845)
fallow impact statusprints a short human view. It shows the tracking state, the record count, the store file and the store key. Barefallow impactstill prints the full report. The JSON and Markdown output do not change.(Refs #4845)
The GitHub Action names the input that stops the "SARIF upload skipped" warning. The warning now says
To stop this warning, set sarif: false.The old advice,format: json, did not stop it.(Refs #4845)
A file that code names with a path below the module directory is no longer an unused file.
fallow dead-codenow readspath.join(__dirname, "../scripts/agent.mjs"), the same call withimport.meta.dirnameorpath.resolve, and a join on aconstthat holds such a directory. It also reads the script files in the argument array of a process call whosecwdoption is such a directory, as inspawn(process.execPath, ["scripts/run.ts"], { cwd: REPO_ROOT }). The reference keeps the file in use and credits no export, because a process or a file read uses none. Animport()of the path, as inimport(pathToFileURL(path.join(__dirname, "gen.mjs")).href), credits the exports too. The path must end in a script extension, so a path to a directory does not credit the index file of that directory. A base that the code gets at run time, such as a function parameter orprocess.cwd(), is not read.(Refs #4912)
fallow migratewrites each rule severity in the form that fallow reads. A severity such as"Warning"or"OFF"becomeswarnoroff. A value that is noterror,warnoroff, or that is not a string, now gives one warning for its source rule, and the rule is not migrated. Before, the config kept the value and did not load, or the rule disappeared with no warning.A line break in a source path stays inside the
Migrated fromcomment.fallow migratewrites a\nor\rin the path as an escape, in TOML and in JSONC output. Before, the rest of the path became a config line, and the written config did not load.fallow security --runtime-coverageuses the settings of its own run for the runtime coverage step. The step loaded the config a second time and did not read the environment of the run, so a value such asFALLOW_CACHE_DIRdid not reach it. The step now uses the config of the dead-code analysis of the run, with the same production mode as the files that it reuses.(Refs #4875)
An entry list that a config picks with a conditional expression now gives its entry points. A config can pick its entries from the environment, as in
entry: isBootstrap ? ["src/bin.ts"] : ["src/bin.ts", "src/worker.ts"]. Fallow read no entry from such a value, so it reported the files as unused. It now reads the files of both branches, for each plugin that reads a path or a list of paths from a config, such as thepack.entryof a Vite+ config and thebuild.lib.entryof a Vite config.(Refs #4912)
A changed file with a non-ASCII character or a space in its name is in the diff scope. Git writes a quoted path, or a tab after the path, in the header of such a file. Diff-scoped results (
--diff-file,--diff-stdin,fallow audit,fallow security --gate new, the review comments) did not find the file, so its findings dropped. The change anchors offallow audit --brieffor a file with a space in its name get new ids one time.An added line that starts with
++no longer stops the base-line mapping of a diff.fallow audit --gate new-onlythen kept clone groups as introduced that the change did not write. The walkthrough anchors now also contain such a line.fallow audit --briefcompares a movedpackage.jsonwith its old path. Without--diff-file, each dependency of a moved package showed as added, and its review decisions lost their previous id.fallow fixno longer deletes an unrelated setting ofpnpm-workspace.yaml. When one run removed an unused catalog entry and anempty catalog group, the group removal used a line number from before the
entry removal. It then deleted the next top-level setting, for example
linkWorkspacePackages: true.An emptied catalog with an inline comment on its header stays a
mapping.
fallow fixand the editor quick fix wroteui: # note {}, sothe catalog was null and
pnpm installfailed. They now writeui: {} # note.The editor quick fix checks the unsaved buffer before it removes a catalog
group or entry. It no longer offers to delete a catalog group that has
entries in the buffer, or an entry that belongs to another catalog.
A catalog entry with a blank line after its key is removed in full.
fallow fixand the editor quick fix left the value lines of the entry inthe file.
The SARIF results of the bare
fallowrun and offallow auditnow have a location per clone. Before, the duplication run of these documents gave one result per clone group with no file location and no rule definition, so a code scanning service could not show the result at a file. The duplication run now has the shape offallow dupes --format sarif: one result per clone instance, with a file location and a source snippet, and a declaredfallow/code-duplicationrule. The message text isCode clone group N (...), as infallow dupes.fallow report --fromof a saved bare run or audit gives the same run. The rule id and the run categories (fallow/dupes/,fallow/audit/dupes/) do not change. A code scanning service that matched the old results by fingerprint sees new alerts once.(Closes #4873)
The CLI reference names
fallow architecturefor the architecture issue types.fallow schema --cli-reference,fallow schemaand the issue registry gave the cycle, boundary and policy issue types the commanddead-codeand a deprecated option, for example--circular-deps. Now these seven rows givecommand: "architecture"and--cycles,--boundariesor--policy. The newdeprecated_filter_flagfield keeps the old option.fallow dead-code --circular-depsand the other old options work as before, and MCPissue_typesstill selects these findings. (Closes #4883)Commands in a development container file and in a
t3.jsonproject file now count as uses.fallow dead-codereads the lifecycle commands of.devcontainer/devcontainer.json,.devcontainer.jsonand.devcontainer/<name>/devcontainer.json(initializeCommand,onCreateCommand,updateContentCommand,postCreateCommand,postStartCommand,postAttachCommand), and thescripts[].commandvalues of at3.jsonfile. It reads each command as it reads a package.json script: a script file that the command runs is an entry point, a binary that it runs credits the package, and a project shell file that it runs is read too.(Refs #4912)
A CI step that puts a
node_modules/.binpath in a shell variable now credits the package. A step such asbundler=scripts/node_modules/.bin/esbuildfollowed by"$bundler" src/a.tsruns the binary through the variable, so fallow reported the package as an unused dependency. The assignment now counts as the use of the binary.(Refs #4912)
An Expo app no longer needs a config entry for its fingerprint config, its font packages and its native-only modules. The Expo plugins keep
fingerprint.config.jsin use. A font file path in the app config, such as"@expo-google-fonts/inter/400Regular/Inter_400Regular.ttf", credits the package that holds the file. A dependency with anexpo-module.config.jsonfile and no JavaScript entry is a native module that Expo autolinking adds to the build, so fallow no longer reports it as unused. Both credits apply only to a dependency that thepackage.jsonof the app declares and that is installed.(Refs #4912)
fallow fixno longer edits a generated file. The fixer removed an unused export, enum member or class member in a file that a code generator writes, and the next run of the generator put it back.fallow fixnow keeps such a file and reports it as askippedentry withskip_reason: "generated_source". A file is generated when its path has ageneratedor__generated__folder or a.generated.or.gen.name part, or when its leading comment has@generated, or names the generator together with "do not edit", as in// Generated by <tool>. Do not edit.. The skip is intentional and does not change the exit code.fallow dead-codestill reports the unused exports of the file.(Refs #4912)
The CLI gate line and the MCP
warningssentence now show the same gate numbers, gates, empty-scope advice and baseline facts. Both surfaces now read the facts of the verdict from one reader infallow-output(Closes #4874). These differences are gone:observedtext of the decision-surface rows and the exit-reason line) now rounds a fractional gate number to two decimals, as the MCP sentence did. A duplication of66.66666666666666percent now reads66.67. Thegate_outcomesmember keeps every digit.5.004percent against a threshold of5reads5.004 against 5, not5 against 5.79.98against a minimum of80now reads79.9.gate_outcomesentry withoutenforcedas not enforced, as the MCP server did. Before, the CLI dropped the entry.changed-since,diff-filter). For another request, such asgroup-filter, it tells the caller to check the value of the request, as the CLI line names that request.request_outcomesentry without a stringstatusas an unapplied request. The schema requiresstatus, so both surfaces now skip such an entry, as they do for a gate entry.fallow initkeeps a.gitignorethat is not UTF-8. It appends.fallow/to the bytes of the file. Before, it replaced such a file withthe one line
.fallow/.A partial save of a regression baseline keeps a file that it cannot use.
Configuration
📅 Schedule: (UTC)
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.