New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to write a reference to #6305
Comments
Check the name property in the package.json of the library you are importing - it might not match the path in your root tsconfig.base.json. In my case the name property in the package.json was |
Hi @TheophileSketo That's exactly what it is. New libraries are created incorrectly. Instead of @iko/shared/util-pipes it creates @iko/shared-util-pipes. We are not creating libraries any differently than we did before. This started recently. Don't know if related. There is a warning that's been coming up in the later versions of nx.dev:
|
Sorry for the inconvenience! There was an issue where the generated package name format was not in sync with what was added to the By migrating to the latest version, this issue should be solved. If you can't migrate to the latest version at this point, please make sure your library package name matches the path mapping in the I'm closing this one since a fix has been merged and released. If you still have issues after updating, please feel free to reopen this issue or create a new one. |
This issue has been closed for more than 30 days. If this issue is still occuring, please open a new issue with more recent context. |
Current Behavior
Since about 10 days ago or less, all newly created libraries cannot be referenced from other libraries. It's like they are missing something. I have run diffs on all configuration files between old and newly created modules and they all look identical.
Expected Behavior
Modules should compile successfully. All older modules interoperate fine. Every new module I create now builds fine but cannot be referenced by other modules.
Steps to Reproduce
I created a repo with parts from our latest codebase. I created 2 modules in this repo with the same versions in my package.json as in my real repo. One module references the other: Github repo that reproduces error
yarn install
nx build geo-name-util-geo-name-pipes
to make sure you successfully build the dependencynx build geo-name-feature-geo-name
that is dependent on the previous module. This will fail.Failure Logs
Unable to write a reference to GeoNameProvincePipe in /Users/crash/Desktop/dep/libs/geo-name/util-geo-name-pipes/src/lib/geo-name-province-pipe/geo-name-province.pipe.ts from /Users/crash/Desktop/dep/libs/geo-name/util-geo-name-pipes/src/lib/geo-name-util-geo-name-pipes.module.ts
Environment
`
Node : 12.22.2
OS : darwin x64
yarn : 1.22.10
nx : Not Found
@nrwl/angular : 12.5.7
@nrwl/cli : 12.5.7
@nrwl/cypress : 12.5.7
@nrwl/devkit : 12.5.7
@nrwl/eslint-plugin-nx : 12.5.7
@nrwl/express : Not Found
@nrwl/jest : 12.5.7
@nrwl/linter : 12.5.7
@nrwl/nest : Not Found
@nrwl/next : Not Found
@nrwl/node : Not Found
@nrwl/react : Not Found
@nrwl/schematics : Not Found
@nrwl/tao : 12.5.7
@nrwl/web : Not Found
@nrwl/workspace : 12.5.7
@nrwl/storybook : 12.5.7
@nrwl/gatsby : Not Found
typescript : 4.3.5
`
The text was updated successfully, but these errors were encountered: