Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

SugarCube 2.18.0 & Safari 10.1.1 (macOS 10.12.x) — "Fatal error" on opening HTML file in browser

I rarely ever launch my project in Safari directly so I'm not sure how far back I introduced this problem, but I have noticed on launching Twine's html output file in Safari itself I get the following error as a popup:
Apologies! A fatal error has occurred. Aborting.

Error: SecurityError (DOM Exception 18): The operation is insecure..

Stack Trace:
global code@file:///Users/joshuameadows/Desktop/Alcyone-%20The%20Last%20City.html:6186:30734

The game never progresses past the loading reticule. I'm not quite sure what I have done to cause the problem, although it works fine in the web2exe executable I use to package the project as its own app. It would make my life easier to debug if I can use the file occasionally in Safari, so I'm curious about fixing it if I can.


  • Do you have the safari browser set to allow access to local storage and such?
  • Chapel wrote: »
    Do you have the safari browser set to allow access to local storage and such?

    Hm, I don't know that I don't? I wouldn't have changed any default settings & it worked previously (within the last few months).
  • edited May 18
    Might be worth checking out if you can, if only to rule it out. Some setting like 'Block cookies and data.' An update could have potentially changed the setting or its default state or something. I could also be totally wrong. I had a similar issue a few weeks ago when I was testing some stuff on a friend's mac book, though I don't remember if it was the exact same issue, it was something about security and changing that setting worked.
  • I've had issues with Firefox as well, and only lately, too. Chrome still works, though, but only because I know how to allow local storage access.
  • edited May 18
    Does this happen with a new empty project compiled with SugarCube or only with Alcyone?

    That security error can result from a variety of things, it's not specifically a storage error. In this case, however, a storage error is the most likely source. There was a bug in the 10.1 betas related to storage access from local files, however, it was supposed to have been resolved. Perhaps the fix didn't make it into the version you're using—no idea about that, I'm just speculating.

    Also. IIRC, the setting you want to check is under the Privacy tab as Cookies and website data.
  • Hm yes it happens with a totally empty project as well, although I have that option checked & enabled in my browser. o_o
  • I tried wiping Safari to scratch & testing — still didn't work.
    I created a brand new user account — still didn't work.
    I tested it on a different machine — still didn't work.

    So I don't know if there's been a new setting added that's more restrictive or what, but I'm baffled personally.
  • At this point, I'm getting the impression that the bug made it out of the betas. :(

    Which setting did you do your testing with: Allow from websites I visit, Always allow? I'm assuming you didn't try one of the more restrictive ones.

    Regardless. If possible, I'd prefer for SugarCube to trap that exception and deliver a more on-target error message. Since I do not have access to modern versions of Safari—outside of iOS Safari, which limits my ability to do local file testing—I might ask you to test some builds for me, if you don't mind.
  • Yeah I would be happy to test anything you need. It was on "allow from websites I visit" by default, I think, but "always allow" didn't change it either.
  • I'm having this same error on everything I create with Twine 2.1.3 and Sugarcube 2.18.0, including previously OK files. I'm seeing it on Safari on my desktop (new-ish MacBook Pro) and my iPhone 6. (System software on both is fully up-to-date.)
Sign In or Register to comment.