issue reverting jspm back to 0.16.53 (last stable build) - jspm

I recently tried latest beta version of jspm "0.17.0-beta.47" in a local version of a project that i pull from a git repository.
Didnt have much success so deleted the project and did a fresh git clone to set everything back.
so the project is backed to using jspm#0.16.53 and usually works fine but since trying this beta version and reverting back every time i run 'jspm install' it tries to add the following line to our config.js file
"systemjs-json": "github:systemjs/plugin-json#0.1.2"
where as before this didnt happen. its also crashing when i run the tests on my local machine with the error
' Error: (SystemJS) XHR error (404 Not Found) loading http://localhost:9877jspm_packages/npm/es6-iterator#2.0.3.json
Error loading http://localhost:9877jspm_packages/npm/es6-iterator#2.0.3.json!http://localhost:9877jspm_packages/github/systemjs/plugin-json#0.1.2.js as "../es6-iterator#2.0.3.json!systemjs-json" from http://localhost:9877jspm_packages/npm/es6-iterator#2.0.3/array.js'
like i say this didnt do this before i tried the beta version. i got a collegue to git clone the project onto his machine and everything works fine so its
acting as if trying out the beta version has left some global setting on my machine that i cant remove.
any suggestions what could be happening?

Related

cypress cache clear hanging

For context I am working in windows 10 with Node.js.
Having set up cypress successfully after a load of trial and error in one project file I am starting from scratch with another project file to work out the exact steps.
For some reason it is failing with the new attempt and having noticed the errors show v 7/3/0 whereas the errors for the previous showed v 7.2.0 I thought I'd return to the first project file and try
cypress clear cache as recommended at docs.cypress.io/guides/references/troubleshooting which I've assumed that was to be run at the Node.js command prompt.
Having done so Node.js is just hanging.
Is this expected behaviour?
Have I misunderstood the instructions?
Thanks

KeystoneJS: "keystone.getResolvers is not a function" after deleting yarn.lock

Edit: I tried going back to the already-working develop branch and same story. It must be something in node_modules?
I'm working on a KeystoneJS project. I added hooks to one of my lists and the project worked fine.
When I was finished with my work I pushed my work to GitHub and made a pull request for my team. However GitHub complained about a security error (in yarn.lock), so I deleted yarn.lock, reinstalled node_modules(yarn). When I ran the project again locally, however, I received the following error
✔ Validated project entry file ./tsout/index.js
✔ Keystone server listening on port 4545
✔ Initialised Keystone instance
✖ Connecting to database
TypeError: keystone.getResolvers is not a function
at createApolloServer (/Users/r/Documents/projects/yaa-keystone/node_modules/#keystonejs/app-graphql/lib/apolloServer.js:148:25)
at GraphQLApp.prepareMiddleware (/Users/r/Documents/projects/yaa-keystone/node_modules/#keystonejs/app-graphql/index.js:23:20)
at /Users/r/Documents/projects/yaa-keystone/node_modules/#keystonejs/keystone/lib/Keystone/index.js:752:17
at Array.map (<anonymous>)
at Keystone.prepare (/Users/r/Documents/projects/yaa-keystone/node_modules/#keystonejs/keystone/lib/Keystone/index.js:751:12)
at executeDefaultServer (/Users/r/Documents/projects/yaa-keystone/node_modules/#keystonejs/keystone/bin/utils.js:112:42)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
It's throwing the error deep inside the keystone package in node_modules. I deleted and reinstalled node_modules, I reverted my project to a commit from yesterday that worked fine, but I keep getting the same error.
I realise it's hard to say what the issue is, but any help in figuring out how to start tracking this down would be helpful.
This turned out to be an error with new package updates to KeystoneJS conflicting with my code. When I removed yarn.lock and ran yarn it downloaded the latest versions.

Error: Cannot find module './dist-tools/transform.js' from '/opt/atlassian/pipelines/agent/build/node_modules/aws-sdk'

Hi so we have something interesting happening in our builds.
Nothing regarding the gulp build script changed from our side for one of our projects. But suddenly today when we try to do a pipeline build on one of our repositories we get the following stacktrace error:
Error: Cannot find module './dist-tools/transform.js' from '/opt/atlassian/pipelines/agent/build/node_modules/aws-sdk'
at /opt/atlassian/pipelines/agent/build/node_modules/resolve/lib/async.js:128:35
at load (/opt/atlassian/pipelines/agent/build/node_modules/resolve/lib/async.js:147:43)
at onex (/opt/atlassian/pipelines/agent/build/node_modules/resolve/lib/async.js:172:17)
at /opt/atlassian/pipelines/agent/build/node_modules/resolve/lib/async.js:13:69
at FSReqWrap.oncomplete (fs.js:152:21)
Has anyone come accross this before? (we are using node 10.17 for our builds)
We tested the same code from our local builds and get the exact same issue. It seems that something in the aws-sdk package changed?
Since this error suddenly appeared this morning, we looked at our aws-sdk package and updated it to the latest version (2.643.0), but we still get the same error. No code that uses the aws-sdk package has changed.
Also seeing this as of this morning. I find this somewhat sus (adding dist-tools to npmignore).
https://github.com/aws/aws-sdk-js/commit/98c40e64cb7d60927c6a0cec49592fc1fcaa59d7
I wonder if pulling the package directly from GH would resolve.
UPDATE:
I've got a convo going on over here about this https://github.com/aws/aws-sdk-js/issues/3159
We downgraded to the previous version and our issue went away.

Node serving an old version but still compiles updates

I'm creating a React application and am running into this issue. When I make changes to code, Node does recompile and even recognizes errors in the code, but no matter what, the localhost in the browser remains unchanged. Here's a list of things that I've tried:
Clearing the browser's cache and hard reloading the page
Switching browsers
Turning Node off and on again
Reinstalling Node
Creating a new directory, copying over the code, and then installing Node there
Turning the whole computer off and on again
I'm not sure what to try anymore. When installing Node, there are no errors, and no errors if I run npm start or npm build. As I said, I know Node is looking in the right directory since it recognizes when I make changes and shows errors when the code fails to compile. I also know I'm looking at the right localhost page since it isn't available when Node isn't running. However, the page remains perfectly usable and unchanged even if the code fails to compile, and actually is able to load before Node compiles all of the code.
I got the code itself from a zip file from GitHub and people who have their frontend set up have no issues with it. Node and all the other dependencies were downloaded by me, again, with no errors.
I'm using Node v10.16.0 and npm v6.9.0

Failing to push to heroku for nodejs web3 - it is trying to find web3#1.0.0-beta.42 postinstall

I had pushed a node.js react with DApp with web3#1.0.0-beta-41 yesterday (2/6/19) and it worked. Since this morning, when I try to push the same codes it comes up with
web3#1.0.0-beta.42 postinstall
C:\BaandaDev\baandadev-03\client\node_modules\web3
node angular-patch.js module.js:549
throw err;
^ Error: Cannot find module 'C:\BaandaDev\baandadev-03\client\node_modules\web3\angular-patch.js'
(Please disregard baanda ... those are my directory names but the
error is emerging from node modules)
Why is it looking for web3#1.0.0-beta.42 when I am not even asking for it?
I have reduced the version till web3#1.0.0.beta-37 and heroku still looks for beta.42 angular patch (I am not even using angular). The worst thing is ... it worked yesterday.
The only thing I can think of is, Ethereum released web3#1.0.0-beta.42 yesterday. But, it does not explain why heroku would look for a patch for something else.
Interestingly, when I clone the one that is working in heroku in my local machine using something like heroku git:clone -a baandadev03-t2 and then run npm install to re-instead it in my local machine, it throws the same problem in my local machine. However, if I npm i --save webe3#1.0.0-beta.41 manually, it does deploy without a hitch.
Suspect: npm install (generic that install node-modules from package.json is broken for web3 somehow). That is why it is breaking in heroku as well as in local. But, that's a suspect only.
$ git push heroku master (and heroku should push it in and not look for modules I am not asking for).
Likely it is because of web3 npm is breaking. They (web3) have release version web1.0.0-beta.40 to 43 in 3 days. But, I also realized that generic npm install, used for generating node-modules from package.json (node.js), is breaking on web3 on both side. In heroku after push when they try to gen the node-modules. And, when I clone the version from heroku into my own laptop, it cry at the same place (while creating node module at web3). Both places are looking for angular library that it cannot find (I do not know why they would do that - a bug?). And, even when I specify much lower version of web3, it still looks for it that it never did in the past.
I have reported the bug and hope they fix it quickly. I removed all web3 reference from my application and it went into heroku nice and fine. But, that is not good when app depends on smart contracts ... right :)?

Resources