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

Production build is not working on fresh project #2

Closed
Nicceboy opened this issue Mar 10, 2019 · 7 comments · Fixed by #16
Closed

Production build is not working on fresh project #2

Nicceboy opened this issue Mar 10, 2019 · 7 comments · Fixed by #16
Labels
bug Something isn't working

Comments

@Nicceboy
Copy link

Expected Behavior

I'm trying to compile production build and I except it work from scratch. It has been done for fresh clone from the repository.
However, it ends into error.

Current Behavior

After cloning, I install node modules and try to run production build, it ends into error:

Lexical error on line 1: Unrecognized text.
  Erroneous area:
1: 100% - auto - 1
^.........^

I figured out that this might be related to CSS function calc(), where 'auto' might not be usable. However, even after modifying or removing those CSS parts what I was able to find, error still appeared.

Failure Information (for bugs)

Following error messages appear:

nicce@workstation ~/D/blk-design-system-react> npm run build

> blk-design-system-react@1.0.0 build /home/nicce/Documents/blk-design-system-react
> react-scripts build

Creating an optimized production build...
Failed to compile.

Lexical error on line 1: Unrecognized text.
  Erroneous area:
1: 100% - auto - 1
^.........^

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! blk-design-system-react@1.0.0 build: `react-scripts build`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the blk-design-system-react@1.0.0 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/nicce/.npm/_logs/2019-03-10T23_34_16_078Z-debug.log

Steps to Reproduce

  1. Clone repository
  2. Install modules npm install
  3. Build for production npm run build

Context

  • npm version: 6.9.0
  • nodejs version: v10.15.3
  • Operating System: Arch Linux - kernel 5.0.0-arch1-1-ARCH

Failure Logs

Content of log file:

nicce@workstation ~/D/blk-design-system-react> cat /home/nicce/.npm/_logs/2019-03-10T23_34_16_078Z-debug.log
                                               
0 info it worked if it ends with ok
1 verbose cli [ '/usr/bin/node', '/usr/bin/npm', 'run', 'build' ]
2 info using npm@6.9.0
3 info using node@v10.15.3
4 verbose run-script [ 'prebuild', 'build', 'postbuild' ]
5 info lifecycle blk-design-system-react@1.0.0~prebuild: blk-design-system-react@1.0.0
6 info lifecycle blk-design-system-react@1.0.0~build: blk-design-system-react@1.0.0
7 verbose lifecycle blk-design-system-react@1.0.0~build: unsafe-perm in lifecycle true
8 verbose lifecycle blk-design-system-react@1.0.0~build: PATH: /usr/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/home/nicce/Documents/blk-design-system-react/node_modules/.bin:/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/lib/jvm/default/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl:/var/lib/snapd/snap/bin
9 verbose lifecycle blk-design-system-react@1.0.0~build: CWD: /home/nicce/Documents/blk-design-system-react
10 silly lifecycle blk-design-system-react@1.0.0~build: Args: [ '-c', 'react-scripts build' ]
11 silly lifecycle blk-design-system-react@1.0.0~build: Returned: code: 1  signal: null
12 info lifecycle blk-design-system-react@1.0.0~build: Failed to exec build script
13 verbose stack Error: blk-design-system-react@1.0.0 build: `react-scripts build`
13 verbose stack Exit status 1
13 verbose stack     at EventEmitter.<anonymous> (/usr/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:301:16)
13 verbose stack     at EventEmitter.emit (events.js:189:13)
13 verbose stack     at ChildProcess.<anonymous> (/usr/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack     at ChildProcess.emit (events.js:189:13)
13 verbose stack     at maybeClose (internal/child_process.js:970:16)
13 verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:259:5)
14 verbose pkgid blk-design-system-react@1.0.0
15 verbose cwd /home/nicce/Documents/blk-design-system-react
16 verbose Linux 5.0.0-arch1-1-ARCH
17 verbose argv "/usr/bin/node" "/usr/bin/npm" "run" "build"
18 verbose node v10.15.3
19 verbose npm  v6.9.0
20 error code ELIFECYCLE
21 error errno 1
22 error blk-design-system-react@1.0.0 build: `react-scripts build`
22 error Exit status 1
23 error Failed at the blk-design-system-react@1.0.0 build script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]

@einazare einazare added the bug Something isn't working label Mar 11, 2019
@einazare
Copy link
Contributor

Hello there @Nicceboy ,

Thank you for your interest in working with our products.
Please go inside src/assets/scss/blk-design-system-react/custom/_icons.scss and delete the following lines:

  • width: calc(100% - $icon-size-sm - 1);
  • width: calc(100% - $icon-size-lg - 1);
  • width: calc(100% - $icon-size-xl - 1);
  • width: calc(100% - #{$icon-size} - 1);

Hope this helps.

Best,
Manu

@Nicceboy
Copy link
Author

Hello there @Nicceboy ,

Thank you for your interest in working with our products.
Please go inside src/assets/scss/blk-design-system-react/custom/_icons.scss and delete the following lines:

* `width: calc(100% - $icon-size-sm - 1);`

* `width: calc(100% - $icon-size-lg - 1);`

* `width: calc(100% - $icon-size-xl - 1);`

* `width: calc(100% - #{$icon-size} - 1);`

Hope this helps.

Best,
Manu

Thank you. Removal of these fixed it.

Creating an optimized production build...
Compiled successfully.

dhernandez pushed a commit to siames-social/siames.social that referenced this issue Apr 21, 2019
tylim88 added a commit to zero-to-mastery/GameSenshi that referenced this issue May 10, 2019
@fachrezamuslim
Copy link

@einazare thank you, its work for me too

@frknasir
Copy link

  • width: calc(100% - $icon-size-sm - 1);

this did it for me...thank you

@Mottoweb
Copy link

Worked thanks, but this isn't merged?

@einazare
Copy link
Contributor

Hello there, @Mottoweb ,

At the moment it is not merged.
I'll see if I can update the product by the end of this year.

Best,
Manu

einazare added a commit that referenced this issue Mar 13, 2020
Closes #8
Closes #7
Closes #5
Closes #4
Closes #2
Closes #1
This was referenced Apr 10, 2020
@Shakil97
Copy link

Thank you so much. it's working perfectly after build.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants