[issue32909] ApplePersistenceIgnoreState warning on macOS

2018-02-23 Thread Ronald Oussoren

Ronald Oussoren  added the comment:

The ApplePersistenceIgnoreState setting (either in user defaults or an 
info.plist file) is IMHO not the right solution, as this is a setting intended 
to be used for testing (see 
)

I don't have time to research this fully at this time, but expect that this is 
something that should be fixed in GUI libraries (or possibly matplotlib).

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32909] ApplePersistenceIgnoreState warning on macOS

2018-02-22 Thread Ned Deily

Ned Deily  added the comment:

I don't know much about this but it seems to be due to the application Resume 
feature added in OS X 10.7 and has to do with the persistence of application 
windows.  Python itself does not create any such windows; they are created by 
the GUI toolkits used in Python applications, like Tk (used by the standard 
library tkinter) or other third-party modules that interface to other toolkits 
(PyQT, PyObjC, etc). I took a quick look and didn't see any application bundle 
keys that could be added to the Python.app Info.plist to disable persistence 
globally in a Python framework build and, even if there were one, I'm not sure 
that is desirable.  Perhaps the best way is for each tool kit to do it.  
Ronald, anyone else: have any suggestions?

https://developer.apple.com/library/content/documentation/DataManagement/Conceptual/DocBasedAppProgrammingGuideForOSX/StandardBehaviors/StandardBehaviors.html

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32909] ApplePersistenceIgnoreState warning on macOS

2018-02-22 Thread cbrnr

New submission from cbrnr :

There seems to be a problem with using certain Python packages and the 
application resume feature of recent macOS versions. Specifically, whenever I 
"import matplotlib.plyplot" or run the magic command "%matplotlib" in IPython, 
I get the following warning message:

2018-02-22 10:35:38.287 Python[4145:281298] ApplePersistenceIgnoreState: 
Existing state will not be touched. New state will be written to (null)

There's an issue in the matplotlib repo 
(https://github.com/matplotlib/matplotlib/issues/6242), but I don't think this 
problem can be fixed by matplotlib. Instead, according to this SO post 
(https://stackoverflow.com/a/21567601/1112283), the following command fixes the 
behavior:

defaults write org.python.python ApplePersistenceIgnoreState NO

Since this problem also comes up with Homebrew, I created an issue 
(https://github.com/Homebrew/homebrew-core/issues/24424), but the maintainers 
indicated that (1) this might be a Python issue and should be addressed 
upstream, and (2) the solution above is not a real fix and the correct behavior 
should be implemented programmatically by Python itself.

--
components: macOS
messages: 312550
nosy: cbrnr, ned.deily, ronaldoussoren
priority: normal
severity: normal
status: open
title: ApplePersistenceIgnoreState warning on macOS
type: behavior
versions: Python 3.6

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com