[issue10784] os.getpriority() and os.setpriority()

2011-02-25 Thread Antoine Pitrou
Antoine Pitrou added the comment: Indeed. -- status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscr

[issue10784] os.getpriority() and os.setpriority()

2011-02-25 Thread Senthil Kumaran
Senthil Kumaran added the comment: On Sat, Feb 26, 2011 at 12:11:10AM +, Antoine Pitrou wrote: > if err.errno != errno.EACCESS: > AttributeError: 'module' object has no attribute 'EACCESS' That was one 'S' too many. Should be errno.EACCES Looks like Antoine has fixed it in r88627. ---

[issue10784] os.getpriority() and os.setpriority()

2011-02-25 Thread Antoine Pitrou
Antoine Pitrou added the comment: == ERROR: test_set_get_priority (test.test_os.ProgramPriorityTests) -- Traceback (most recent call last): File "/home/build

[issue10784] os.getpriority() and os.setpriority()

2011-02-25 Thread Giampaolo Rodola'
Giampaolo Rodola' added the comment: Misc/NEWS updated in r88609. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubsc

[issue10784] os.getpriority() and os.setpriority()

2011-02-25 Thread Giampaolo Rodola'
Giampaolo Rodola' added the comment: Committed in r88608 including Py_RETURN_NONE and Py_BEGIN/END_ALLOW_THREADS changes. -- resolution: -> fixed status: open -> closed ___ Python tracker ___

[issue10784] os.getpriority() and os.setpriority()

2011-01-10 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- stage: -> patch review ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://m

[issue10784] os.getpriority() and os.setpriority()

2011-01-10 Thread Martin v . Löwis
Martin v. Löwis added the comment: You should use begin/end allow threads when the system call might block. To get an indication, trace through the kernel code of some system; my guess is that these are typically non-blocking (i.e. return immediately) - but I might be wrong. --

[issue10784] os.getpriority() and os.setpriority()

2011-01-10 Thread Giampaolo Rodola'
Giampaolo Rodola' added the comment: Question: should Py_BEGIN/END_ALLOW_THREADS be used around getpriority() and setpriority() calls? It's still not clear to me when to use them exactly. -- ___ Python tracker __

[issue10784] os.getpriority() and os.setpriority()

2010-12-28 Thread Martin v . Löwis
Martin v. Löwis added the comment: > Looks good. Would there be a point in making any of the parameters optional? No. The API should look exactly as it does on the system level. Anybody calling these functions should know how call them. -- ___ Pyth

[issue10784] os.getpriority() and os.setpriority()

2010-12-28 Thread Georg Brandl
Georg Brandl added the comment: Looks good. Would there be a point in making any of the parameters optional? -- nosy: +georg.brandl ___ Python tracker ___ _

[issue10784] os.getpriority() and os.setpriority()

2010-12-27 Thread Ross Lagerwall
Ross Lagerwall added the comment: Patch looks good, just one thing: In setpriority(), it should be possible to use the Py_RETURN_NONE; macro instead of INCREFing manually. -- components: +Extension Modules nosy: +rosslagerwall type: -> feature request ___

[issue10784] os.getpriority() and os.setpriority()

2010-12-27 Thread Giampaolo Rodola'
Changes by Giampaolo Rodola' : -- nosy: +christian.heimes ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http:

[issue10784] os.getpriority() and os.setpriority()

2010-12-27 Thread Giampaolo Rodola'
Giampaolo Rodola' added the comment: Forgot to attach the patch. -- Added file: http://bugs.python.org/file20177/getsetpriority.patch ___ Python tracker ___

[issue10784] os.getpriority() and os.setpriority()

2010-12-27 Thread Giampaolo Rodola'
New submission from Giampaolo Rodola' : After having implemented a similar thing in psutil ( http://code.google.com/p/psutil/issues/detail?id=142 ) I decided to contribute a patch for Python which exposes getpriority() and setpriority() POSIX calls in the os module. They can be used to get/se