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

Building Clay on Windows is not possible #1056

Closed
antonio-ortega opened this issue Jul 16, 2018 · 4 comments
Closed

Building Clay on Windows is not possible #1056

antonio-ortega opened this issue Jul 16, 2018 · 4 comments
Labels
2.x comp: infrastructure They are used in problems that are related to monorepo infrastructure, build, process automation... type: bug Issues reporting that Component is not doing what should be done

Comments

@antonio-ortega
Copy link
Member

After cloning the repo and following the steps in README, once I executed npm run build I got this error:

lerna ERR! npm ERR! code ELIFECYCLE
lerna ERR! npm ERR! errno 255
lerna ERR! npm ERR! [email protected] soy: metalsoy --soyDeps '../../node_modules/clay-+(button|checkbox|icon|link|portal|radio)/src/**/*.soy'
lerna ERR! npm ERR! Exit status 255
lerna ERR! npm ERR!
lerna ERR! npm ERR! Failed at the [email protected] soy script.
lerna ERR! npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

This issue is happening on Windows.

@jbalsas
Copy link
Contributor

jbalsas commented Jul 16, 2018

Thanks for reporting, @antonio-ortega! I think this is caused by the ' glob expansion not working properly on windows... @izaera, haven't we encountered similar issues in the past?

@izaera
Copy link
Member

izaera commented Jul 16, 2018

Yes. And we had to move the arguments to a config file because the escaping is different for Windows and Unix shells.

Another way to bypass it is to create a node script that properly calls metalsoy (so that it can circumvent the shell).

@matuzalemsteles matuzalemsteles added comp: infrastructure They are used in problems that are related to monorepo infrastructure, build, process automation... type: bug Issues reporting that Component is not doing what should be done labels Nov 23, 2018
This was referenced Nov 23, 2018
@matuzalemsteles matuzalemsteles pinned this issue Jan 18, 2019
@marcoscv-work marcoscv-work unpinned this issue Mar 18, 2019
@jbalsas
Copy link
Contributor

jbalsas commented Feb 3, 2020

Closing due to inactivity and 2.x being in maintenance. We can reopen if needed or if still broken :/

@jbalsas jbalsas closed this as completed Feb 3, 2020
@georgel-pop-lr
Copy link
Member

georgel-pop-lr commented Feb 25, 2020

Hi,

I did check 'yarn build' on Windows in master and it works properly, but the scripts are very different than 2.x

Then I moved to 2.x branch and first I encounter these two build issues:

  1. packages/clay-autocomplete/package.json
  2. packages/clay-dropdown/package.json
    these two files have duplicated dependencies of "metal-dom": "^2.16.0", and another one in dev dependencies "metal-dom": "^2.13.2", I added same versions for both, but I think it can be removed from dev dependencies.

After doing this I got the issue described in this ticket, the problem seems to be how this regular expression is being interpreted 'clay-+(data-provider|portal|loading-indicator)', I checked this regular expression and looks fine, is matching 'clay-data-provider', 'clay-portal' and 'clay-loading-indicator'. Not really sure what can be the problem on windows.

Here you have the full error text:
` Asset Size Chunks Chunk Names
./build/globals/clay-select.js 624 kB 0 [emitted] [big] main
./build/globals/clay-select.js.map 749 kB 0 [emitted] main
[6] (webpack)/buildin/global.js 509 bytes {0} [built]
[27] ./src/ClaySelect.js 4.49 kB {0} [built]
[28] ../clay-component/src/ClayComponent.js 8.39 kB {0} [built]
[66] ./src/ClaySelect.soy.js 10.6 kB {0} [built]
+ 63 hidden modules
lerna ERR! yarn run build exited 255 in 'clay-autocomplete'
lerna ERR! yarn run build stdout:
$ npm run soy && webpack

[email protected] soy C:\liferay\repos\clay\packages\clay-autocomplete
metalsoy --soyDeps '../../node_modules/clay-+(data-provider|portal|loading-indicator)/src/**/*.soy'

info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

lerna ERR! yarn run build stderr:
'portal' is not recognized as an internal or external command,
operable program or batch file.
npm ERR! code ELIFECYCLE
npm ERR! errno 255
npm ERR! [email protected] soy: metalsoy --soyDeps '../../node_modules/clay-+(data-provider|portal|loading-indicator)/src/**/*.soy'
npm ERR! Exit status 255
npm ERR!
npm ERR! Failed at the [email protected] soy 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! C:\Users\Georgel Vasile\AppData\Roaming\npm-cache_logs\2020-02-25T12_30_50_489Z-debug.log
error Command failed with exit code 255.

lerna ERR! yarn run build exited 255 in 'clay-autocomplete'
lerna WARN complete Waiting for 3 child processes to exit. CTRL-C to exit immediately.
error Command failed with exit code 255.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2.x comp: infrastructure They are used in problems that are related to monorepo infrastructure, build, process automation... type: bug Issues reporting that Component is not doing what should be done
Projects
None yet
Development

No branches or pull requests

5 participants