Hello,<br><br><div class="gmail_quote">2011/8/21 Mitchell Hashimoto <span dir="ltr">&lt;<a href="mailto:mitchell.hashimoto@gmail.com">mitchell.hashimoto@gmail.com</a>&gt;</span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div>I noticed the &#39;os&#39; module is incomplete, and I&#39;d like to help complete this.</div></blockquote><div><br></div><div>You are very welcome!</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div>CPython does this by simply having these methods available on &quot;posix&quot; &quot;nt&quot; &quot;os2&quot; etc. and the &quot;os&quot; module imports those. It appears that PyPy does the same thing. I was able to successfully add &#39;getlogin&#39; as practice, but I wanted to post here before going further. Some questions below:</div>


<div><br></div><div>1.) Should I mimic CPython and add the functionality to the OS-specific modules?</div></blockquote><div><br></div><div>Yes we should mimic CPython: fortunately these modules have different names but share the same source file.</div>
<div>With CPython it&#39;s Modules/posixmodule.c, with PyPy it&#39;s in pypy/module/posix.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div>2.) I don&#39;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?</div>
</blockquote><div><br></div><div>Yes, no problem. In this case, I think it&#39;s best to let the test fail on Windows so that someone may notice and fix it.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">


<div>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?</div></blockquote><div><br></div><div>
Yes, smaller patches are easier to read and merge. I&#39;d be happy to review and commit them. </div></div><div><br></div>-- <br>Amaury Forgeot d&#39;Arc<br>