Obfuscate failure - alleged syntax error

At some point between starting my project and the bazillion lines of code later, the obfuscation began to fail, claiming there is likely a syntax error to blame. The code runs fine (always has) and I’ve used other online tools to do an independent syntax error and nothing is wrong.

I see other topics posted on the topic, but that was failing on blank projects and was fixed in I’m running

Any suggestions for an easy fix?

My only thought is to make a blank project and load the files one by one until I get the failure. (I could also try to comment ALL code and then uncomment file by file). I dread either of those options, so I’m asking here if there is something else (easier) to try. Maybe there’s a log file I can inspect?

Thanks in advance!

Can you share the exact error you’re receiving?

Any chance you can DM me the project? I’d like to try it here on a test version I’m working on.

Screenshot 2023-12-10 155355

Will do. (adding this nothing text to be more than 10 characters)

Got the project, thank you!

I will look at it today.

A couple of preliminary findings. I’m working on getting more details, but in the meantime…

  1. The internal error message is unterminated string literal.

  2. There are a number of lint errors in the code. You might want to clean these up. Click on the hexagon icon above the Code Window to see them:

Screenshot 2023-12-11 at 9.20.56 AM

This turns out to be happening in the widely used JSMIN library.

Specifically, on this line:

    NSB.MsgBox(`Click ` +
      `<a href='mailto:${aGameData.accountEmailArray[1]}` +
      `?cc=${userLogic.userData.accountEmailString}` +
      `&subject=Invitation%20from%20${userLogic.userData.accountEmailString}%20to%20play%20a%20game%20of%20Space%20Missile` +
      `&body=Click%20${url.href.replaceAll("&", "%26")}'` +
      `target='_self' rel='noopener noreferrer'>` +
      `here</a>` +
      ` to open your email app, review the invitation, and send it.`, 0, "🚀 Space Missile");

JSMIN fails (see the &body line for an extra single quote).

I used this page to validate your code. I could only see the error if I looked at the Chrome console. I used binary splitting of your code to find the problem. JSMIN does not give a line number - it just fails.

We’ll look into this more, but this should at least get you going again.

Yes, I’ve been wanting to do that. Unfortunately, 98% of the lint errors are style, not syntax.

If you recall, had reached out to you to help me use the link config property to adjust what it reports.

Brilliant! Thank you!!

Looks like that is fixed in AS9. I’m meeting with the team today about getting it released.


Not sure if you tried deleting that one single quote, but I still get the same error.

I tried using your recommended tool, I but could not get all my code to produce an output. I may not know how to use it.

Either way, you seem confident that it is a spurious error that the browser isn’t catching. So, I will continue to use online tools, etc., to see if I can track it down.

Thanks again for taking a look at it!

Great news!

Open the Chrome Console. If jsmin fails, a message will be produced. Unfortunately, jsmin does not tell you the line number.

Ah! Now I see what you meant. (I was evaluating the minimized code in chrome and not seeing any errors.) Gotcha!