fix(lint): review and enable rules from @nextcloud/eslint-config v9 migration - #8067
Closed
masterlouis wants to merge 4 commits into
Closed
Conversation
21 tasks
lfals
pushed a commit
to lfals/libresign
that referenced
this pull request
Aug 28, 2026
Replace raw console calls with the @nextcloud/logger wrapper and scope no-console off for test files that intentionally intercept console output. Cherry-picked from masterlouis LibreSign#8067 (775cadb). Co-authored-by: Luigi <gigi.mastro.wolf@gmail.com> Signed-off-by: Luis Amorim <luisfelipeamorim@hotmail.com>
Member
|
@masterlouis, closing this as it has been superseded by: Your commits were moved to #8101 using cherry-pick. |
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.
Related to #7876
📝 Summary
Follow-up of #7876 (
@nextcloud/eslint-configv8 → v9 upgrade). This PRreviews and progressively enables the ESLint rules newly introduced by
v9, tracked in
libresign/disabled-during-migrationineslint.config.mjs, one rule per commit as requested in the issue.main. Once #7876 lands, this diff will shrink to just thelint-migration work.
What's done so far
needed before
npm run lintcould even run):vue/no-unused-componentsis now scoped tofiles: ['**/*.vue']only. In v9 the
vueplugin is registered only for.vuefiles,so applying this rule globally crashed ESLint on non-Vue files.
import/orderandimport/no-unresolved, which relied oneslint-plugin-import— no longer a dependency of@nextcloud/eslint-configv9. Import ordering is now handled byperfectionist/sort-imports(already provided by the sharedconfig), which will be reviewed as its own rule.
eslint-disablecomments referencing rulesthat no longer exist, or no longer apply in their file's context
(
import/no-named-as-default,import/no-unresolved,jsdoc/require-jsdoc, an unusedno-newdirective).no-console: replaced application-levelconsole.error/console.warncalls across 13 files with theproject's existing
src/logger.jswrapper around@nextcloud/logger, passing error/context as a structured object(e.g.
logger.error('Failed to save filters', { error })) insteadof loose positional arguments. Test files that intentionally
intercept
console.*for assertions (src/tests/setup.js,src/tests/store/filters.spec.ts) are excluded via a scopedno-console: offoverride, since that's test tooling rather thanapplication logging.
Still to do
Remaining rules in
libresign/disabled-during-migration(~96 rules)will be enabled incrementally, one commit per rule, following the
process described in the issue.
🧪 How to test
npm cinpm run lint→ should report 0 problemsnpm run test:unit -- --run→ should pass with no new failures✅ Checklist