Closed nelsonic closed 1 year ago
@snyk finds 4 issues with this PR, all jsonwebtoken
:
Thanks @snyk, suuuuuuuper helpful. Thanks for failing the build that releases the new version of the package to fix the problem you've identified. 🎉
Meanwhile what I really want is to know if the CI (GitHub Actions) is passing so I know if Hapi@v21
works ... 🤷♂️
OK. I'm done
with @snyk between them creating a PR as me #373 🤦♂️
and now prematurely failing this build that is updating the issue they have identified ... done
. 🙅
What kind of security system allows a manual override? 🤦♂️ https://app.snyk.io/org/nelsonic/pr-checks/2af9b479-c08f-4551-8e13-e0815297bc90
This is an acknowledgement that their system is fundamentally broken. 💔
"Mark as successful" indeed ...
Attempted to run npm audit fix
... got:
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR!
npm ERR! While resolving: eslint-plugin-prettier@3.1.3
npm ERR! Found: eslint@7.0.0-rc.0
npm ERR! node_modules/eslint
npm ERR! dev eslint@"^7.0.0-alpha.0" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer eslint@">= 5.0.0" from eslint-plugin-prettier@3.1.3
npm ERR! node_modules/eslint-plugin-prettier
npm ERR! dev eslint-plugin-prettier@"^3.1.2" from the root project
npm ERR!
npm ERR! Conflicting peer dependency: eslint@8.31.0
npm ERR! node_modules/eslint
npm ERR! peer eslint@">= 5.0.0" from eslint-plugin-prettier@3.1.3
npm ERR! node_modules/eslint-plugin-prettier
npm ERR! dev eslint-plugin-prettier@"^3.1.2" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
Gonna try and manually update eslint
and prettier
... 🧑💻⏳ 🙄
Somewhat predictably ...
npm run lint
> hapi-auth-jwt2@10.3.0 lint
> eslint lib
/Users/n/code/hapi-auth-jwt2/lib/index.js
20:21 error Insert `·` prettier/prettier
46:37 error Insert `·` prettier/prettier
56:32 error Insert `·` prettier/prettier
64:35 error Insert `·` prettier/prettier
73:31 error Insert `·` prettier/prettier
85:40 error Insert `·` prettier/prettier
184:12 error Replace `⏎········isValid,⏎········credentials,⏎········response,⏎········errorMessage,` with `·isValid,·credentials,·response,·errorMessage·}·=` prettier/prettier
189:7 error Replace `}·=` with `·` prettier/prettier
324:36 error Insert `·` prettier/prettier
340:33 error Insert `·` prettier/prettier
371:28 error Insert `·` prettier/prettier
402:23 error Insert `·` prettier/prettier
410:20 error Replace `err` with `(err)` prettier/prettier
424:27 error Insert `·` prettier/prettier
✖ 14 problems (14 errors, 0 warnings)
14 errors and 0 warnings potentially fixable with the `--fix` option.
This is silly.
20:21 error Insert `·`
the line in question is: https://github.com/dwyl/hapi-auth-jwt2/blob/0cf2b34234d713157c453a1bedcffa8a63695cce/lib/index.js#L20
How does this line need a .
on it? 🤷♂️
Through a little investigation, 🔍
it turns out that the latest version of prettier
doesn't allow the function
keyword. 🤷♂️
Everything has to be =>
(arrow functions) ... 🤦♂️
Sooooo glad I don't write JS
anymore.
This is suuuuper lame! the function
keyword is perfectly fine!
why do the Küel Kids have to ruin perfectly working code?! 🤦♂️
:exclamation: No coverage uploaded for pull request base (
main@0cf2b34
). Click here to learn what that means. The diff coverage isn/a
.
@@ Coverage Diff @@
## main #375 +/- ##
========================================
Coverage ? 100.00%
========================================
Files ? 2
Lines ? 134
Branches ? 0
========================================
Hits ? 134
Misses ? 0
Partials ? 0
:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more
Much better:
@SimonLab please take a look and merge when you're back at your desk. Thanks. 🙏
This PR creates a new [maintenance] release for the package. 📦 To publish a version with the updated
jsonwebtoken
dependency https://github.com/dwyl/hapi-auth-jwt2/pull/374 ⬆️Changelog:
Sadly the deps badges are no longer working:
Removing from
README.md
✂️Also:
.travis.yml
with.github
(GitHub Actions/CI + @dependabot)prettier
+eslint
to latest and updates code inindex.js
fromfunction
to=>
... 🙄 https://github.com/dwyl/hapi-auth-jwt2/pull/375#issuecomment-1371859575README.md
badges frommaster
tomain