Problem with elm-upgrade upgrading from 0.18 to 0.19

I’m trying to bite the bullet and upgrade my largest elm project from 0.18 to 0.19. As I have a number of other projects, my inclination is to leave 0.18 installed globally for now (on Mac OS), and install 0.19 locally in the project to be upgraded. I’m following the elm-upgrade instructions which advises to install version 19 of elm and elm-format locally

cd path/to/my/elm/project
npm install elm@latest-0.19.1  
npm install elm-format@latest-0.19.1

These two installed locally without issue.

From my project folder, I can see the global version is still in my path (from /usr/local/bin)

$ elm --version
0.18.0

… and 0.19 is installed in ./node_modules/.bin

$ npx elm --version
0.19.1

Then it instructs to invoke the upgrade with

cd path/to/my/elm/project
npx elm-upgrade@latest

However, I’m getting this error:

$ npx elm-upgrade@latest
npx: installed 59 in 5.175s
Unexpected token *

Does anyone have any ideas what might be wrong? TIA

After digging in a little, it appears that the problem was due to the version of node I had installed (v8.11.3). I upgraded to v14.15.3 and the problem no longer occurs. Incidentally, I did get more information about the error message by installing elm-upgrade temporarily and invoking it without npx. It was erroring out parsing the asterisk in front of a generator function.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.