This topic contains 5 replies, has 0 voices, and was last updated by darrenhillconsulting 8 years ago.

  • Author
    Posts
  • #1531

    darrenhillconsulting

    So, today … an automation I built just stopped working. More accurately, the render.xmlToPdf function throws a classic unexpected error. (Line 221 is the render.xmlToPdf call)

    {“type”:”error.SuiteScriptError”,”name”:”UNEXPE CTE D_ERROR”,”message”:null,”stack”:[“renderXmlToPdf(N/render)”,”(/SuiteScripts/DH/DH_GeneratePDF.js:211)”],”cause”:{“type”:”internal error”,”code”:”UNEXPECTED_ERROR”,”details”:null,”u serEvent”:null,”stackTrace”:[“renderXmlToPdf(N/render)”,”(/SuiteScripts/DH/DH_GeneratePDF.js:211)”],”notifyOff”:false},”id”:””,”notifyOff”:false}

    This has been working for more than a quarter, so why fail now?

    Here’s the xmlString I’m passing into the function. The xml itself passes all validations and has no bad characters. And 3 image references resolve fine.

    Code:











    Vendor Report

    Batdad – batdad

    2016-10-1 – 2016-10-31

    Traffic Summary



































































    Total Earnings $105,419.90
    Total Pageviews 32,595,964
    Total Entrances 8,506,353
    Earnings Per Day $3,400.64
    Pages Per Session 3.83
    Pageviews Per day 1,051,483
    Entrances Per Day 274,398
    Average RPM $3.23

    This is a cached copy. Click here to see the original post.

  • #1532

    michoel

    I don’t know if this is what’s causing the issue, but you seem to be missing the tag:

    Code:

  • #1533

    darrenhillconsulting

    I thought the same thing … but its in there (not sure why its not in my example)

  • #1534

    adityasrivalli

    Noticed at a coupel of places, some equal to symbols in your sample tags within the Datacurve tag, Please check if they are causing syntactical issues.

  • #1535

    darrenhillconsulting

    Originally posted by adityasrivalli

    View Post

    Noticed at a coupel of places, some equal to symbols in your sample tags within the Datacurve tag, Please check if they are causing syntactical issues.

    Ya, something went wrong when I copied that code into this editor. I corrected the xml content string.

  • #1536

    darrenhillconsulting

    Hello all,

    I was able to fix this issue myself. I ended up downloading and installing the BFO Generator locally and ran my xml through it. So I got much more detailed error output than the generic Netsuite one. Ended up my TrueType font file was corrupt! Everything is right in the world again.

    Cheers to those that helped out!

You must be logged in to reply to this topic.