Encoding Compatibility Error
Closed this issue · 7 comments
I'm trying to build the final report, but I got this error:
$bundle exec report_builder -s "${SAVE_PATH}" -o "${SAVE_PATH}/final_report_`$ts`"
Encoding::CompatibilityError: incompatible character encodings: UTF-8 and ASCII-8BIT
(erb):169:in `concat'
(erb):169:in `block (5 levels) in build_report'
(erb):166:in `each'
(erb):166:in `block (4 levels) in build_report'
(erb):153:in `each'
(erb):153:in `block (3 levels) in build_report'
(erb):22:in `each'
(erb):22:in `each_with_index'
(erb):22:in `block (2 levels) in build_report'
(erb):21:in `each'
(erb):21:in `each_with_index'
(erb):21:in `block in build_report'
/usr/local/lib/ruby/2.4.0/erb.rb:896:in `eval'
/usr/local/lib/ruby/2.4.0/erb.rb:896:in `result'
/usr/local/bundle/gems/report_builder-1.2/lib/report_builder/builder.rb:33:in `block in build_report'
/usr/local/bundle/gems/report_builder-1.2/lib/report_builder/builder.rb:32:in `open'
/usr/local/bundle/gems/report_builder-1.2/lib/report_builder/builder.rb:32:in `build_report'
/usr/local/bundle/gems/report_builder-1.2/lib/report_builder.rb:45:in `build_report'
/usr/local/bundle/gems/report_builder-1.2/bin/report_builder:73:in `<top (required)>'
/usr/local/bundle/bin/report_builder:23:in `load'
/usr/local/bundle/bin/report_builder:23:in `<top (required)>'
bundler: failed to load command: report_builder (/usr/local/bundle/bin/report_builder)
@khaylova can you please provide a JSON report for which you are getting this error.
Hi @rajatthareja. It's a bunch of json's files. But for example
@khaylova I am able to generate the HTML report for https://drive.google.com/open?id=1VfAzeTgYDDFkmD-JctDOvTzPoetSTAQj
Please try to find the JSON file for which error is comming or share all files so that I can reproduce error.
@rajatthareja I still have problems with the files marked with the underlines: https://drive.google.com/open?id=1kVih0Aevdtv5wSFPpLMEpwE6tXUGjQFE
@khaylova Issue is fixed.
Note: Gem not released yet. You can install it from github https://bundler.io/guides/git.html
Fix available in v1.7
@rajatthareja I'm getting the same error Encoding::CompatibilityError: incompatible character encodings: UTF-8 and ASCII-8BIT
The gem version: '~> 1.8'
I'm running the following rake task:
task :generate_report do
ReportBuilder.configure do |config|
config.input_path = 'reports/cucumber.json'
config.report_path = 'reports/report'
config.report_types = [:retry, :html]
config.include_images = true
end
ReportBuilder.build_report
end
please let me know if you need more details