shopware / development

MIT License
189 stars 170 forks source link

Theme compile breaks with "Infinite calling loop error" if trying to compile more than 37 storefronts #174

Closed xUJYx closed 2 years ago

xUJYx commented 2 years ago

PHP Version

7.4.23

Shopware Version

dev v6.4.99

Expected behaviour

command psh storefront:build must compile theme for all sales channels

Actual behaviour

Theme compile process failes on 37th sales channel...

How to reproduce

Install dev or prod shopware. Add near 400 categories and 7000 products. Add more than 37 sales channels and connect 3000 products to each of them.

Try to call storefront:build and compile sales channels. Got error: ` SHOPWARE Developer Version Using .psh.yaml.dist Starting Execution of 'storefront:build' ('/app/dev-ops/storefront/actions/build.sh') (1/5) Starting

bin/console bundle:dump
[OK] Dumped plugin configuration.

(2/5) Starting

bin/console feature:dump
[OK] Successfully dumped js feature configuration

(3/5) Starting

PROJECT_ROOT=/app/ npm --prefix vendor/shopware/platform/src/Storefront/Resources/app/storefront/ run production

sw-next-storefront@1.0.0 production /app/vendor/shopware/platform/src/Storefront/Resources/app/storefront NODE_ENV=production webpack --config webpack.config.js

# Webpack Plugin Injector: Plugin "Storefront" injected as a new entry point
ℹ Compiling Shopware 6 Storefront
✔ Shopware 6 Storefront: Compiled successfully in 3.35s
   316 modules

(4/5) Starting

bin/console assets:install Copying files for bundle: FrameworkBundle Copying files for bundle: MonologBundle Copying files for bundle: SensioFrameworkExtraBundle Copying files for bundle: TwigBundle Copying files for bundle: WebProfilerBundle Copying files for bundle: DebugBundle Copying files for bundle: EnqueueBundle Copying files for bundle: EnqueueAdapterBundle Copying files for bundle: Framework Copying files for bundle: System Copying files for bundle: Content Copying files for bundle: Checkout Copying files for bundle: Profiling Copying files for bundle: Administration Copying files for bundle: Docs Copying files for bundle: Storefront Copying files for bundle: Elasticsearch Copying files for bundle: DevOps Copying files for bundle: Maintenance Copying files for bundle: JtImport Copying files for bundle: DbalKernelPluginLoader Copying files for bundle: Recovery

 [OK] Successfully copied all bundle files                                      

(5/5) Starting

bin/console theme:compile Start theme compilation

 Compiling theme for sales channel for : 0114a6ac5067ffeee286ecd8ed19cd87       

 ! [NOTE] Took 2.333116 seconds                                                 

 Compiling theme for sales channel for : 026bd7e1c7ba94bd0e4bb293ddcc3fd6       

 ! [NOTE] Took 2.165789 seconds                                                 

 Compiling theme for sales channel for : 0a4aefdafe144761b9560de939b7047b       

 ! [NOTE] Took 2.191153 seconds                                                 

 Compiling theme for sales channel for : 11632a454506459c88308280f1686999       

 ! [NOTE] Took 2.313023 seconds                                                 

 Compiling theme for sales channel for : 13e66bd17e53ebb6976582e362728d54       

 ! [NOTE] Took 2.450594 seconds                                                 

 Compiling theme for sales channel for : 16d1cd7edecf238c7bfed0cd53b550a0       

 ! [NOTE] Took 2.526401 seconds                                                 

 Compiling theme for sales channel for : 170d71207fa9a6440f4b3dfbbad19642       

 ! [NOTE] Took 2.555345 seconds                                                 

 Compiling theme for sales channel for : 190fc4dedceb65c18218e7ad21c4b57c       

 ! [NOTE] Took 2.698131 seconds                                                 

 Compiling theme for sales channel for : 1ae956329eb29fbe21a4b827c99d32eb       

 ! [NOTE] Took 3.163566 seconds                                                 

 Compiling theme for sales channel for : 2289eb2471f85cf70e6f945fa41ce421       

 ! [NOTE] Took 3.217660 seconds                                                 

 Compiling theme for sales channel for : 2714c7d258e4d059c86a3a8a50179d69       

 ! [NOTE] Took 3.324252 seconds                                                 

 Compiling theme for sales channel for : 2e1fe664cb1e232b55ab10272e8b358a       

 ! [NOTE] Took 4.048226 seconds                                                 

 Compiling theme for sales channel for : 32225bb93c1866ccd0023dfbdacc05db       

 ! [NOTE] Took 3.956323 seconds                                                 

 Compiling theme for sales channel for : 33752d05083b0a2bae89a51eaba7f78d       

 ! [NOTE] Took 4.013856 seconds                                                 

 Compiling theme for sales channel for : 352fabdd5d79a043eb4b6d1d63063a4e       

 ! [NOTE] Took 4.131177 seconds                                                 

 Compiling theme for sales channel for : 37486bdd326721c1ce41a4b1962fbbaa       

 ! [NOTE] Took 4.005650 seconds                                                 

 Compiling theme for sales channel for : 381e9686736a9a143244d20233aab29e       

 ! [NOTE] Took 4.124306 seconds                                                 

 Compiling theme for sales channel for : 3da4c0e39fdb2b6fe30aebb36eb0a099       

 ! [NOTE] Took 4.747286 seconds                                                 

 Compiling theme for sales channel for : 4106bc5c2154c8393183542179bfe458       

 ! [NOTE] Took 4.878915 seconds                                                 

 Compiling theme for sales channel for : 4bac9d9e9a06b8f6832c210bb841dd94       

 ! [NOTE] Took 4.183759 seconds                                                 

 Compiling theme for sales channel for : 50943b24a0f5056d39a99b3269506772       

 ! [NOTE] Took 4.617169 seconds                                                 

 Compiling theme for sales channel for : 50bb0ae6e3bf5286852a87b4e4c1470f       

 ! [NOTE] Took 5.241166 seconds                                                 

 Compiling theme for sales channel for : 58ba02d297dc36594bcc4a793ac35a81       

 ! [NOTE] Took 5.491763 seconds                                                 

 Compiling theme for sales channel for : 5d5001e291674a22172723adbffe2a5c       

 ! [NOTE] Took 5.590078 seconds                                                 

 Compiling theme for sales channel for : 5d8c0fead883cb079034962787f08084       

 ! [NOTE] Took 5.535138 seconds                                                 

 Compiling theme for sales channel for : 617397c216b78b46b33b592997b11681       

 ! [NOTE] Took 5.833657 seconds                                                 

 Compiling theme for sales channel for : 66f66ba059788a83722f5ae0c6266e57       

 ! [NOTE] Took 5.855065 seconds                                                 

 Compiling theme for sales channel for : 6776bd4a4dcefe8d8de4649c2013c1d5       

 ! [NOTE] Took 6.016958 seconds                                                 

 Compiling theme for sales channel for : 6874e1ab8110499a3ff1c98acd6ba1d3       

 ! [NOTE] Took 5.891735 seconds                                                 

 Compiling theme for sales channel for : 73e0dbf2a15f493ec64e9cd0664e6410       

 ! [NOTE] Took 6.292474 seconds                                                 

 Compiling theme for sales channel for : 75930b3e71b37f38da98fd212a19dcf8       

 ! [NOTE] Took 6.446489 seconds                                                 

 Compiling theme for sales channel for : 75ab655bdcb29aa978efd92a81b44ba5       

 ! [NOTE] Took 6.500488 seconds                                                 

 Compiling theme for sales channel for : 7689b7929e83587a023465ed1896e336       

 ! [NOTE] Took 7.060267 seconds                                                 

 Compiling theme for sales channel for : 7929c2e75bc6c67e66ccd96ef0e3e202       

 ! [NOTE] Took 6.697981 seconds                                                 

 Compiling theme for sales channel for : 7a03f202dcdcfd1c1b91cdb9d264e642       

 ! [NOTE] Took 7.044630 seconds                                                 

 Compiling theme for sales channel for : 7a164ed49cdd262530adb82b4f5b789e       

 ! [NOTE] Took 7.150504 seconds                                                 

 Compiling theme for sales channel for : 7c28711eee5f735c717bb005e1815896       

In ThemeCompiler.php line 201:

  Unable to compile the theme "Storefront". Infinite calling loop: /app/platf  
  orm/src/Storefront/Resources/app/storefront/vendor/bootstrap/scss/utilities  
  /_float.scss on line 7, at column 53                                         
  Call Stack:                                                                  
  #0 function breakpoint-min /app/platform/src/Storefront/Resources/app/store  
  front/vendor/bootstrap/scss/mixins/_breakpoints.scss on line 53              
  #1 function breakpoint-infix /app/platform/src/Storefront/Resources/app/sto  
  refront/vendor/bootstrap/scss/utilities/_float.scss on line 5                
  #2 function breakpoint-min /app/platform/src/Storefront/Resources/app/store  
  front/vendor/bootstrap/scss/mixins/_breakpoints.scss on line 59              
  #3 mixin media-breakpoint-up /app/platform/src/Storefront/Resources/app/sto  
  refront/vendor/bootstrap/scss/utilities/_float.scss on line 10               
  #4 function breakpoint-min /app/platform/src/Storefront/Resources/app/store  
  front/vendor/bootstrap/scss/mixins/_breakpoints.scss on line 59              
  #5 mixin media-breakpoint-up /app/platform/src/Storefront/Resources/app/sto  
  refront/vendor/bootstrap/scss/utilities/_float.scss on line 10               

      ~~~MANY OF SAME TYPE OF ERROR~~~

  #12892 function theme-color /app/platform/src/Storefront/Resources/app/stor  
  efront/vendor/bootstrap/scss/_variables.scss on line 535                     
  #12893 function theme-color /app/platform/src/Storefront/Resources/app/stor  
  efront/vendor/bootstrap/scss/_variables.scss on line 246                     
  #12894 function theme-color /app/platform/src/Storefront/Resources/app/stor  
  efront/vendor/bootstrap/scss/_variables.scss on line 172                                                                      

theme:compile [-k|--keep-assets]

Execution aborted, a subcommand failed!

xUJYx commented 2 years ago

To fix this behavior you need to move lines 68-73 into compileTheme method inside Storefront/Theme/ThemeCompiler.php

https://github.com/shopware/platform/issues/2338#issuecomment-1044703399