Issue while building the site (react-intl issue?)

I need advice to debug deploy Netlify App

This error happens on the Netlify build but not on my local build (with gatsby build command) Have you ever experienced this issue?
see the partial log:

3:26:54 PM: failed Building static HTML for pages - 0.269s
3:26:54 PM: error Building static HTML failed
3:26:54 PM: 
3:26:54 PM:   434 |         var value = this.parseIdentifierIfPossible().value;
3:26:54 PM:   435 |         if (!value) {
3:26:54 PM: > 436 |             return this.error(ErrorKind.MALFORMED_ARGUMENT, createLocation(openingBracePosition, this.clonePosition()));
3:26:54 PM:       | ^
3:26:54 PM:   437 |         }
3:26:54 PM:   438 |         this.bumpSpace();
3:26:54 PM:   439 |         if (this.isEOF()) {
3:26:54 PM: 
3:26:54 PM:   WebpackError: /opt/build/repo/public/render-page.js:4603
3:26:54 PM:   
3:26:54 PM:   - parser.js:436 
3:26:54 PM:     [gatsby-starter-i18n-bulma]/[@formatjs]/icu-messageformat-parser/lib/parser.    js:436:1
3:26:54 PM:   
3:26:54 PM:   - parser.js:484 
3:26:54 PM:     [gatsby-starter-i18n-bulma]/[@formatjs]/icu-messageformat-parser/lib/parser.    js:484:1
3:26:54 PM:   
3:26:54 PM:   - parser.js:540 
3:26:54 PM:     [gatsby-starter-i18n-bulma]/[@formatjs]/icu-messageformat-parser/lib/parser.    js:540:1
3:26:54 PM:   
3:26:54 PM:   - parser.js:368 
3:26:54 PM:     [gatsby-starter-i18n-bulma]/[@formatjs]/icu-messageformat-parser/lib/parser.    js:368:1
3:26:54 PM:   
3:26:54 PM:   - parser.js:261 
3:26:54 PM:     [gatsby-starter-i18n-bulma]/[@formatjs]/icu-messageformat-parser/lib/parser.    js:261:1
3:26:54 PM:   
3:26:54 PM:   - parser.js:408 
3:26:54 PM:     [gatsby-starter-i18n-bulma]/[@formatjs]/icu-messageformat-parser/lib/parser.    js:408:1
3:26:54 PM:   
3:26:54 PM:   - extends.js:14 
3:26:54 PM:     [gatsby-starter-i18n-bulma]/[@babel]/runtime/helpers/extends.js:14:1
3:26:54 PM:   
3:26:54 PM:   - extends.js:2 
3:26:54 PM:     [gatsby-starter-i18n-bulma]/[@babel]/runtime/helpers/extends.js:2:1
3:26:54 PM:   
3:26:54 PM:   - utils.js:47 
3:26:54 PM:     [gatsby-starter-i18n-bulma]/[@formatjs]/ecma402-abstract/lib/utils.js:47:1
3:26:54 PM:   
3:26:54 PM:   - parser.js:258 
3:26:54 PM:     [gatsby-starter-i18n-bulma]/[@formatjs]/icu-messageformat-parser/lib/parser.    js:258:1
3:26:54 PM:   
3:26:54 PM:   - extends.js:13 
3:26:54 PM:     [gatsby-starter-i18n-bulma]/[@babel]/runtime/helpers/esm/extends.js:13:1
3:26:54 PM:   
3:26:54 PM: 
3:26:54 PM: ​
3:26:54 PM: ────────────────────────────────────────────────────────────────
3:26:54 PM:   "build.command" failed                                        
3:26:54 PM: ────────────────────────────────────────────────────────────────
3:26:54 PM: ​
3:26:54 PM:   Error message
3:26:54 PM:   Command failed with exit code 1: gatsby build
3:26:54 PM: ​
3:26:54 PM:   Error location
3:26:54 PM:   In Build command from Netlify app:
3:26:54 PM:   gatsby build
3:26:54 PM: ​
3:26:54 PM:   Resolved config
3:26:54 PM:   build:
3:26:54 PM:     command: gatsby build
3:26:54 PM:     commandOrigin: ui
3:26:54 PM:     environment:
3:26:54 PM:       - REVIEW_ID
3:26:54 PM:     publish: /opt/build/repo/public
3:26:54 PM:   functions:
3:26:54 PM:     '*': {}

I sorted out: i downgraded the react-intl, react-leaflet and leaflet packages and the issue disappeared. Probably cwas caused by some packages incompatibility, if you are experiencing this issue see my PR here Upgrading packges to version 3.6.0 (gatsbyjs) by kalwalt Β· Pull Request #146 Β· kalwalt/gatsby-starter-i18n-bulma Β· GitHub.

1 Like

Hey there, @kalwalt :wave:

Thanks for coming back and letting us know! This will be beneficial to future Forums members who encounter something similar.

1 Like

it’s a pleasure! I would undertstand why in my local machine all went fine but fails on Netlify. I suppose that is involved the node, npm and ubuntu version used, unfortunately i can’t test with the same environment.

1 Like