[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2016-05-08 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Fixed in issue23815. Opened issue26979 for documenting the catch.

--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

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



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2014-11-25 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

_tkinter classes are now heap types and they no longer have the __module__ 
attribute.

 import _tkinter
 _tkinter.TkappType.__module__
Traceback (most recent call last):
  File stdin, line 1, in module
AttributeError: __module__

See issue20204.

--
nosy: +serhiy.storchaka

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



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2014-02-03 Thread Mark Lawrence

Changes by Mark Lawrence breamore...@yahoo.co.uk:


--
nosy:  -BreamoreBoy

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



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2013-08-10 Thread Antoine Pitrou

Antoine Pitrou added the comment:

The first two patches (_tkinter_pep3121-384_v0.patch and 
_tkinter_pep3121-384_v1.patch) seemed to have the refcounts right, but Andrew's 
further patches lost the required Py_INCREF in the various new() functions (and 
the corresponding Py_DECREF in deallocs), which is the cause for the crash in 
#15667.

--
nosy: +pitrou

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2013-08-10 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 4d0c938870bc by Antoine Pitrou in branch 'default':
Fix refcounting issue with extension types in tkinter.
http://hg.python.org/cpython/rev/4d0c938870bc

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2013-04-19 Thread Andrew Svetlov

Andrew Svetlov added the comment:

No, PEP3121 patch is not ready yet but PEP384 has been applied.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2013-04-18 Thread Mark Lawrence

Mark Lawrence added the comment:

Is any more work needed on this issue or can it be closed?

--
nosy: +BreamoreBoy

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-11-08 Thread Robin Schreiber

Changes by Robin Schreiber robin.schrei...@me.com:


--
keywords: +pep3121 -patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-10-30 Thread Andrew Svetlov

Andrew Svetlov added the comment:

Amaury, you are right: 
PyTclObject_Type_slots[3].pfunc = PyObject_GenericGetAttr;
is not required.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-10-30 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 4eb6e07e8171 by Andrew Svetlov in branch 'default':
Issue #15721: apply PEP 384 Refactoring to tkinter module.
http://hg.python.org/cpython/rev/4eb6e07e8171

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-10-15 Thread Amaury Forgeot d'Arc

Amaury Forgeot d'Arc added the comment:

Andrew,

I have questions about the following part of commit bf9d118779f5:
+ PyTclObject_Type_slots[3].pfunc = PyObject_GenericGetAttr;

First, the 3 refers to the position of Py_tp_getattro in the array, which is 
a fragile thing IMO.

Then, this hack was not necessary before; why is it needed now?
IIRC on Windows a static initializer cannot contain dll-imported variables, but 
function pointers are OK.
Or do you have evidence of the contrary?

--
nosy: +amaury.forgeotdarc

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-10-15 Thread Andrew Svetlov

Andrew Svetlov added the comment:

Amaury, I completely agree with your objection. 
I've found this code in xxlimited.c and adapted to _tkinter source.
If that weird code can be removed I will do it.

I have no idea how we can catch/reproduce the problem, maybe Martin von Loewis 
can help as author of xxlimited.c code?

As I know almost nobody make PEP 384 compliant modules for now and maybe there 
are couple of dark corners at least in the docs.

See also #15650 for another question related to adaptation to pep3121.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-10-14 Thread Roundup Robot

Roundup Robot added the comment:

New changeset bf9d118779f5 by Andrew Svetlov in branch 'default':
Issue #15721: make _tkinter module pep384 compatible.
http://hg.python.org/cpython/rev/bf9d118779f5

--
nosy: +python-dev

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-10-07 Thread Andrew Svetlov

Andrew Svetlov added the comment:

The patch for current default branch.

--
Added file: http://bugs.python.org/file27470/_tkinter_pep3121-384_v7.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-10-07 Thread Andrew Svetlov

Andrew Svetlov added the comment:

The patch is huge, then I like to apply it in two steps: first implement pep 
384 than 3121.
Attached first patch.

--
Added file: http://bugs.python.org/file27475/_tkinter_pep384_v1.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-10-06 Thread Andrew Svetlov

Andrew Svetlov added the comment:

Update patch conforming to current _tkinter code.

--
Added file: http://bugs.python.org/file27457/_tkinter_pep3121-384_v1.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-10-06 Thread Andrew Svetlov

Andrew Svetlov added the comment:

I would to have all module state inside _tkinterstate structure.
static variables like tcl_lock, tcl_state, quitMainLoop, errorInCmd etc should 
be moved into _tkinterstate also.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-10-06 Thread Robin Schreiber

Robin Schreiber added the comment:

Before I submitted this patch, I used to have these variables inside the 
modulestate, which caused severe problems. I do not know the exact reason, but 
my guess is that these variables have to be globally available for every thread 
(tcl variables are used for thread synchronization arent they?). As the 
modulestate may change depending on the thread, one can no longer guarantee 
that every thread within the process is operating on the same variable. This 
might not be nessecary, however as I mentioned, the naive approach of putting 
the variables inside the modulestate did not work out for me.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-10-06 Thread Andrew Svetlov

Andrew Svetlov added the comment:

I'm trying to make patch following myself recommendations.
Looks good but not finished yet. Will publish it after all work done.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-10-06 Thread Andrew Svetlov

Andrew Svetlov added the comment:

Submit patch which store own state into module state.
Still not finished yet: need to add checks for ready state in every access to 
fields of module state structure.

--
assignee:  - asvetlov
Added file: http://bugs.python.org/file27458/_tkinter_pep3121-384_v2.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-10-06 Thread Andrew Svetlov

Changes by Andrew Svetlov andrew.svet...@gmail.com:


--
stage:  - patch review

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-10-06 Thread Andrew Svetlov

Andrew Svetlov added the comment:

Update patch to support TKINTER_PROTECT_LOADTK option.

--
Added file: http://bugs.python.org/file27460/_tkinter_pep3121-384_v3.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-10-06 Thread Andrew Svetlov

Andrew Svetlov added the comment:

Upload version which check if _tkinter module was destroyed (for example, if it 
was call from daemon thread runing Tk app when main thread is exiting with 
interpreter finalization).

--
Added file: http://bugs.python.org/file27464/_tkinter_pep3121-384_v4.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-08-20 Thread Andrew Svetlov

Changes by Andrew Svetlov andrew.svet...@gmail.com:


--
nosy: +asvetlov

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-08-18 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the tkinter 
module!
When running the test form inside Python.exe (tkinter._test()), the litte 
test-window is rendered correctly. However there are still some error 
messages popping up inside the python shell 
(I am running this on OS X 10.8):

 tkinter._test()
2012-08-18 12:46:24.775 python.exe[17410:707] speedup (null)
2012-08-18 12:46:24.776 python.exe[17410:707] ERROR: Unable to find method 
[_NSFullScreenTransition 
_startFullScreenTransitionForCGWindow:targetFrame:duration:].
2012-08-18 12:46:24.776 python.exe[17410:707] ERROR: Unable to find method 
[_NSFullScreenTransition 
_startEnterFullScreenTransitionForCGWindow:targetFrame:duration:].
2012-08-18 12:46:24.778 python.exe[17410:707] ERROR: Unable to find method 
[_NSFullScreenTransition 
startExitFullScreenTransitionForCGWindow:targetFrame:duration:].
[87221 refs]
 

I have no Idea how and where these are triggered.

--
components: Extension Modules
files: _tkinter_pep3121-384_v0.patch
keywords: patch
messages: 168504
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to tkinter module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26887/_tkinter_pep3121-384_v0.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-08-18 Thread Martin v . Löwis

Martin v. Löwis added the comment:

See

http://www.python.org/download/mac/tcltk/

It may be that using a different build of Tcl/Tk solves that problem.

--
nosy: +loewis

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15721] PEP 3121, 384 Refactoring applied to tkinter module

2012-08-18 Thread Ned Deily

Ned Deily added the comment:

What version of 10.8 are you seeing those messages with?  And do you see them 
without the patch applied?

--
nosy: +ned.deily

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15721
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com