SyntaxError: (RegexpError) incompatible character encoding: /\u0085/
Hi Ruby plugin team,We are getting an exception when we run an rspec test in IntelliJ. It is rather inconsistent and not isolated to one test. We run the spec and the error occurs, we comment out the spec and it still occurs but when we comment out a bunch of specs it doesn't occur.We do not get this error at all when we run rspect from the command line.Is this a known bug? Our files are stored in perforce as UTF8..../Users/dheath/.rvm/rubies/jruby-1.6.4/bin/jruby -J-cp /Users/dheath/Workspace/WEB__dheath__comments/_INTEGRATION_/comments/out/production/comments --1.9 -e $stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift) /Users/dheath/.rvm/gems/jruby-1.6.4@comments/bin/rspec /Users/dheath/Workspace/WEB__dheath__comments/_INTEGRATION_/comments/spec/controllers/comments_controller_spec.rb --require teamcity/spec/runner/formatter/teamcity/formatter --format Spec::Runner::Formatter::TeamcityFormatter --example CommentsController#createTesting started at 3:38 PM ...SyntaxError: (RegexpError) incompatible character encoding: /\u0085/replace_escaped_symbols at /Users/dheath/Library/Application Support/IntelliJIdea10/ruby/rb/testing/patch/common/teamcity/utils/service_message_factory.rb:192create_message at /Users/dheath/Library/Application Support/IntelliJIdea10/ruby/rb/testing/patch/common/teamcity/utils/service_message_factory.rb:235each at org/jruby/RubyHash.java:1175map at org/jruby/RubyEnumerable.java:729create_message at /Users/dheath/Library/Application Support/IntelliJIdea10/ruby/rb/testing/patch/common/teamcity/utils/service_message_factory.rb:235create_suite_finished at /Users/dheath/Library/Application Support/IntelliJIdea10/ruby/rb/testing/patch/common/teamcity/utils/service_message_factory.rb:59close_example_group at /Users/dheath/Library/Application Support/IntelliJIdea10/ruby/rb/testing/patch/bdd/teamcity/spec/runner/formatter/teamcity/formatter.rb:526dump_summary at /Users/dheath/Library/Application Support/IntelliJIdea10/ruby/rb/testing/patch/bdd/teamcity/spec/runner/formatter/teamcity/formatter.rb:376__send__ at org/jruby/RubyBasicObject.java:1712send at org/jruby/RubyKernel.java:2125notify at /Users/dheath/.rvm/gems/jruby-1.6.4@comments/gems/rspec-core-2.6.4/lib/rspec/core/reporter.rb:75each at org/jruby/RubyArray.java:1603notify at /Users/dheath/.rvm/gems/jruby-1.6.4@comments/gems/rspec-core-2.6.4/lib/rspec/core/reporter.rb:74finish at /Users/dheath/.rvm/gems/jruby-1.6.4@comments/gems/rspec-core-2.6.4/lib/rspec/core/reporter.rb:24report at /Users/dheath/.rvm/gems/jruby-1.6.4@comments/gems/rspec-core-2.6.4/lib/rspec/core/reporter.rb:14run at /Users/dheath/.rvm/gems/jruby-1.6.4@comments/gems/rspec-core-2.6.4/lib/rspec/core/command_line.rb:21run_in_process at /Users/dheath/.rvm/gems/jruby-1.6.4@comments/gems/rspec-core-2.6.4/lib/rspec/core/runner.rb:80run at /Users/dheath/.rvm/gems/jruby-1.6.4@comments/gems/rspec-core-2.6.4/lib/rspec/core/runner.rb:69autorun at /Users/dheath/.rvm/gems/jruby-1.6.4@comments/gems/rspec-core-2.6.4/lib/rspec/core/runner.rb:11Process finished with exit code 1
请先登录再写评论。
I had this problem too with JRuby 1.6.4 and language level 1.9.
Fixed it by patching ruby plugin.
# encoding: UTF-8
in file
~\.IntelliJIdea10\config\plugins\ruby\rb\testing\patch\common\teamcity\utils\service_message_factory.rb
add first line, saying
# encoding: UTF-8
Jetbrains guys, please fix it in upstream.