Permalink
Browse files

doh, startup error hidden in 10% without coverage

  • Loading branch information...
1 parent d6c27ab commit 307f7bdd530f9908915fc9f15fcd82d50af2eb4f Whit Morriss committed Jan 4, 2012
Showing with 4 additions and 13 deletions.
  1. +4 −5 cheeseprism/index.py
  2. +0 −8 doc/example-index/index.html
View
@@ -175,15 +175,15 @@ def rebuild_leaf(event):
@subscriber(event.IIndexUpdate)
def bulk_update_index(event):
new_pkgs = event.index.update_data(event.datafile)
- notify_packages_added(new_pkgs)
+ notify_packages_added(event.index, new_pkgs)
-def notify_packages_added(new_pkgs, reg=None):
+def notify_packages_added(index, new_pkgs, reg=None):
if reg is None:
reg = get_current_registry()
for data in new_pkgs:
- reg.notify(event.PackageAdded(name=data['name'], version=data['version']))
+ reg.notify(event.PackageAdded(index, name=data['name'], version=data['version']))
@subscriber(ApplicationCreated)
@@ -200,8 +200,7 @@ def bulk_update_index_at_start(event):
template_env = settings['cheeseprism.index_templates']
index = IndexManager(file_root, template_env=template_env)
new_pkgs = index.update_data(datafile)
-
- notify_packages_added(new_pkgs, reg)
+ notify_packages_added(index, new_pkgs, reg)
class EnvFactory(object):
@@ -1,8 +0,0 @@
-\<html>
-<body>
-<h1>Package Index</h1>
-<ul>
-<li><a href="dummypackage/index.html">dummypackage</a>
-</ul>
-</body>
-</html>

0 comments on commit 307f7bd

Please sign in to comment.