Top "Anti-patterns" questions

A programming anti-pattern is a commonly used solution to a specific programming problem, often claiming being an actual design pattern.

Python: is using "..%(var)s.." % locals() a good practice?

I discovered this pattern (or anti-pattern) and I am very happy with it. I feel it is very agile: def …

python string design-patterns anti-patterns
Are set-only properties bad practice?

I have some C# code that loves to create properties that have setters but no getters. To me this seems …

c# anti-patterns
Can the Diamond Problem be really solved?

A typical problem in OO programming is the diamond problem. I have parent class A with two sub-classes B and …

design-patterns oop anti-patterns
Ravioli code - why an anti-pattern?

I recently came across a term 'God object' which was described as an 'anti-pattern'. I'd heard of bad coding practices, …

anti-patterns
How do I NOT use DependencyResolver.Current.GetService(...) in this situation

Following the advice I have been given in this thread [Ninject UOW pattern, new ConnectionString after user is authenticated I …

c# dependency-injection ninject anti-patterns service-locator
Extending singletons in PHP

I'm working in a web app framework, and part of it consists of a number of services, all implemented as …

php inheritance singleton anti-patterns
Concrete examples on why the 'Anemic Domain Model' is considered an anti-pattern

I apologize if this is a duplicate, but I couldn't find any concrete examples on the topic in related questions. …

java architecture domain-driven-design anti-patterns anemic-domain-model
Is global constants an anti-pattern?

I've always thought having a class just for the sake of holding constants is a bad design. But recently, I've …

design-patterns oop anti-patterns
Dependency Injection best practices and anti-patterns

I'm relatively unskilled in Dependency Injection, and I'd like to learn some best practices and anti-patterns to use and avoid …

language-agnostic dependency-injection anti-patterns
the significance of java RMI please?

Why do people use RMI, or when should I use RMI? I read those tutorials about RMI on oracle's website.…

java computer-science rmi software-design anti-patterns