meld icon indicating copy to clipboard operation
meld copied to clipboard

Doesn't work in MacOS Mohave

Open PVGrad opened this issue 6 years ago β€’ 73 comments

I run it

meld /etc/php.ini.default-previous /etc/php.ini.default-previous\~orig
/Applications/Meld.app/Contents/MacOS

And nothing happens - only icon of meld is showing, but no window Then I press ctrl+c to terminate process and this is the output:

Traceback (most recent call last):
  File "/usr/local/bin/meld", line 47, in <module>
    status = subprocess.call([MELDPATH] + arglist, env=environment)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 522, in call
    return Popen(*popenargs, **kwargs).wait()
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 1384, in wait
    pid, sts = _eintr_retry_call(os.waitpid, self.pid, 0)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 476, in _eintr_retry_call
    return func(*args)
KeyboardInterrupt

PVGrad avatar Sep 26 '18 08:09 PVGrad

As I understood - there were my local problems with python2.7 after system update to Mohave. So issue can be closed. Thanks

PVGrad avatar Sep 27 '18 14:09 PVGrad

@PVGrad So how to resolve this problem? macOS 10.14 python --version Python 2.7.10

many thanks.

zzju avatar Sep 28 '18 03:09 zzju

installed python 3, and re-installed meld 3.19, meld works again.

zzju avatar Sep 28 '18 04:09 zzju

I have python 3 installed as well as meld 3.19, but still having the same problem as OP.

fafafariba avatar Sep 28 '18 22:09 fafafariba

Please try to run the following Bash script _clean-meld-settings.sh to cleanup your some settings of Meld.

#!/bin/bash

cd ${HOME}
rm -rf ./.local/share/meld
rm -f ./Library/Preferences/org.gnome.meld.plist
rm -rf "./Library/Saved Application State/org.gnome.meld.savedState/"

munepi avatar Sep 30 '18 01:09 munepi

Today morning (UCT+9 πŸ‡―πŸ‡΅), I also have posted how to use/change custom-font with Meld plist settings in Issue Can't change font #38. The plist file ~//Library/Preferences/org.gnome.meld.plist is just the one. Please check and try the post if necessary.

munepi avatar Oct 03 '18 13:10 munepi

Please try to run the following Bash script _clean-meld-settings.sh to cleanup your some settings of Meld.

#!/bin/bash

cd ${HOME}
rm -rf ./.local/share/meld
rm -f ./Library/Preferences/org.gnome.meld.plist
rm -rf "./Library/Saved Application State/org.gnome.meld.savedState/"

This worked for me, thank you.

fafafariba avatar Oct 09 '18 18:10 fafafariba

I've got approximately the same output running Meld (python version 2.7.15, OS X 10.14). Cleaning settings did not change anything for me:

/Applications/Meld.app/Contents/MacOS
^CTraceback (most recent call last):
  File "/Applications/Meld.app/Contents/MacOS/Meld", line 47, in <module>
    status = subprocess.call([MELDPATH] + arglist, env=environment)
  File "/usr/local/Cellar/python@2/2.7.15_1/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 172, in call
    return Popen(*popenargs, **kwargs).wait()
  File "/usr/local/Cellar/python@2/2.7.15_1/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 1099, in wait
    pid, sts = _eintr_retry_call(os.waitpid, self.pid, 0)
  File "/usr/local/Cellar/python@2/2.7.15_1/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 125, in _eintr_retry_call
    return func(*args)
KeyboardInterrupt

Anything else I can try?

ppannuto avatar Oct 15 '18 21:10 ppannuto

Please try to run the following Bash script _clean-meld-settings.sh to cleanup your some settings of Meld.

#!/bin/bash

cd ${HOME}
rm -rf ./.local/share/meld
rm -f ./Library/Preferences/org.gnome.meld.plist
rm -rf "./Library/Saved Application State/org.gnome.meld.savedState/"

this worked for me as well, thank you! πŸ‘

MaxBenChrist avatar Oct 16 '18 10:10 MaxBenChrist

Please try to run the following Bash script _clean-meld-settings.sh to cleanup your some settings of Meld.

#!/bin/bash

cd ${HOME}
rm -rf ./.local/share/meld
rm -f ./Library/Preferences/org.gnome.meld.plist
rm -rf "./Library/Saved Application State/org.gnome.meld.savedState/"

this worked for me as well, thank you! πŸ‘

It worked only 1 time after cleaning all setting. I still only see an icon for the second and the after runs.

JerryShih avatar Oct 17 '18 11:10 JerryShih

@JerryShih That is an unofficial, bad know-how :-( , but please try the following three steps.

  1. move the original Mac-port starter script to Meld.distro below.
    $ mv /Applications/Meld.app/Contents/MacOS/Meld /Applications/Meld.app/Contents/MacOS/Meld.distro
    
  2. make a wrapper /Applications/Meld.app/Contents/MacOS/Meld of the Meld.distro below
    #!/bin/bash
    
    ## 
    # $ sudo xattr -r -d com.apple.quarantine /Applications/Meld.app/
    
    ## standard plist settings: OK
    # ~/Library/Preferences/org.gnome.meld.plist
    # $ defaults read org.gnome.meld
    # $ defaults write org.gnome.meld "/org/gnome/meld/use-system-font" 0
    # $ defaults write org.gnome.meld "/org/gnome/meld/custom-font" "Ricty, 18"
    
    ##FIXME: ad-hoc cleanup Meld settings
    (cd ${HOME}
    rm -rf ./.local/share/meld
    #rm -f ./Library/Preferences/org.gnome.meld.plist
    rm -rf "./Library/Saved Application State/org.gnome.meld.savedState/"
    )
    
    # export G_ENABLE_DIAGNOSTIC=1 # 0 or 1
    # export GTK_THEME=Adwaita # Adwaita or Adwaita:dark
    # export GTK_DEBUG=interactive
    
    logger "/Applications/Meld.app/Contents/MacOS/Meld.distro"
    exec "/Applications/Meld.app/Contents/MacOS/Meld.distro" $@
    
  3. Then, $ chmod +x /Applications/Meld.app/Contents/MacOS/Meld

I remark that

  • you are available some GTK-related environment variables inside the above wrapper Meld: G_ENABLE_DIAGNOSTIC, GTK_THEME, GTK_DEBUG.
  • you are also available some tips commented in the above wrapper Meld if necessary.
  • I also have posted how to use/change custom-font with Meld plist settings in Issue Can't change font #38. The plist file ~//Library/Preferences/org.gnome.meld.plist is just the one. Please check and try the post if necessary.

munepi avatar Oct 17 '18 11:10 munepi

@JerryShih That is an unofficial, bad know-how :-( , but please try the following three steps.

  1. move the original Mac-port starter script to Meld.distro below.
    $ mv /Applications/Meld.app/Contents/MacOS/Meld /Applications/Meld.app/Contents/MacOS/Meld.distro
    
  2. make a wrapper /Applications/Meld.app/Contents/MacOS/Meld of the Meld.distro below
    #!/bin/bash
    
    ## 
    # $ sudo xattr -r -d com.apple.quarantine /Applications/Meld.app/
    
    ## standard plist settings: OK
    # ~/Library/Preferences/org.gnome.meld.plist
    # $ defaults read org.gnome.meld
    # $ defaults write org.gnome.meld "/org/gnome/meld/use-system-font" 0
    # $ defaults write org.gnome.meld "/org/gnome/meld/custom-font" "Ricty, 18"
    
    ##FIXME: ad-hoc cleanup Meld settings
    (cd ${HOME}
    rm -rf ./.local/share/meld
    #rm -f ./Library/Preferences/org.gnome.meld.plist
    rm -rf "./Library/Saved Application State/org.gnome.meld.savedState/"
    )
    
    # export G_ENABLE_DIAGNOSTIC=1 # 0 or 1
    # export GTK_THEME=Adwaita # Adwaita or Adwaita:dark
    # export GTK_DEBUG=interactive
    
    logger "/Applications/Meld.app/Contents/MacOS/Meld.distro"
    exec "/Applications/Meld.app/Contents/MacOS/Meld.distro" $@
    
  3. Then, $ chmod +x /Applications/Meld.app/Contents/MacOS/Meld

I remark that

  • you are available some GTK-related environment variables inside the above wrapper Meld: G_ENABLE_DIAGNOSTIC, GTK_THEME, GTK_DEBUG.
  • you are also available some tips commented in the above wrapper Meld if necessary.
  • I also have posted how to use/change custom-font with Meld plist settings in Issue Can't change font #38. The plist file ~//Library/Preferences/org.gnome.meld.plist is just the one. Please check and try the post if necessary.

It just a wrapper to clean the setting before calling meld. What's the root cause for this problem? Do all gtk-base gui tools have the same problem?

JerryShih avatar Oct 18 '18 05:10 JerryShih

Not all gtk-based, just the pygtk-based require such wrapper.

And I apologize for not being able to help as efficiently on this thread (and others), but I promise that once I have some spare time on my hands + having collected some tricks and fixes from the people that comment on those issues, I'll create a new release that would include the fixes in one nifty release.

yousseb avatar Oct 18 '18 05:10 yousseb

Hi @yousseb , Thank you for your information and follow-up. I exactly could not trace that problem around pygtk-something :-( So, I have made such ad-hoc wrapper. I'm looking forward to a new release!

munepi avatar Oct 18 '18 05:10 munepi

@munepi thank you for trying (and helping others get their cases resolved). I wish there was some means to tell the generated binary the path to look for libraries in a cleaner way to get rid of the python wrapper that I had to make. That on its own would have solved other issues on my list here.

But anyway, I guess I'll be able to put sometime into this within a month or so. Or at least I hope..

yousseb avatar Oct 18 '18 05:10 yousseb

#!/bin/bash cd ${HOME} rm -rf ./.local/share/meld rm -f ./Library/Preferences/org.gnome.meld.plist rm -rf "./Library/Saved Application State/org.gnome.meld.savedState/"

Work for me as well. πŸ‘

briskgopesh avatar Oct 26 '18 06:10 briskgopesh

these steps fixed it for me too.. thanks!!

rm -rf ./.local/share/meld rm -f ./Library/Preferences/org.gnome.meld.plist rm -rf "./Library/Saved Application State/org.gnome.meld.savedState/"

thanks @munepi i needed the wrapper to run cleanly

chaosless avatar Oct 31 '18 21:10 chaosless

these steps fixed it for me too.. thanks!!

rm -rf ./.local/share/meld rm -f ./Library/Preferences/org.gnome.meld.plist rm -rf "./Library/Saved Application State/org.gnome.meld.savedState/"

This isn't really a "fix" though...

sysadmiral avatar Nov 01 '18 10:11 sysadmiral

rm -rf "./Library/Saved Application State/org.gnome.meld.savedState/"

Nice .. thanks for that :-)

VR2ualize avatar Nov 05 '18 23:11 VR2ualize

I have same issue on Mojave with 3.19.0

oxoocoffee avatar Nov 06 '18 18:11 oxoocoffee

The fix kind of works for me but the mouse isn't accurate when trying to manipulate the UI elements. I have to go about a quarter of an inch above the UI element for the click event to register. Hopefully this will be fixed sooner than later!

bbqchickenrobot avatar Nov 07 '18 06:11 bbqchickenrobot

The fix kind of works for me but the mouse isn't accurate when trying to manipulate the UI elements. I have to go about a quarter of an inch above the UI element for the click event to register. Hopefully this will be fixed sooner than later!

I also get that, but only when resizing the application window after opening, if I don't change the size of the application window I don't get that problem.

VR2ualize avatar Nov 07 '18 14:11 VR2ualize

Please try to run the following Bash script _clean-meld-settings.sh to cleanup your some settings of Meld.

#!/bin/bash

cd ${HOME}
rm -rf ./.local/share/meld
rm -f ./Library/Preferences/org.gnome.meld.plist
rm -rf "./Library/Saved Application State/org.gnome.meld.savedState/"

Thanks, this fixed it, without having to upgrade Python 🏁

Please add this to the release notes πŸ˜ƒ

dluc avatar Nov 14 '18 00:11 dluc

Please try to run the following Bash script _clean-meld-settings.sh to cleanup your some settings of Meld.

#!/bin/bash

cd ${HOME}
rm -rf ./.local/share/meld
rm -f ./Library/Preferences/org.gnome.meld.plist
rm -rf "./Library/Saved Application State/org.gnome.meld.savedState/"

Removing some meld files temporarily fixed the issue. So, I wanted to try the wrapper solution as munepi posted above, but no luck I am receiving "There was a problem opening the file" error whenever Meld opens a file. Probably, I am doing something wrong at step2 of the wrapper solution. Anyway, I also look forward to waiting for an update for this issue. Thanks a lot for your help.

SemihGk avatar Nov 19 '18 16:11 SemihGk

Using 3.19.0 and Meld stopped working again. Repeating the steps above fixed the issue one more time, but apparently there's a bug leading to the broken state at some point

dluc avatar Nov 28 '18 23:11 dluc

Hey guys, could you please run the _clean-meld-settings.sh script by @munepi in this thread then give this new build a shot?

https://github.com/yousseb/meld/releases/tag/os-11

yousseb avatar Dec 01 '18 06:12 yousseb

Running 3.19.2 (r1) but the font size is 18pt and cannot be changed as this leads to a crash

preinking avatar Dec 01 '18 08:12 preinking

tried newest version, no go.

 ↳ meld --version
 meld 3.19.2

But maybe this is a clue, Yousef?

 ↳ /Applications/Meld.app/Contents/MacOS/Meld-bin
 Couldn't set the locale: unsupported locale setting; falling back to 'C' locale

 ** (process:26632): WARNING **: 14:32:29.078: Failed to load shared library 
 '/Users/youssef/gtk/inst/lib/libglib-2.0.0.dylib' referenced by the typelib: 
 dlopen(/Users/youssef/gtk/inst/lib/libglib-2.0.0.dylib, 9): image not found

 ** (process:26632): WARNING **: 14:32:29.078: Failed to load shared library 
 '/Users/youssef/gtk/inst/lib/libgobject-2.0.0.dylib' referenced by the typelib: 
 dlopen(/Users/youssef/gtk/inst/lib/libgobject-2.0.0.dylib, 9): image not found

ira-bv avatar Dec 02 '18 12:12 ira-bv

Trying to figure this out. But no, it’s not those paths.

The Meld starter python script sets the DYLD_LIBRARY_PATH which tells dlopen where to look. In fact, this is the only reason why the script exists and I’ve been looking for a way around this forever. This is deep inside gopject-introspection python compiler. The only recommendation that I have is don’t start Meld-bin directly until I find a solution to telling gi to use relative path.

Alternatively, I could use some help in telling macOS not save state on crashes. Looks like this is what is happening.

On Sun, Dec 2, 2018 at 4:35 AM Ira Abramov [email protected] wrote:

tried newest version, no go.

↳ meld --version

meld 3.19.2

But maybe this is a clue, Yousef?

↳ /Applications/Meld.app/Contents/MacOS/Meld-bin

Couldn't set the locale: unsupported locale setting; falling back to 'C' locale

** (process:26632): WARNING **: 14:32:29.078: Failed to load shared library

'/Users/youssef/gtk/inst/lib/libglib-2.0.0.dylib' referenced by the typelib:

dlopen(/Users/youssef/gtk/inst/lib/libglib-2.0.0.dylib, 9): image not found

** (process:26632): WARNING **: 14:32:29.078: Failed to load shared library

'/Users/youssef/gtk/inst/lib/libgobject-2.0.0.dylib' referenced by the typelib:

dlopen(/Users/youssef/gtk/inst/lib/libgobject-2.0.0.dylib, 9): image not found

β€” You are receiving this because you were mentioned.

Reply to this email directly, view it on GitHub https://github.com/yousseb/meld/issues/70#issuecomment-443504250, or mute the thread https://github.com/notifications/unsubscribe-auth/AEgDildYlKc6Gox88ASMdK4a8lI1Ml3Lks5u08j1gaJpZM4W6Kzk .

yousseb avatar Dec 02 '18 17:12 yousseb

One more build. Let's try this one guys:

https://github.com/yousseb/meld/releases/tag/osx-11

yousseb avatar Dec 02 '18 22:12 yousseb