[Pkg-debile-commits] [debile-master] 02/03: flake8 clean up of unused variables and undefined variables
Vasudev Kamath
vasudev-guest at moszumanska.debian.org
Sun Mar 2 13:56:57 UTC 2014
This is an automated email from the git hooks/post-receive script.
vasudev-guest pushed a commit to branch master
in repository debile-master.
commit 334d1220ff5ed6abfa52a4983de51a9237b6ffb5
Author: Vasudev Kamath <kamathvasudev at gmail.com>
Date: Sun Mar 2 19:22:29 2014 +0530
flake8 clean up of unused variables and undefined variables
* enabled import of debilemaster.mail.send_mail
* replace job_id with job submit_report function
* comment out unsed session and j variable in submit_report
* Drop unused exception variable e in authenticate_user and
authenticate_machine function.
---
debilemaster/server.py | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/debilemaster/server.py b/debilemaster/server.py
index f0c95e2..d919c21 100644
--- a/debilemaster/server.py
+++ b/debilemaster/server.py
@@ -25,7 +25,7 @@ from sqlalchemy.orm.exc import NoResultFound
from debilemaster.orm import Machine, Job, Source, Binary, User
from debilemaster.config import Config
-#from debilemaster.mail import send_mail
+from debilemaster.mail import send_mail
from debilemaster.archive import UserRepository
from debilemaster.utils import listize
@@ -389,8 +389,8 @@ class DebileMasterInterface(object):
job - job ID this relates to
failed - was it able to complete properly
"""
- session = Session()
- j = session.query(Job).filter(Job.id == job_id).one()
+ # session = Session()
+ # j = session.query(Job).filter(Job.id == job).one()
package = job.get_package()
#report = Report(report=report,
# builder=get_builder(),
@@ -463,7 +463,7 @@ class DebileMasterAuthMixIn(SimpleXMLRPCRequestHandler):
if user.password == password:
NAMESPACE.user = user
return True
- except NoResultFound, e:
+ except NoResultFound:
logging.error("User claiming name %s does not exist", user_login)
return False
@@ -478,7 +478,7 @@ class DebileMasterAuthMixIn(SimpleXMLRPCRequestHandler):
machine.last_ping = dt.datetime.utcnow()
session.commit()
return True
- except NoResultFound, e:
+ except NoResultFound:
logging.error("Machine claiming name %s does not exist",
machine_name)
return False
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-debile/debile-master.git
More information about the Pkg-debile-commits
mailing list