mirror of
https://github.com/donnemartin/system-design-primer.git
synced 2025-12-14 17:08:56 +03:00
value --> values
Also fixed a copy-and-paste error
This commit is contained in:
@@ -25,7 +25,7 @@ class SalesRanker(MRJob):
|
||||
if self.within_past_week(timestamp):
|
||||
yield (category, product_id), quantity
|
||||
|
||||
def reducer(self, key, value):
|
||||
def reducer(self, key, values):
|
||||
"""Sum values for each key.
|
||||
|
||||
(foo, p1), 2
|
||||
@@ -74,4 +74,4 @@ class SalesRanker(MRJob):
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
HitCounts.run()
|
||||
SalesRanker.run()
|
||||
|
||||
Reference in New Issue
Block a user