Open Brooooooklyn opened 3 months ago
*🆕 Untriaged**
The team has not yet reviewed the issue. We usually do it within one business day. Docs: https://github.com/toeverything/AFFiNE/blob/canary/docs/issue-triaging.md
This is an automatic reply by the bot.
/cc @Boshen
My guess is the ignore match here.
Specifying packages/backend/server/dist
forces linting this path.
@Boshen What I mean is that circular dependencies can be found in the compiled code, but not in the TypeScript code.
Probably a bug, can you assign this to me so I don't forget?
The referenced fix will display the following output, feel free to fix these before our next release.
oxlint -c oxlint.json --tsconfig tsconfig.json --import-plugin
× eslint-plugin-import(no-cycle): Dependency cycle detected
╭─[packages/backend/server/src/core/features/index.ts:3:28]
2 │
3 │ import { UserModule } from '../user';
· ─────────
4 │ import { EarlyAccessType, FeatureManagementService } from './management';
╰────
help: These paths form a cycle:
-> ../user - packages/backend/server/src/core/user/index.ts
-> ./resolver - packages/backend/server/src/core/user/resolver.ts
-> ../common - packages/backend/server/src/core/common/index.ts
-> ./admin-guard - packages/backend/server/src/core/common/admin-guard.ts
-> ../features - packages/backend/server/src/core/features/index.ts
× eslint-plugin-import(no-cycle): Dependency cycle detected
╭─[packages/backend/server/src/core/user/resolver.ts:24:23]
23 │ import { CurrentUser } from '../auth/session';
24 │ import { Admin } from '../common';
· ───────────
25 │ import { AvatarStorage } from '../storage';
╰────
help: These paths form a cycle:
-> ../common - packages/backend/server/src/core/common/index.ts
-> ./admin-guard - packages/backend/server/src/core/common/admin-guard.ts
-> ../features - packages/backend/server/src/core/features/index.ts
-> ../user - packages/backend/server/src/core/user/index.ts
-> ./resolver - packages/backend/server/src/core/user/resolver.ts
× eslint-plugin-import(no-cycle): Dependency cycle detected
╭─[packages/frontend/core/src/components/page-list/index.tsx:6:15]
5 │ export * from './components/page-display-menu';
6 │ export * from './docs';
· ────────
7 │ export * from './docs/page-list-item';
╰────
help: These paths form a cycle:
-> ./docs - packages/frontend/core/src/components/page-list/docs/index.ts
-> ./virtualized-page-list - packages/frontend/core/src/components/page-list/docs/virtualized-page-list.tsx
-> ./page-list-header - packages/frontend/core/src/components/page-list/docs/page-list-header.tsx
-> ../view/use-edit-collection - packages/frontend/core/src/components/page-list/view/use-edit-collection.tsx
-> ./edit-collection/edit-collection - packages/frontend/core/src/components/page-list/view/edit-collection/edit-collection.tsx
-> @affine/core/components/hooks/affine/use-all-page-list-config - packages/frontend/core/src/components/hooks/affine/use-all-page-list-config.tsx
-> @affine/core/components/page-list - packages/frontend/core/src/components/page-list/index.tsx
× eslint-plugin-import(no-cycle): Dependency cycle detected
╭─[packages/frontend/core/src/modules/peek-view/index.ts:15:57]
14 │ export { PeekViewEntity, PeekViewService };
15 │ export { PeekViewManagerModal, useInsidePeekView } from './view';
· ────────
╰────
help: These paths form a cycle:
-> ./view - packages/frontend/core/src/modules/peek-view/view/index.ts
-> ./peek-view-manager - packages/frontend/core/src/modules/peek-view/view/peek-view-manager.tsx
-> ./doc-preview - packages/frontend/core/src/modules/peek-view/view/doc-preview/index.ts
-> ./doc-peek-view - packages/frontend/core/src/modules/peek-view/view/doc-preview/doc-peek-view.tsx
-> @affine/core/components/blocksuite/block-suite-editor - packages/frontend/core/src/components/blocksuite/block-suite-editor/index.ts
-> ./blocksuite-editor - packages/frontend/core/src/components/blocksuite/block-suite-editor/blocksuite-editor.tsx
-> ./blocksuite-editor-container - packages/frontend/core/src/components/blocksuite/block-suite-editor/blocksuite-editor-container.tsx
-> ./lit-adaper - packages/frontend/core/src/components/blocksuite/block-suite-editor/lit-adaper.tsx
-> ./bi-directional-link-panel - packages/frontend/core/src/components/blocksuite/block-suite-editor/bi-directional-link-panel.tsx
-> ../../affine/reference-link - packages/frontend/core/src/components/affine/reference-link/index.tsx
-> @affine/core/modules/peek-view - packages/frontend/core/src/modules/peek-view/index.ts
Released in oxlint v0.9.8
yarn lint:ox
is fine on our canary branch. But if runyarn oxlint --import-plugin -D no-cycle -D no-self-import packages/backend/server/dist
on compiled files, there are several errors: