MWorks no windows called with magnifying symbol show up

Hi Chris,

I have been working with the nightly build for a few days now.

Today and apparently out of nowhere, mworks stopped opening the variable, reward, eye window etc. I can load an eye calibration, run tasks and see the console. The popups in the preference window works, etc.
Popups don’t show on the other monitor either.

I tried to revert to 12.1 and 12, also clearing the experiment cache. Several restarts. Nothing has helped. I cannot run experiments this way.

macOS 12.6.8

Any idea what’s going on?

Hi Alina,

It sounds like the problem you’re describing is as follows:

  1. You click MWClient’s magnifying glass button.
  2. The normal menu of client window options appears.
  3. Selecting a window option does not open the window.

Is that correct? If so, do the “Show All”, “Show Grouped”, and “Hide All” choices do anything?

If the issue persists even after you quit and re-open MWClient, then I don’t see how it could be an issue with the application, as there’s no persistent state associated with the client window popup menu. This makes me suspect an OS-level issue. Have you tried restarting macOS?

Also, are you sure the windows aren’t opening underneath the stimulus display window? To test this, try opening a client window before you’ve loaded an experiment, then check all the displays for it.

Finally, have you installed or updated any other software recently on the Mac in question? I’m not sure how other software could be causing the issue, but I suppose it’s possible.

Thanks,
Chris

Hi Chris,

I click the button but no selection menu appears.

No that already doesn’t happen.

I don’t have these.
Show all with right click on client does nothing.

Yes I restarted repeatedly

Yes I tried that, not helping

No. The frustrating thing is that it worked the day before and I didn’t change anything at all.

I will try an os update to 12.7 next. Sometimes mysterious Mac issues disappear when I update.

Hi Alina,

If the client window popup menu doesn’t appear at all, then it’s possible that there’s something wrong with one or more of the plugins that implement the windows. Starting with MWClient closed, can you run the following command in Terminal and send me the output?

MWORKS_WRITE_MESSAGES_TO_STDERR=1 /Applications/MWClient.app/Contents/MacOS/MWClient

If there are issues loading any of the client plugins, hopefully there will be some relevant error messages in the Terminal output.

Thanks,
Chris

Loading HighPrecisionClock

Loading LowPrioritySchedulerPlugin

2023-09-29 11:07:21.704 MWClient[1924:20330] log file path: /Users/labuser/Library/Logs/MWorks/20230929_110721704.log

2023-09-29 11:07:21.856 MWClient[1924:20330] Couldn’t load bundle: The bundle “MWorksMATLABWindow” couldn’t be loaded.: {

NSBundlePath = “/Library/Application Support/MWorks/Plugins/Client/MWorksMATLABWindow.bundle”;

NSDebugDescription = “dlopen(/Library/Application Support/MWorks/Plugins/Client/MWorksMATLABWindow.bundle/Contents/MacOS/MWorksMATLABWindow, 0x0109): Library not loaded: ‘@rpath/libeng.dylib’\n Referenced from: ‘/Library/Application Support/MWorks/Plugins/Client/MWorksMATLABWindow.bundle/Contents/MacOS/MWorksMATLABWindow’\n Reason: tried: ‘/Applications/MATLAB/bin/maci64/libeng.dylib’ (no such file), ‘/Applications/MATLAB/bin/maci64/libeng.dylib’ (no such file), ‘/usr/local/lib/libeng.dylib’ (no such file), ‘/usr/lib/libeng.dylib’ (no such file)”;

NSFilePath = “/Library/Application Support/MWorks/Plugins/Client/MWorksMATLABWindow.bundle/Contents/MacOS/MWorksMATLABWindow”;

NSLocalizedDescription = “The bundle \U201cMWorksMATLABWindow\U201d couldn\U2019t be loaded.”;

NSLocalizedFailureReason = “The bundle couldn\U2019t be loaded.”;

NSLocalizedRecoverySuggestion = “Try reinstalling the bundle.”;

I checked the log files, they are empty

Thanks. I see nothing unusual there, unfortunately. Updating to macOS 12.7 is probably a good next step.

Also, is the Mac in question one of the 2013 (aka “Trash Can”) Mac Pro’s?

Thanks,
Chris

Yes it’s the trash can, updating did not help.

I have no issues with any other apps.

Hi Chris,

We still don’t know what cause the original issue, but at some point during my clearing of everything mworks I removed the configuration file, and adding this makes it run again.

So the error looks just like a fresh install without the configuration file, which I certainly didn’t touch in between…

Hi Alina,

OK, that’s good news, both because it fixes your issue and because it’s something I should be able to reproduce for myself.

Just to be clear, which configuration file had been removed?

Thanks,
Chris

Whatever was in the install path described online. It must have been the two-monitor version because I am using two monitors. Either configuration file solved the issue.

I think the file got lost when I kept uninstalling more mworks, or if that is not part of your uninstall, I was also clearing mworks from the cache and possibly anywhere I could find it lingering because reverting from nightly to 12.1 and then to 12.0 didn’t fix my issue.

I keep forgetting about that configuration file because it is described after the uninstall… I think this is at least the second time I had such a deep issue that I had to remove all traces of mworks from the machine to recover.

Hi Alina,

Your answer raises more questions:

  1. If you re-remove the configuration file that you restored, does the client window issue return?

  2. Before you restored the configuration file, were you able to load and run experiments (apart from being unable to open client windows)?

    If so, then there must have been a configuration file in one of the two possible locations, because experiment loading just fails with the following message if there is no configuration file whatsoever:

    ERROR: Cannot load experiment file: The file "setup_variables.xml" couldn't be opened because there is no such file.
    
  3. Is it possible that you also removed the file $HOME/Library/Preferences/org.mworks-project.MWClient.plist?

    I have no idea how a missing setup_variables.xml could affect the client, but if org.mworks-project.MWClient.plist got corrupted somehow, it’s conceivable that that could have caused the issue you were having, and removing it resolved the issue.

  4. What do you mean by “clearing mworks from the cache”?

Thanks,
Chris

If you re-remove the configuration file that you restored, does the client window issue return?

Interestingly, no. I did have the file in two locations though as it turns out, so I am not sure if it was truly missing (likely not because stuff is still running) or if the fresh copy supersedes the other, possibly corrupted copy?

The locations are very similar in name and now I also briefly had both on the desktop to produce the proper error that happens when the config file is missing. So what I can say is copying a fresh version from mworks 12.0 from the examples restored healthy behavior. But I am no longer sure if one of them could have been a ‘bad’ config file. Opening both right now, they are identical.

Before you restored the configuration file, were you able to load and run experiments (apart from being unable to open client windows)?

Yes.

If so, then there must have been a configuration file in one of the two possible locations, because experiment loading just fails with the following message if there is no configuration file whatsoever:

Yes indeed I could make that happen.

Is it possible that you also removed the file $HOME/Library/Preferences/org.mworks-project.MWClient.plist?

No I did not.

What do you mean by “clearing mworks from the cache”?

There’s an experiment cache in some obscure location like 4g/y083240834098024/ that often causes issues, but frequently those are related to stimuli not updating properly.

Hi Alina,

So what I can say is copying a fresh version from mworks 12.0 from the examples restored healthy behavior. But I am no longer sure if one of them could have been a ‘bad’ config file. Opening both right now, they are identical.

None of this makes much sense. Like I said, I have no idea how a setup_variables.xml file, corrupted or otherwise, could affect MWClient’s UI. I’m inclined to think that, just as the problem appeared randomly, it disappeared randomly, too, and the fact that you had also just restored the config file was a coincidence.

One final thought: Are you running TeamViewer on this Mac? I have (possibly unfounded) suspicions that TeamViewer does nasty, invasive things that could potentially break other apps. If you find yourself with this or another bizarre UI issue in the future, and you’d like to entertain my suspicions, you could try disabling or uninstalling TeamViewer.

Apart from that, I have no more ideas for debugging this problem. But if it happens again, please let me know!

Thanks,
Chris

Not teamviewer but realvnc. Which may generate similar issues perhaps, though it hasn’t before… I will reinstall the nightly build soon and tell you how that goes.