Spea / SpBowerBundle

Symfony2 Bundle to handle asset dependencies with bower
231 stars 44 forks source link

Broken if only js or css #64

Closed ivan1986 closed 10 years ago

ivan1986 commented 10 years ago

this commit b2579f38303a4fc76344a0d8dcd7d8b949f4fe17

do

Fatal error: Uncaught exception 'InvalidArgumentException' with message 'There is no "jquery_css" asset.' in /home/ivan/work/editor.my/vendor/kriswallsmith/assetic/src/Assetic/AssetManager.php:37 Stack trace: #0 /home/ivan/work/editor.my/vendor/kriswallsmith/assetic/src/Assetic/Factory/LazyAssetManager.php(180): Assetic\AssetManager->get('jquery_css') #1 /home/ivan/work/editor.my/vendor/kriswallsmith/assetic/src/Assetic/Asset/AssetReference.php(125): Assetic\Factory\LazyAssetManager->get('jquery_css') #2 /home/ivan/work/editor.my/vendor/kriswallsmith/assetic/src/Assetic/Asset/AssetReference.php(83): Assetic\Asset\AssetReference->callAsset('getSourcePath') #3 /home/ivan/work/editor.my/vendor/kriswallsmith/assetic/src/Assetic/Asset/Iterator/AssetCollectionIterator.php(66): Assetic\Asset\AssetReference->getSourcePath() #4 [internal function]: Assetic\Asset\Iterator\AssetCollectionIterator->current() #5 /home/ivan/work/editor.my/vendor/kriswallsmith/assetic/src/Assetic/Factory/AssetFactory.php(382): FilterIterator->rewind() # in /home/ivan/work/editor.my/vendor/symfony/symfony/src/Symfony/Component/Config/Loader/FileLoader.php on line 100

on start jquery_css not exist

daFish commented 10 years ago

The reason for this failure is that there is no Assetic package named @jquery_css. Before this patch packages where generated wether or not the files for the package existed.

You can check which packages exist by using sp:bower:list on the console.

ivan1986 commented 10 years ago

it adds by select2,

@angular_ui_select2_js
  @select2_js
  @jquery_js
  /home/ivan/work/editor.my/src/Irev/JsLibsBundle/Resources/public/components/angular-ui-select2/src/select2.js
@angular_ui_date_js
  @jquery_ui_js
  /home/ivan/work/editor.my/src/Irev/JsLibsBundle/Resources/public/components/angular-ui-date/src/date.js
@angular_ui_tinymce_js
  /home/ivan/work/editor.my/src/Irev/JsLibsBundle/Resources/public/components/angular-ui-tinymce/src/tinymce.js
@angular_resource_js
  /home/ivan/work/editor.my/src/Irev/JsLibsBundle/Resources/public/components/angular-resource/angular-resource.js
@select2_css
  @jquery_css
  /home/ivan/work/editor.my/src/Irev/JsLibsBundle/Resources/public/components/select2/select2.css
@select2_js
  @jquery_js
  /home/ivan/work/editor.my/src/Irev/JsLibsBundle/Resources/public/components/select2/select2.js
@jquery_ui_js
  @jquery_js
  /home/ivan/work/editor.my/src/Irev/JsLibsBundle/Resources/public/components/jquery-ui/ui/jquery-ui.js
@bootbox_js
  /home/ivan/work/editor.my/src/Irev/JsLibsBundle/Resources/public/components/bootbox/bootbox.js
@jquery_js
  /home/ivan/work/editor.my/src/Irev/JsLibsBundle/Resources/public/components/jquery/jquery.js

but jq not have css