Skip to content

Getting "Error: ENAMETOOLONG: name too long" when processing captured json, also 404 for some report html #11

@plermant

Description

@plermant

Hi Sam, a couple of thing i wanted to report:

  1. I am getting this Error when processing the report html (I attach the info in ZIP):
    jsCoveragePierre.zip
plermant@ubuntu:/mnt/hgfs/desktopBin/coverage-ext-master/reporter$ nodejs gen_report.js jsCoverage.txt
Write asset: /mnt/hgfs/desktopBin/coverage-ext-master/reporter/html-report/base.css
Write asset: /mnt/hgfs/desktopBin/coverage-ext-master/reporter/html-report/sort-arrow-sprite.png
Write asset: /mnt/hgfs/desktopBin/coverage-ext-master/reporter/html-report/sorter.js
Write asset: /mnt/hgfs/desktopBin/coverage-ext-master/reporter/html-report/prettify.css
Write asset: /mnt/hgfs/desktopBin/coverage-ext-master/reporter/html-report/prettify.js
Writing /mnt/hgfs/desktopBin/coverage-ext-master/reporter/html-report/index.html
Writing /mnt/hgfs/desktopBin/coverage-ext-master/reporter/html-report/__root__/index.html
Writing /mnt/hgfs/desktopBin/coverage-ext-master/reporter/html-report/__root__/http---ajax-googleapis-com-ajax-libs-jquery-1-8-2-jquery-min-js---0.1150.html
Writing /mnt/hgfs/desktopBin/coverage-ext-master/reporter/html-report/__root__/http---api-atg-kohls-com-update-ede-assets-js-ede-wrapper-js---0.5320.html
Writing /mnt/hgfs/desktopBin/coverage-ext-master/reporter/html-report/__root__/http---b-scorecardresearch-com-beacon-js---0.8683.html
Writing /mnt/hgfs/desktopBin/coverage-ext-master/reporter/html-report/__root__/http---cdn-brcdn-com-v1-br-trk-5117-js---0.4244.html
Writing /mnt/hgfs/desktopBin/coverage-ext-master/reporter/html-report/__root__/http---d3t1dw6evd1rv7-cloudfront-net-385-s_code-js---0.2737.html
Writing /mnt/hgfs/desktopBin/coverage-ext-master/reporter/html-report/__root__/http---d3t1dw6evd1rv7-cloudfront-net-v3-foresee-foresee-surveydef-js-build=3---0.9485.html
Writing /mnt/hgfs/desktopBin/coverage-ext-master/reporter/html-report/__root__/http---d87niwgcilqaw-cloudfront-net-social-entry-getSimplePoolEntries-campaignId=3&channelId=1&poolName=loyalty&offset=0&limit=500&callback=SK-MR-cmsService-getCMSEntries---0.8577.html
fs.js:549
  return binding.open(pathModule._makeLong(path), stringToFlags(flags), mode);
                 ^

Error: ENAMETOOLONG: name too long, open '/mnt/hgfs/desktopBin/coverage-ext-master/reporter/html-report/__root__/http---d87niwgcilqaw-cloudfront-net-social-entry-getSimplePoolEntries-campaignId=3&channelId=1&poolName=loyalty&offset=0&limit=500&callback=SK-MR-cmsService-getCMSEntries---0.8577.html'
    at Error (native)
    at Object.fs.openSync (fs.js:549:18)
    at Object.fs.writeFileSync (fs.js:1156:15)
    at SyncFileWriter.extend.writeFile (/mnt/hgfs/desktopBin/coverage-ext-master/reporter/node_modules/istanbul/lib/util/file-writer.js:58:12)
    at FileWriter.extend.writeFile (/mnt/hgfs/desktopBin/coverage-ext-master/reporter/node_modules/istanbul/lib/util/file-writer.js:147:23)
    at /mnt/hgfs/desktopBin/coverage-ext-master/reporter/node_modules/istanbul/lib/report/html.js:488:24
    at Array.forEach (native)
    at HtmlReport.Report.mix.writeFiles (/mnt/hgfs/desktopBin/coverage-ext-master/reporter/node_modules/istanbul/lib/report/html.js:482:23)
    at /mnt/hgfs/desktopBin/coverage-ext-master/reporter/node_modules/istanbul/lib/report/html.js:484:22
    at Array.forEach (native)

Would you know of a workaround for this?
Some js name can be dynamically generated so the URLs tend to be quite long ...?

  1. Also, and it may or may not be related to the issue above, the final html produces many links that don't resolve. For instance the report list this however I get a 404 (see report in zip)
    jsCoveragePierre.zip
    : file:///C:/Users/plermant/Documents/bin/coverage-ext-master/reporter/html-report/root/http---s-btstatic-com-lib-0e11339390158edd976adc7552fd7d9ebc1e36fb-js-v=1---0.4831.html

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions