Reputation
1,702
Next privilege 2,000 Rep.
Edit questions and answers
Badges
6 13
Newest
 Yearling
Impact
~42k people reached

Jan
22
comment How to design a complex REST API considering DB performance?
You didn't describe an API, you just recapitulated the raw database schema in a heavyweight wrapper. Even your premise shows the exposed bare-metal: "Let's say my application will provide training for Companies"; company cannot be trained. What application does the API really want to talk about?
Jan
22
comment Is it a good practice to avoid constants by using getters?
I question the premise: User.getRole().getCode() is already an unpleasant read, comparing a Code to a Role makes it yet more ungainly.
Jan
5
comment Convention for exception argument order
Logging is where the majority of the information should be; put another way, there isn't enough information present at the location of the exception to tell a complete story. Don't go overboard with exception annotations, they can't help as much as you might want.
Jan
2
comment Is Python's inheritance an “is-a” style of inheritance or a compositional style?
All else being equal, multiple inheritance is hard to reason about. (Aaron made the same point in his answer, this is just more succinct and closer to the affected code.)
Nov
15
comment 'import module' vs. 'from module import function'
So how is if sys_argv: any better than if sys.argv:? I know what the second statement means, I have no idea what the first form means without backtracking to the bizarre import.
Sep
15
awarded  Yearling
Sep
14
answered What is the Pythonic convention for working with an object similar to an existing variable?
Jul
27
comment Is throwing new RuntimeExceptions in unreachable code a bad style?
People will continue to believe that wildcard catches which handle nothing are actually exception handlers. Your version disregards that flawed assumption by not pretending to handle that which it can't. The caller of retrieveUserMailConfiguration() expects to get something back. If that function cannot return something reasonable, it should fail fast and loudly. It's as if the other answers saw no issue with catch(Exception) which is an odious code-smell.
Jul
10
comment Do I have to distribute my commercial source code that links GPL software if I only use this commercial software to provide a reporting service?
That's a good question for your corporate lawyer. Unfortunately we don't give legal opinions here because even if some are lawyers, they are not your lawyer.
Jul
9
answered OODesign: Data Structure which calls algorithm on insert
Jul
5
comment How to extract the active code path from a complex algorithm
I fear that if you find a code path that is exercised by one input (recipe) that changing only that code path will break many others; convoluted code often has obnoxious inter-dependencies. There is also a whiff of undecidability which smells like an analysis for recipe A will not reveal all of the code paths needed for recipe B.
Jul
5
comment How to develop front end (UI) for my Django website
First, make it work, then make it pretty.
Jul
5
comment How to develop front end (UI) for my Django website
+1 "no sane web-developer"
May
27
comment Avoiding lot of roles implementation in same object
It's Java, it's supposed to be obscenely verbose.
May
21
comment Can one edit a built-in Python module?
There is an answer below by Michael0x2a that covers the fine points, but the simple version is: don't do that. If I am reading your code and see a call to math.polynomial_roots() me and my interpreter will become confused. That's a Bad Thing.
Apr
24
awarded  Informed
Feb
28
comment Am I designing software or architecting software?
In English, any noun (Architect) can be verbed (Architecting) but, to my ear, "architecting" is an ear-grating business neologism. I tend to assume that an engineer who claims he is "architecting" to either be presumptuous or enjoys long words that have a more concise synonym.
Feb
28
comment Java write to text file from multiple threads
I suggest you read about synchronization and perhaps thread synchronization questions on StackOverflow
Feb
28
comment Bad sign if nobody can comprehend one's code?
Programmers who don't understand that communicating with other people is the main purpose of source-code probably don't deserve their title.
Feb
25
comment Write a (good) code convention for c#
Yes, do steal one. A quick search turned up a dozen wheels that you don't have to re-invent.