Browse Source

Use parser error rather than systemexit exception

tags/nilmtools-1.0
Jim Paris 11 years ago
parent
commit
d919a73387
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      src/filter.py

+ 2
- 2
src/filter.py View File

@@ -142,12 +142,12 @@ class Filter(object):
self._client_dest = Client(args.dest_url)

if (not self.interhost) and (args.srcpath == args.destpath):
raise Exception("source and destination path must be different")
self._parser.error("source and destination path must be different")

# Open and print info about the streams
self.src = get_stream_info(self._client_src, args.srcpath)
if not self.src:
raise Exception("source path " + args.srcpath + " not found")
self._parser.error("source path " + args.srcpath + " not found")

self.dest = get_stream_info(self._client_dest, args.destpath)
if not self.dest:


Loading…
Cancel
Save