[pypy-dev] Question about "Completing 'os' module" (issue 833)

Mitchell Hashimoto mitchell.hashimoto at gmail.com
Sat Aug 27 09:00:52 CEST 2011


Sorry to ping the list again, but I've addressed the issues raised in the
issue to complete the "os.getlogin" feature. Is there any way I can get
another review to get this merged please?

Best,
Mitchell

On Mon, Aug 22, 2011 at 4:53 AM, Mitchell Hashimoto <
mitchell.hashimoto at gmail.com> wrote:

> Amaury,
>
> I've implemented one method (getlogin) and have created an issue + patch
> for it:
>
> https://bugs.pypy.org/issue841
>
> Best,
> Mitchell
>
> On Sun, Aug 21, 2011 at 2:20 PM, Amaury Forgeot d'Arc <amauryfa at gmail.com>wrote:
>
>> Hello,
>>
>> 2011/8/21 Mitchell Hashimoto <mitchell.hashimoto at gmail.com>
>>
>>> I noticed the 'os' module is incomplete, and I'd like to help complete
>>> this.
>>>
>>
>> You are very welcome!
>>
>>
>>> CPython does this by simply having these methods available on "posix"
>>> "nt" "os2" etc. and the "os" module imports those. It appears that PyPy does
>>> the same thing. I was able to successfully add 'getlogin' as practice, but I
>>> wanted to post here before going further. Some questions below:
>>>
>>> 1.) Should I mimic CPython and add the functionality to the OS-specific
>>> modules?
>>>
>>
>> Yes we should mimic CPython: fortunately these modules have different
>> names but share the same source file.
>> With CPython it's Modules/posixmodule.c, with PyPy it's in
>> pypy/module/posix.
>>
>>
>>> 2.) I don't have a Windows computer on hand. What is the standard
>>> practice for implementing some stdlib for one OS but not the other? Would
>>> PyPy accept this temporarily?
>>>
>>
>> Yes, no problem. In this case, I think it's best to let the test fail on
>> Windows so that someone may notice and fix it.
>>
>>
>>> 3.) There are many missing methods, to simplify implementation time and
>>> the patch, would it be okay to submit a patch for each stdlib method, so
>>> that this was built up over time?
>>>
>>
>>  Yes, smaller patches are easier to read and merge. I'd be happy to review
>> and commit them.
>>
>> --
>> Amaury Forgeot d'Arc
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/pypy-dev/attachments/20110827/e81b41ff/attachment.html>


More information about the pypy-dev mailing list