Skip to content

Commit

Permalink
some other fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
benoitc committed May 7, 2011
1 parent 5a0c8ce commit e4d6177
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 7 deletions.
2 changes: 1 addition & 1 deletion couchapp/autopush/command.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ def run(self):
log.info("unhandled exception in main loop:\n%s" %
traceback.format_exc())
sys.exit(-1)
observer.join()
self.observer.join()

def halt(self):
self.observer.stop()
Expand Down
5 changes: 1 addition & 4 deletions couchapp/autopush/watchdog/observers/kqueue.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,7 @@
"""

from __future__ import with_statement
from ..utils import \
platform #, has_attribute
from ..utils import platform

if platform.is_bsd() or platform.is_darwin():
import threading
Expand All @@ -94,8 +93,6 @@
import os

# See the notes for this module in the documentation above ^.
#import select
#if not has_attribute(select, 'kqueue') or sys.version_info < (2, 7, 0):
if sys.version_info < (2, 7, 0):
import couchapp.autopush._select as select
else:
Expand Down
5 changes: 3 additions & 2 deletions couchapp/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
import codecs
from hashlib import md5
import imp
import inspect
import logging
import os
import re
Expand Down Expand Up @@ -396,7 +397,7 @@ def expandpath(path):
def load_py(uri, cfg):
if os.path.exists(uri):
name, ext = os.path.splitext(os.path.basename(uri))
script = imp.load_source(name, self.script_uri)
script = imp.load_source(name, uri)
else:
if ":" in uri:
parts = uri.rsplit(":", 1)
Expand All @@ -418,7 +419,7 @@ class ShellScript(object):
scripts in any languages """

def __init__(self, cmd):
self.cmd = uri
self.cmd = cmd

def hook(self, *args, **options):
cmd = self.cmd + " "
Expand Down

0 comments on commit e4d6177

Please sign in to comment.