Loading ...
Sorry, an error occurred while loading the content.

AppleEvent TimedOut

Expand Messages
  • underdoeg
    Hi everyone. I am trying to compile the currently open as code file with mxmlc. It did work actually. But then suddenly I got the following error message:
    Message 1 of 4 , Apr 2, 2008
    • 0 Attachment
      Hi everyone.

      I am trying to compile the currently open as code file with mxmlc. It did work actually. But
      then suddenly I got the following error message:

      SubEthaEdit got an error: AppleEvent timed out. (-1712)

      If I run the script from the Script Editor however it works fine.

      After some googling I found this page where one of the developers was asking help about
      this issue:

      http://lists.apple.com/archives/applescript-implementors/2006/Apr/msg00041.html

      Seems to be exactly this bug. Does anybody know about this?

      Thank you

      Philip Whitfield (underdoeg)
    • michael_j_barber
      ... But ... AppleScript doesn t wait forever for a response. IIRC, it times out after a minute. If your compile takes longer than that, you ll get the error
      Message 2 of 4 , Apr 3, 2008
      • 0 Attachment
        --- In SubEthaEdit@yahoogroups.com, "underdoeg" <underdoeg@...> wrote:
        >
        > Hi everyone.
        >
        > I am trying to compile the currently open as code file with mxmlc. It did work actually.
        But
        > then suddenly I got the following error message:
        >
        > SubEthaEdit got an error: AppleEvent timed out. (-1712)
        >
        AppleScript doesn't wait forever for a response. IIRC, it times out after a minute. If your
        compile takes longer than that, you'll get the error above.

        Try wrapping your call to the compile in a "with timeout" statement. It should look
        something like

        with timeout of (60*30) seconds
        compileDocument()
        end timeout

        That gives 30 minutes for the compilation to complete.

        Wrap it in a try to handle any error that still comes through.
      • underdoeg
        Tanks for your quick reply. I already set the timeout. But that didn t work. But with the try I can at least show a decent error message. Thanks. I don t
        Message 3 of 4 , Apr 3, 2008
        • 0 Attachment
          Tanks for your quick reply.

          I already set the timeout. But that didn't work. But with the try I can at least show a decent
          error message. Thanks.

          I don't really think it has something to do with the time my script takes because it works
          perfectly when i run it out of script editor and the timeOut message appears right after I
          try to run it from SubEtha. A timeout should at least take a few seconds before happening
          or am I wrong?

          I recoded the whole thing now and will start it as an application for the moment. If it
          works the way I'm expecting it, Ill post it here

          --- In SubEthaEdit@yahoogroups.com, "michael_j_barber" <michael_j_barber@...> wrote:
          >
          > --- In SubEthaEdit@yahoogroups.com, "underdoeg" <underdoeg@> wrote:
          > >
          > > Hi everyone.
          > >
          > > I am trying to compile the currently open as code file with mxmlc. It did work
          actually.
          > But
          > > then suddenly I got the following error message:
          > >
          > > SubEthaEdit got an error: AppleEvent timed out. (-1712)
          > >
          > AppleScript doesn't wait forever for a response. IIRC, it times out after a minute. If your
          > compile takes longer than that, you'll get the error above.
          >
          > Try wrapping your call to the compile in a "with timeout" statement. It should look
          > something like
          >
          > with timeout of (60*30) seconds
          > compileDocument()
          > end timeout
          >
          > That gives 30 minutes for the compilation to complete.
          >
          > Wrap it in a try to handle any error that still comes through.
          >
        • michael_j_barber
          The timeout should definitely take a while. I misunderstood what you meant when you said you suddenly got the error - I thought it was indicative of an
          Message 4 of 4 , Apr 4, 2008
          • 0 Attachment
            The timeout should definitely take a while. I misunderstood what you meant when you
            said you "suddenly" got the error - I thought it was indicative of an unexpected change,
            rather than about the timing.

            Your description seems consistent with the warning given at the bottom of this page:
            <https://www.codingmonkeys.de/subethaedit/scripting.html>. Could that be it?

            I'd think that your scripts should be mostly the same as what I did for invoking LaTeX.
            There's a basic description here:
            <http://appliedabstraction.blogspot.com/2007/07/seeing-latex-6-typesetting.html>.
            Maybe it will be of help. Later posts in the series refine the ideas; you might find the set
            of AppleScript handlers at <http://appliedabstraction.blogspot.com/2008/01/seeing-
            latex-19-subethaedittools-or.html> to be of use.

            --- In SubEthaEdit@yahoogroups.com, "underdoeg" <underdoeg@...> wrote:
            >
            > Tanks for your quick reply.
            >
            > I already set the timeout. But that didn't work. But with the try I can at least show a
            decent
            > error message. Thanks.
            >
            > I don't really think it has something to do with the time my script takes because it works
            > perfectly when i run it out of script editor and the timeOut message appears right after I
            > try to run it from SubEtha. A timeout should at least take a few seconds before
            happening
            > or am I wrong?
            >
            > I recoded the whole thing now and will start it as an application for the moment. If it
            > works the way I'm expecting it, Ill post it here
            >
            > --- In SubEthaEdit@yahoogroups.com, "michael_j_barber" <michael_j_barber@> wrote:
            > >
            > > --- In SubEthaEdit@yahoogroups.com, "underdoeg" <underdoeg@> wrote:
            > > >
            > > > Hi everyone.
            > > >
            > > > I am trying to compile the currently open as code file with mxmlc. It did work
            > actually.
            > > But
            > > > then suddenly I got the following error message:
            > > >
            > > > SubEthaEdit got an error: AppleEvent timed out. (-1712)
            > > >
            > > AppleScript doesn't wait forever for a response. IIRC, it times out after a minute. If
            your
            > > compile takes longer than that, you'll get the error above.
            > >
            > > Try wrapping your call to the compile in a "with timeout" statement. It should look
            > > something like
            > >
            > > with timeout of (60*30) seconds
            > > compileDocument()
            > > end timeout
            > >
            > > That gives 30 minutes for the compilation to complete.
            > >
            > > Wrap it in a try to handle any error that still comes through.
            > >
            >
          Your message has been successfully submitted and would be delivered to recipients shortly.