Closed benjamin-heasly closed 2 years ago
Thanks @paulstey for kicking off the build, and @eldu for your feedback. I looked into the error it was putting up and I'll try to summarize what I saw / did.
The build was trying to run node app.js
and failing on new import
statements within app.js
and other files. I tried adding babel to the build and running node app.js
on the version compiled by babel, and this fixed the import
error.
But even so, the same step later failed when jspsych 7 tried to access the window
. I think this makes sense, if this app and jspsych are intended for browser use rather than via node
directly. With this in mind I removed the node app.js
step from the build. This allows the build to proceed to the Jest tests, which do run and pass.
I'm thinking the Jest tests are covering more than node app.js
, and so maybe this is sufficient?
But I could be missing something and we really do want to run node app.js
as part of the build. If so I could look into that further, and I might ask your advice on how to work around the window
.
Thanks!
Woo hoo! Thanks again. I'll go ahead and merge this and I'm excited to put all these pieces together...
Hi @eldu and @mirestrepo -- it looks like the build on main
is failing after this merge -- https://github.com/brown-ccv/behavioral-task-trials/actions/runs/2630492638
I took a look, I'm not sure but if I'm reading things correctly, this part of the build uses a GH_TOKEN
secret, which maybe has elevated permissions compared to the default GITHUB_TOKEN
(?) in order to push to main
(?) and possibly this token has expired (?) since the last deploy 16 months ago.
Does that sound possible or familiar, and would you be able to check on this as an admin?
Thank you!
:tada: This PR is included in version 2.0.0 :tada:
The release is available on:
npm package (@latest dist-tag)
Your semantic-release bot :package::rocket:
@benjamin-heasly
@broarr and @paulstey helped to update the GH_TOKEN
and the deploy keys for the repo! Should be good to go now!
Greetings @mirestrepo, @eldu, @hollandjg! Could I ask for another review on the way to upgrading honeycomb with jspsych 7?
This PR is intended to have no functional changes, but makes a few upgrades that came out of my local testing with honeycomb and jspsych 7. I found that the jspsych 7 upgrades went beyond the honeycomb repo itself, and into this repo as well. Once I made these changes locally, I was able to run through the honeycomb demo task using jspsych 7.
As a summary:
package-lock.json
andyarn.lock
, adding some noisejspsych-react
withjspsych
7require()
style to esimport
style@babel/preset-env
as a dev dependency so that tests still work withimport
Changing from
require()
toimport
seemed invasive and I'm not sure what you think!My reasoning was:
require()
didn't seem to work, the results were string names of obscure.cjs
files, rather than the expected function or class symbols.require()
ing es modules is not expected to work.import
.