All challenges
Code AnalysisBeginner 60s

Abstraction leakage in repository

class OrderRepository: def query(self): return self.db.orders # returns ORM Query object # service orders = repo.query().filter(status='PAID').order_by('created').all() for o in orders: o.discount = o.total * 0.1 What architectural problem does returning the ORM query object from the repository cause?

Think you can answer under pressure?

Get matched and answer live questions in 3-minute 1v1 battles. Elo ranking, badge tiers and bragging rights on the line.

Play this in a 3-minute battle