Freezing with Firefox?

Running Firefox 85.0 on an M1 MBP, and invoking hook leads Hook to beachball for a while and then nothing happens. Is this known?

Realized I was on a beta version, so switched to 84.0.2, and the issue persists.

Firefox support is language dependent (due to its lack of automation), but I don’t think that would lead to a beachball.

Could you please send us an Activity Monitor Spindump of the Hook process as a PM or email?

In case it helps @tedsvo and @LucB I’m on Firefox Nightly (and will stay there, updating daily) - but on Intel.

I’m thinking with specific instructions I could either confirm it’s broken or works on Intel. Or else check for regression if there is a fix that needs testing.

1 Like

I was having the same issue on my new MBP M1, but after Hook locked up a dozen times or so whenever calling Hook, it finally asked me for permissions to use Firefox. It now seems to be working.

I’m still having a problem with Hook seemingly hanging for 30-60 seconds when called from Firefox. Again, it is only on my MacBook Pro M1.

Internally, we’ve implemented a feature that Hook would gracefully time out when communication with a third-party app does not terminate promptly (defaulting to 5s). This will likely make it into the next release.

But the odd thing is that Hook works with Firefox as long as I wait a moment. I simply need to wait and after 30-60 seconds Hook opens and behaves properly with Firefox. Unusable, but oddly functioning.

  1. Does Hook do that with other apps?

  2. can you try this in Apple’s Script Editor App (Utilities folder).

     use framework "AppKit"
    

    – classes, constants, and enums used
    property NSShiftKeyMask : a reference to 131072
    property NSAlternateKeyMask : a reference to 524288
    property NSControlKeyMask : a reference to 262144
    property NSEvent : a reference to current application’s NSEvent

    set modifier_down to true
    repeat while modifier_down
    set modifier_flags to NSEvent’s modifierFlags()
    set option_down to ((modifier_flags div (get NSAlternateKeyMask)) mod 2) = 1
    set shift_down to ((modifier_flags div (get NSShiftKeyMask)) mod 2) = 1
    set control_down to ((modifier_flags div (get NSControlKeyMask)) mod 2) = 1
    set modifier_down to option_down or shift_down or control_down
    end repeat

    tell application “Firefox”
    activate
    delay 0.05
    set myName to get name of front window
    if version > 72 and myName ends with " - Mozilla Firefox" then
    if length of myName > 18 then
    set myName to text 1 through -19 of myName
    else
    set myName to “”
    end if
    end if
    end tell
    tell application “System Events”
    keystroke “l” using {command down}
    keystroke (key code 53)
    keystroke (key code 53)
    –keystroke “c” using {command down}
    tell process “Firefox”
    click menu item “Copy” of menu “Edit” of menu bar 1
    end tell
    delay 0.05
    set theClipboard to current application’s NSPasteboard’s generalPasteboard’s stringForType:(current application’s NSPasteboardTypeString)
    return (“[” & myName & “](” & the theClipboard as string) & “)”
    end tell

Does it return a result quickly? Please try it a few times.

This only happens with Firefox.

I don’t know if I’m doing it correctly. I instantly receive an error message “Syntax Error: Expected expression but found plural class name”.

I copied the instructions for redoing the permissions from this thread, but for Firefox: Preview.app not working [for some M1, Big Sur customers]
Firefox and Hook seem to be working together well now.