Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Grammar Identifier error after update to v0.8 #453

Closed
kyle9292 opened this issue Oct 17, 2017 · 3 comments
Closed

Grammar Identifier error after update to v0.8 #453

kyle9292 opened this issue Oct 17, 2017 · 3 comments
Assignees
Labels

Comments

@kyle9292
Copy link

I just tried to update sip.js from 0.7.8 to 0.8.1 using npm in my Ionic3/Angular4 project and I get this error.

Uncaught Error: Module parse failed: C:\xxxxxx\node_modules\sip.js\src\Grammar\src\Grammar.pegjs Identifier directly after number (14:14)
You may need an appropriate loader to handle this file type.
| DIGIT = [0-9]
| ALPHA = [a-zA-Z]
| HEXDIG = [0-9a-fA-F]
| WSP = SP / HTAB
| OCTET = [\u0000-\u00FF]

Uninstall/reinstall yields same result. Knock it back down to 0.7.8 and it works just fine. The same grammar file that won't parse is in both versions so I'm not sure where to go from here.

Any help is appreciated.

@james-criscuolo
Copy link
Collaborator

The problem is that webpack is attempting to build within the sip.js folder, which is unnecessary. I can look into making sure that doesn't happen (it shouldn't), but in the meantime you should be able to add a line within your js loader in your webpack config, like:

test: /\.js$/,
exclude: /node_modules\/sip.js/,

Which should prevent webpack from attempting to build within the folder. I'll take a look at this tomorrow, I would expect it is a small change to our package.json, but we'll see.

@james-criscuolo
Copy link
Collaborator

I was able to replicate and then fix by changing main in package.json. We'll get this in the next release, which should occur at the latest next week. I'll close the issue when that releases.

@egreenmachine
Copy link
Collaborator

We have released 0.8.3 which addresses this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants