codesandbox / codesandbox/codesandbox-client
CI build in codesandbox seem to ignore `main` field in package.json
@DeMoorJasper is already working on this.
Since May 25, 2021.
- Dominant language
- JavaScript
- Stars
- 13.6k
- Forks
- 2.4k
- Avg merge
- 6d 19h
- Merged PRs (30d)
- 2
Description
🐛 bug report
Preflight Checklist
- I have read the
Contributing Guidelines
for this project. - I agree to follow the
Code of Conduct
that this project adheres to. - I have searched the issue tracker for an issue that matches the one I want
to file, without success.
Description of the problem
Using a library like
import { QueryStatus } from '@rtk-incubator/simple-query';
does not work. Using the direct folder of the entry point like
import { QueryStatus } from '@rtk-incubator/simple-query/dist';
does though.
This happens only with CodeSandbox CI built packages. I uploaded the (apart from the package name) identical package to npm as @phryneas/rtk-simple-query@0.0.1-67b8bb3 and that works as expected.
To Reproduce
See this sandbox: https://codesandbox.io/s/rtk-simple-query-demo-forked-ykpf3?file=/src/features/posts/PostsManager.tsx
Changing the offending import either to
import { QueryStatus } from '@rtk-incubator/simple-query/dist';
or
import { QueryStatus } from '@phryneas/rtk-simple-query';
will make the build succeed - as mentioned: @phryneas/rtk-simple-query is exactly the same as @rtk-incubator/simple-query apart from one coming out of CSB CI and one coming from npm.
PS: this is the offending CI build, but this does seem to happen generally: https://ci.codesandbox.io/status/rtk-incubator/simple-query/pr/22/builds/72883
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.