Reputation
Top tag
Next privilege 200 Rep.
See reduced ads
Badges
8
Newest
 Critic
Impact
~587 people reached

Jan
8
comment Why Was Python Written with the GIL?
@Muposat I don't disagree with you - one of the reasons I'm unhappy with Python's threading is that I'm in a similar situation - we have a multiprocessing queue consumer that often maxes out the CPU - and it works great as long as there's no dependencies and little communication between workers. However, giving all processes access to shared mutable variables is nigh impossible if performance is a consideration. Not a problem for a queue consumer but a real hinderance elsewhere.
Nov
22
comment Why Was Python Written with the GIL?
Ok, we're getting off-topic but... How would you go about implementing a merge sort efficiently in python? On linux or windows? If the language has limitations, don't go blaming the OS for not covering up the inadequacies. In any case, shall we delete these comments to remove clutter?
Nov
22
comment Why Was Python Written with the GIL?
@Zelphir so you consider anything that needs multiple threads "high performance"? As to who would use it on windows, millions of people without a chip on their shoulder / religious zealotry for with their OS. Windows is excellent in certain circumstances, awful in others. Same applies linux, OSX and pretty much everything else.
Oct
15
comment Why Was Python Written with the GIL?
@alcalde Well if Guido says it's ok, it must be fine... Multiprocessing on windows has a much higher overhead than on linux, or perhaps that just doesn't count? Also, see if you can get the same perfomance on (say) a large merge sort using multiple processes as you can using multiple threads on a non-GIL interpreter. I'm not saying multiprocessing doesn't have its place - it does - but it's not the right answer to every problem, no matter how much some "pythonistas" want it to be.
Oct
6
comment Why Was Python Written with the GIL?
That's the same argument as Java's lack of unsigned numerical types - the developers think everyone else is dumber than they are...
Oct
6
comment Why Was Python Written with the GIL?
@alcalde Only if you don't know what you're doing and/or you don't want your threads to be able to work cooperatively/communicate. Otherwise, it's a royal pain in the backside, especially considering the overhead of launching a new process on some OSes. We have servers with 32 cores, so to utilise them fully in CPython I'd need 32 processes. That's not a "good solution" it's a hack to work around CPython's inadequacies.
Oct
6
comment Why Was Python Written with the GIL?
Can't help feeling that like Java's lack of unsigned numerics, it was intended to prevent people who don't know what they're doing shooting themselves in the foot. Unfortunately, anyone who does know what they're doing gets a deficient language, which is a real shame because Python rocks in so many other ways
Mar
30
comment Difference between '\n' and '\r\n'
@DavidThornley Because \r\n is more likely to work cross-platform (\r for older macs, \r\n for windows and \n for *nix).
Mar
30
comment Difference between '\n' and '\r\n'
@dan04 Opening/displaying a files using \n is easy, but what happens when you save it? Either you change all \n to \r\n and break the the Principle of Least Astonishment, or you attempt to remember which line endings this particular file uses (what if it's mixed?). There isn't a particularly pretty answer without making notepad more complex than it is. That's what WordPad is for (and it does correctly handle \n). It's just unfortunate that WordPad has other usability issues...
Mar
30
comment Difference between '\n' and '\r\n'
Printers were so much better back then; youtube.com/watch?v=lTxqQ3ALVcU (Not at actually printing of course)
Feb
18
awarded  Critic
Feb
18
comment Why aren't there explicit access modifiers in Python:
@Vector It's hands-down the best glue language I've come across so far, but I wouldn't use it build much more than a service which coordinates other, more complex processes. The woeful threading model alone makes it unsuitable.
Nov
26
awarded  Excavator
Nov
26
revised How do I convince my teammates that we should not ignore compiler warnings?
Grammar and a trivial change to skip the length filter (man I miss my SO rep)
Nov
26
suggested approved edit on How do I convince my teammates that we should not ignore compiler warnings?
Oct
18
comment Keep a programming language backwards compatible vs. fixing its flaws
To expand on @tieTYT's comment, Python's 2to3 tool is largely acceptable but not perfect and misses optimisations. Unfortunately, if you're writing libraries not apps, using it means you can no longer support Python2 without either 2 different codebases or accepting that your Python3 code will be suboptimal until you can drop Python2 support. This is one of the major reasons so many libraries have been so slow porting over. Six years on and it's still hard to get good library support, which has crippled adoption of Python3
Sep
24
awarded  Autobiographer
Sep
19
comment How to fix poorly designed software?
"Open Source projects are a very good source". Sometimes. I've seen some truly excellent and innovative code in OSS but at the same time, I've seen some really awful architectures that are there because features have just been bolted on ad-infinitum. Patterns & Practicies is definitely worth a read (don't worry if you don't understand all of them to start with, you'll start to see problems where you think "aha!")
May
15
comment How to avoid “DO YOU HAZ TEH CODEZ” situations?
I had a similar situation but the asker would do a round-robin of other devs "I've got this far, can you help with the next bit"... After sitting him down and having a frank discussion, he admitted he only wanted enough time in the job on his CV to go for a ministerial position in S. Africa... He even asked me for a LinkedIn recommendation when he left the company!
Oct
23
comment Why aren't there explicit access modifiers in Python:
@keppla That just means that the implementation is questionable, it doesn't mean it's the way it should be.