Comments (8)
Ran into this issue while building a docker image from someone else's repo. It seems that this package is assuming that cypress/plugins/index.js
already exists
note overwrites existing cypress/plugins/index.js file once. In other installs looks for file cypress/plugins/cy-ts-preprocessor.js to avoid overwriting.
Usually this is not the case when building a docker image.
Seems there are two ways to resolve it:
If you are just trying to create a production docker image (not trying to run tests) then you should use npm install --only=prod
and make sure @bahmutov/add-typescript-to-cypress
package is installed into devDependencies section of package.json.
OR
Add RUN ["mkdir","-p","cypress/plugins"]
to your Dockerfile to create the cypress plugins folder before running npm install
from add-typescript-to-cypress.
I have the same issue. Any solution?
from add-typescript-to-cypress.
from add-typescript-to-cypress.
same here. @bahmutov any idea?
from add-typescript-to-cypress.
Getting this issue specifically while trying to implement caching of node_modules
in AWS CodeBuild. Hopefully the following lines can help indicate the problem there:
[Container] 2020/04/03 04:46:05 Moving to directory /codebuild/output/src192289327/src/github.com/github-org/github-repo
--
15 | [Container] 2020/04/03 04:46:05 MkdirAll: /codebuild/local-cache/custom/dba27c31aad935787bb275c3e5e4e957708f15386de599eff1db476022cd7e4c/node_modules
16 | [Container] 2020/04/03 04:46:05 Symlinking: /codebuild/output/src192289327/src/github.com/github-org/github-repo/node_modules => /codebuild/local-cache/custom/dba27c31aad935787bb275c3e5e4e957708f15386de599eff1db476022cd7e4c/node_modules
I'm assuming this has something to do with using symlinking, then path.join
and it not actually getting into the source folder.
Thoughts? Suggestions?
from add-typescript-to-cypress.
@rjriel is this the same problem? I don't see how it relates.
from add-typescript-to-cypress.
I think the solution by @ccrockett in #57 (comment) is the best - either don't install dev dependencies like this one, or have the cypress
folder there (since it should be present to run Cypress tests).
from add-typescript-to-cypress.
@bahmutov sorry, I may have been confusing, it is the same issue. My docker build fails and I get the error about the cypress folder not being found. My explanation was more detailing how the error in my case is likely due to symlinking and thinking maybe there's a better solution than using path.join
with a bunch of ../
to get to the project directory. I'll do some research and maybe submit a PR
from add-typescript-to-cypress.
Related Issues (20)
- write task in typescript
- import json cause the Cypress to crash
- When TypeScript code not compiling, Cypress crashes
- Which is the best way to integrate with @cypress/code-coverage?
- "webpack module missing" error when adding this module to project HOT 3
- When installing via pnpm I get Cannot find "cypress" folder
- shelljs dependancy high vulnerability reported by npm audit HOT 1
- README disagrees with current Cypress documentation after Cypress 4.4.0 HOT 1
- bug: ts-loader@4 in project breaks cypress run HOT 3
- set up renovate app HOT 1
- feature: read cypress folder path from cypress.json if different than default HOT 2
- Can we uninstall this after the initial run? HOT 8
- Not compatible with newer ts-loader HOT 2
- Yarn Warning: Browserslist 2 could fail
- add renovate and start upgrading dependencies HOT 1
- Dependency Dashboard
- need end-to-end test HOT 1
- Can we use path aliases with TypeScript HOT 2
- Add support for Yarn PnP HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from add-typescript-to-cypress.