Skip to content

[BUG] file not found error #1307

Closed
Closed

Description

@faten-kardous

Overview of the issue

file not found error when running compodoc
in the file with path 'webapp/src/app/app-routing.module.ts', i think this import line is related to the error
import { appRoutes } from './custom-app-routes'
the 'custom-app-routes.ts' exists under the same folder as 'app-routing.module.ts' but when running compodoc it raised an error:
file not found under another path:
FileNotFoundError: File not found: webapp/src/custom-app-routes.ts instead of webapp/src/app/custom-app-routes.ts

Operating System, Node.js, npm, compodoc version(s)

Angular 14, node 14,windows 10

Angular configuration, a package.json file in the root folder
Compodoc installed globally or locally ?

globally

If possible sourcecode of the file where it breaks
If possible your terminal logs before the error

[16:43:44] parsing : C:/Users/fkardous/Ui-Showcase/showcase/apps/ng-showcase-config/webapp/src/app/app-routing.module.ts
[16:43:44] Analysing routes definitions and clean them if necessary
Unhandled Rejection at: Promise {
FileNotFoundError: File not found: C:/Users/fkardous/Ui-Showcase/showcase/apps/ng-showcase-config/webapp/src/custom-app-routes.ts
at DirectoryCoordinator.addSourceFileAtPath (C:\Users\fkardous\Ui-Showcase\showcase\apps\ng-showcase-config\webapp\node_modules\ts-morph\dist\ts-morph.js:18643:19)
at Project.addSourceFileAtPath (C:\Users\fkardous\Ui-Showcase\showcase\apps\ng-showcase-config\webapp\node_modules\ts-morph\dist\ts-morph.js:20088:51)
at _loop_3 (C:\Users\fkardous\Ui-Showcase\showcase\apps\ng-showcase-config\webapp\node_modules@compodoc\compodoc\dist\index-cli-f7393cac.js:6567:33)
at RouterParserUtil.cleanFileSpreads (C:\Users\fkardous\Ui-Showcase\showcase\apps\ng-showcase-config\webapp\node_modules@compodoc\compodoc\dist\index-cli-f7393cac.js:6597:17)
at AngularDependencies.getSourceFileDecorators (C:\Users\fkardous\Ui-Showcase\showcase\apps\ng-showcase-config\webapp\node_modules@compodoc\compodoc\dist\index-cli-f7393cac.js:9605:32)
at C:\Users\fkardous\Ui-Showcase\showcase\apps\ng-showcase-config\webapp\node_modules@compodoc\compodoc\dist\index-cli-f7393cac.js:9397:31
at Array.map ()
at AngularDependencies.getDependencies (C:\Users\fkardous\Ui-Showcase\showcase\apps\ng-showcase-config\webapp\node_modules@compodoc\compodoc\dist\index-cli-f7393cac.js:9386:21)
path: 'C:/Users/fkardous/Ui-Showcase/showcase/apps/ng-showcase-config/webapp/src/custom-app-routes.ts',
code: 'ENOENT'
}
} reason: FileNotFoundError: File not found: C:/Users/fkardous/Ui-Showcase/showcase/apps/ng-showcase-config/webapp/src/custom-app-routes.ts
at DirectoryCoordinator.addSourceFileAtPath (C:\Users\fkardous\Ui-Showcase\showcase\apps\ng-showcase-config\webapp\node_modules\ts-morph\dist\ts-morph.js:18643:19)
at Project.addSourceFileAtPath (C:\Users\fkardous\Ui-Showcase\showcase\apps\ng-showcase-config\webapp\node_modules\ts-morph\dist\ts-morph.js:20088:51)
at _loop_3 (C:\Users\fkardous\Ui-Showcase\showcase\apps\ng-showcase-config\webapp\node_modules@compodoc\compodoc\dist\index-cli-f7393cac.js:6567:33)
at RouterParserUtil.cleanFileSpreads (C:\Users\fkardous\Ui-Showcase\showcase\apps\ng-showcase-config\webapp\node_modules@compodoc\compodoc\dist\index-cli-f7393cac.js:6597:17)
at AngularDependencies.getSourceFileDecorators (C:\Users\fkardous\Ui-Showcase\showcase\apps\ng-showcase-config\webapp\node_modules@compodoc\compodoc\dist\index-cli-f7393cac.js:9605:32)
at C:\Users\fkardous\Ui-Showcase\showcase\apps\ng-showcase-config\webapp\node_modules@compodoc\compodoc\dist\index-cli-f7393cac.js:9397:31
at Array.map ()
at AngularDependencies.getDependencies (C:\Users\fkardous\Ui-Showcase\showcase\apps\ng-showcase-config\webapp\node_modules@compodoc\compodoc\dist\index-cli-f7393cac.js:9386:21)
at CliApplication.Application.getDependenciesData (C:\Users\fkardous\Ui-Showcase\showcase\apps\ng-showcase-config\webapp\node_modules@compodoc\compodoc\dist\index-cli-f7393cac.js:11176:40)
at C:\Users\fkardous\Ui-Showcase\showcase\apps\ng-showcase-config\webapp\node_modules@compodoc\compodoc\dist\index-cli-f7393cac.js:10985:23 {
path: 'C:/Users/fkardous/Ui-Showcase/showcase/apps/ng-showcase-config/webapp/src/custom-app-routes.ts',
code: 'ENOENT'
}
[16:43:44] Sorry, but there was a problem during parsing or generation of the documentation. Please fill an issue on github. (https://github.com/compodoc/compodoc/issues/new)

Motivation for or Use Case
Reproduce the error
Related issues
Suggest a Fix

Activity

  1. changed the title [-][BUG][/-] [+][BUG] file not found error[/+] on May 20, 2023
  2. added a commit that references this issue on May 24, 2026
    fd97255
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions