Message10028
Hello! This bug is biting my application which uses Py.setSystemState(). I was wondering what would be the best fix and I wonder if the following would be OK:
We change the code to be that of msg9795 (no weak values) but then we store the provided *PySystemState* to a WeakReference with a ReferenceQueue.
And then we use the associated ReferenceQueue to detect when the PySystemState is garbage collected so that we can remove the associated ThreadState from the map...
BTW, I was never really clear whether sharing the PySystemState between two threads was safe or not (this is where documenting the API would be helpful!). |
|
Date |
User |
Action |
Args |
2015-05-07 12:01:59 | JanVok | set | messageid: <1431000119.82.0.634356460255.issue2321@psf.upfronthosting.co.za> |
2015-05-07 12:01:59 | JanVok | set | recipients:
+ JanVok, zyasoft, kevinmcmurtrie |
2015-05-07 12:01:59 | JanVok | link | issue2321 messages |
2015-05-07 12:01:59 | JanVok | create | |
|