错误:要导入的文件未找到或不可读:断点

时间:2021-05-25 09:15:15

I can't seem to get Breakpoint to load successfully.

我似乎无法成功加载Breakpoint。

  • I have added @import "breakpoint";
  • 我添加了@import“breakpoint”;
  • I have added require 'breakpoint'
  • 我添加了require'breakpoint'

The error log in terminal shows:

终端中的错误日志显示:

Running "compass:dev" (compass) task
    error _/components/sass/styles.scss (Line 4: File to import not found or unreadable: breakpoint.
Load paths:
  Compass::SpriteImporter
  /Users/i835059/Desktop/sassycompass/_/components/sass
  /Library/Ruby/Gems/2.0.0/gems/compass-core-1.0.1/stylesheets
  /Library/Ruby/Gems/2.0.0/gems/susy-2.1.3/sass)
Compilation failed in 1 files.

The error log posted in my css file is as follows:

我的css文件中发布的错误日志如下:

Error: File to import not found or unreadable: breakpoint.
   Load paths:
     Compass::SpriteImporter
     /Users/i835059/Desktop/sassycompass/_/components/sass
     /Library/Ruby/Gems/2.0.0/gems/compass-core-1.0.1/stylesheets
     /Library/Ruby/Gems/2.0.0/gems/susy-2.1.3/sass
    on line 4 of /Users/i835059/Desktop/sassycompass/_/components/sass/styles.scss

1: @import "compass";
2: @import "compass/reset";
3: @import "susy";
4: @import "breakpoint";
5: 
6: @import "variables";
7: @import "mixins";
8: @import "base";
9: @import "layout";

Backtrace:
/Users/i835059/Desktop/sassycompass/_/components/sass/styles.scss:4
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/import_node.rb:66:in `rescue in     import'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/import_node.rb:45:in `import'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/import_node.rb:28:in  `imported_file'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/import_node.rb:37:in `css_import?'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/visitors/perform.rb:294:in `visit_import'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/visitors/base.rb:36:in `visit'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/visitors/perform.rb:152:in `block in visit'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/stack.rb:79:in `block in with_base'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/stack.rb:115:in `with_frame'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/stack.rb:79:in `with_base'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/visitors/perform.rb:152:in  `visit'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/visitors/base.rb:52:in `block in visit_children'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/visitors/base.rb:52:in `map'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/visitors/base.rb:52:in `visit_children'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/visitors/perform.rb:161:in `block in visit_children'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/visitors/perform.rb:173:in `with_environment'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/visitors/perform.rb:160:in `visit_children'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/visitors/base.rb:36:in `block in visit'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/visitors/perform.rb:180:in `visit_root'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/visitors/base.rb:36:in `visit'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/visitors/perform.rb:151:in `visit'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/visitors/perform.rb:8:in `visit'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/root_node.rb:36:in `css_tree'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/tree/root_node.rb:20:in `render'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/engine.rb:268:in `render'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/plugin/compiler.rb:486:in `update_stylesheet'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/plugin/compiler.rb:214:in `block in update_stylesheets'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/plugin/compiler.rb:208:in `each'
/Library/Ruby/Gems/2.0.0/gems/sass-3.4.0/lib/sass/plugin/compiler.rb:208:in `update_stylesheets'
/Library/Ruby/Gems/2.0.0/gems/compass-1.0.1/lib/compass/sass_compiler.rb:40:in `compile!'
/Library/Ruby/Gems/2.0.0/gems/compass-1.0.1/lib/compass/commands/update_project.rb:49:in `perform'
/Library/Ruby/Gems/2.0.0/gems/compass-1.0.1/lib/compass/commands/base.rb:18:in `execute'
/Library/Ruby/Gems/2.0.0/gems/compass-1.0.1/lib/compass/commands/project_base.rb:19:in `execute'
/Library/Ruby/Gems/2.0.0/gems/compass-1.0.1/lib/compass/exec/sub_command_ui.rb:43:in `perform!'
/Library/Ruby/Gems/2.0.0/gems/compass-1.0.1/lib/compass/exec/sub_command_ui.rb:15:in `run!'
/Library/Ruby/Gems/2.0.0/gems/compass-1.0.1/bin/compass:30:in `block in <top (required)>'
/Library/Ruby/Gems/2.0.0/gems/compass-1.0.1/bin/compass:44:in `call'
/Library/Ruby/Gems/2.0.0/gems/compass-1.0.1/bin/compass:44:in `<top (required)>'
/usr/bin/compass:23:in `load'
/usr/bin/compass:23:in `<main>'

3 个解决方案

#1


2  

I was able to get around this issue by running:

我能够通过运行来解决这个问题:

bundle clean --force


bundle install

Not sure where the gems were broken and it says be careful running bundle clean, but worked for me!

不确定宝石在哪里被打破,它说要小心运行捆绑清洁,但为我工作!

#2


1  

I got the same problem so I just created an omega 4 sub-theme

我遇到了同样的问题所以我刚刚创建了一个欧米茄4子主题

I thought that there was some bad update for some gems, so I copied all the gemfiles in the omega theme into my sub-theme.

我认为某些宝石有一些不好的更新,所以我将omega主题中的所有gemfiles复制到我的子主题中。

Run from within the sub-theme :

从子主题内运行:

bundle install

then:

然后:

bundle exec guard 

And everything is alright now

现在一切都好了

#3


0  

You should check do you really have "breakpoint" gem on your computer.
Type this in your termial and try to find "breakpoint":

您应该检查您的计算机上是否真的有“断点”宝石。在您的期刊中键入此内容并尝试查找“断点”:

gem list --local

If there is no this gem, you should install:

如果没有这个gem,你应该安装:

gem install breakpoint

There is another way to use breakpoint in your project, in documentation you can find this:

还有另一种在项目中使用断点的方法,在文档中你可以找到:

#it no longer has any Ruby requirements and can be run as a Sass package

So you can download source of breakpoint via Bower or directly from Github and @import in your stylesheet as simple *.scss file

所以你可以通过Bower直接下载断点源,或者直接从你的样式表中的Github和@import下载简单的* .scss文件

#1


2  

I was able to get around this issue by running:

我能够通过运行来解决这个问题:

bundle clean --force


bundle install

Not sure where the gems were broken and it says be careful running bundle clean, but worked for me!

不确定宝石在哪里被打破,它说要小心运行捆绑清洁,但为我工作!

#2


1  

I got the same problem so I just created an omega 4 sub-theme

我遇到了同样的问题所以我刚刚创建了一个欧米茄4子主题

I thought that there was some bad update for some gems, so I copied all the gemfiles in the omega theme into my sub-theme.

我认为某些宝石有一些不好的更新,所以我将omega主题中的所有gemfiles复制到我的子主题中。

Run from within the sub-theme :

从子主题内运行:

bundle install

then:

然后:

bundle exec guard 

And everything is alright now

现在一切都好了

#3


0  

You should check do you really have "breakpoint" gem on your computer.
Type this in your termial and try to find "breakpoint":

您应该检查您的计算机上是否真的有“断点”宝石。在您的期刊中键入此内容并尝试查找“断点”:

gem list --local

If there is no this gem, you should install:

如果没有这个gem,你应该安装:

gem install breakpoint

There is another way to use breakpoint in your project, in documentation you can find this:

还有另一种在项目中使用断点的方法,在文档中你可以找到:

#it no longer has any Ruby requirements and can be run as a Sass package

So you can download source of breakpoint via Bower or directly from Github and @import in your stylesheet as simple *.scss file

所以你可以通过Bower直接下载断点源,或者直接从你的样式表中的Github和@import下载简单的* .scss文件