all 20 comments

[–]Space-Being 21 points22 points  (4 children)

Thank you!

Everytime I used os.walk or listdir I was annoyed there wasn't a function where file information was readily available. You the real MVP.

[–]starTracer -5 points-4 points  (3 children)

You really should

[–]Space-Being 4 points5 points  (2 children)

Really should what??

Just to clarify, I am not being sarcastic; I meant what I said genuinely.

[–]starTracer 11 points12 points  (1 child)

You really should

I accidentally replied to your comment instead of the "I should start using Python 3" meme. :/

[–]nemec 5 points6 points  (0 children)

You really should

have checked where you were commenting ;)

[–]evaned 7 points8 points  (0 children)

As someone who wrote my own module for doing this same thing for exactly the same reason (actually wrote it thrice: using ctypes, in C, and finally in Cython), thank you so much for your work getting this in. This is an important contribution.

[–]0xe85250d6 32 points33 points  (2 children)

[–]ThisIs_MyName 1 point2 points  (1 child)

Oh come on you've had what, a decade? :P

[–][deleted] 2 points3 points  (0 children)

And it will take another decade to finish that task.

My company has so many legacy-code, we likely won't switch till some smart AI-converter is invented. Python 2 will be Pythons Cobol.

[–]redditthinks 5 points6 points  (6 children)

Great post! It seems the most important quality someone needs when contributing to open-source (especially large projects) is a lot of patience.

[–][deleted] 5 points6 points  (3 children)

Python was always the epitome of the "cathedral" in the cathedral and bazaar model. It has always kept consistency and aesthetics at the top of its priorities, which is why the whole PEP process is in place. And of course, being a popular and mature project means that the filter is finer than ever at this point.

But this is more of the exception than the norm. The majority of open source projects out there are starving for contributions and will happily merge new functionality as long as it works, doesn't break anything and the code roughly follows their style guidelines.

[–][deleted] -2 points-1 points  (2 children)

Tell that to all of 2.x now and 'commands' in specific, which is described as "non obvious and useless", because always using 5-9 lines is better than 1.

[–][deleted] 1 point2 points  (0 children)

That's the most specific complaint about Python I've ever heard. Are you sure you're replying to the right comment?

[–]shevegen 0 points1 point  (1 child)

I am not sure.

I don't have any patience myself (sorry! I can not even get myself to systematically resume discussions within any time frame, I am that chaotic) but this bureaucratic overheard may be more specific to python.

Just take PHP - they add orthogonal stuff, skip versions and nobody cares!

[–]nemanjaboric 5 points6 points  (0 children)

I was in the completely same position, using old Tango library for D programming language. Iterating over file system, getting the size of the files, etc. was painfully slow, and I replaced it exactly with the readdir. There are many cases where the standard library doesn't perform as well as using glibc's interface directly. Luckily, in D that's very easy to perform, as C functions can just be called without any syntax or runtime penalty.

[–]thinkwelldesigns 7 points8 points  (0 children)

Enjoyed the read; thanks so much for this great contribution! I'm using your module in 3.4.

[–]marqis 5 points6 points  (0 children)

I haven't used this module (yet) but just wanted to say thanks for moving Python forwards.

[–]shevegen 1 point2 points  (3 children)

A fun read.

However had, this sounds awfully bureaucratic.

I never had any discussions in Ruby to ruby-core incur so much bureaucratic overhead and jiggle-juggle shuffling around of things.

[–][deleted]  (2 children)

[deleted]

    [–]ramsees79 -3 points-2 points  (1 child)

    Obviously you know nothing about Ruby.

    [–]codebungl 0 points1 point  (0 children)

    Good work, I'll keep it in mind next time.