summaryrefslogtreecommitdiffstats
path: root/eopayment/sips.py
diff options
context:
space:
mode:
authorMathieu Comandon <strycore@gmail.com>2012-06-13 13:13:47 (GMT)
committerMathieu Comandon <strycore@gmail.com>2012-06-13 13:13:47 (GMT)
commitd23266b1ac3c39de865d48725489bce628f19384 (patch)
tree7d399b1e99e3f6668a597070299ed9ca530288ac /eopayment/sips.py
parent21706146c0dc373306d1bc38dedceaf0971d134e (diff)
downloadeopayment-d23266b1ac3c39de865d48725489bce628f19384.zip
eopayment-d23266b1ac3c39de865d48725489bce628f19384.tar.gz
eopayment-d23266b1ac3c39de865d48725489bce628f19384.tar.bz2
fixed calls to request script
Diffstat (limited to 'eopayment/sips.py')
-rw-r--r--eopayment/sips.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/eopayment/sips.py b/eopayment/sips.py
index d3b477f..f4dbddb 100644
--- a/eopayment/sips.py
+++ b/eopayment/sips.py
@@ -104,15 +104,15 @@ class Payment(PaymentCommon):
def __init__(self, options, logger=LOGGER):
self.options = options
self.logger = logger
- logger.debug('initializing sips payment class with %s' % options)
+ self.logger.debug('initializing sips payment class with %s' % options)
def execute(self, executable, params):
if PATHFILE in self.options:
params[PATHFILE] = self.options[PATHFILE]
- executable = os.path.join(self.options[BINPATH], executable)
+ executable = os.path.join(self.options.pop(BINPATH), executable)
args = [executable] + ["%s=%s" % p for p in params.iteritems()]
self.logger.debug('executing %s' % args)
- result, _ = subprocess.Popen(args, executable=executable,
+ result,_ = subprocess.Popen(' '.join(args),
stdout=subprocess.PIPE, shell=True).communicate()
if result[0] == '!':
result = result[1:]
@@ -138,6 +138,7 @@ class Payment(PaymentCommon):
params['customer_email'] = email
if next_url:
params['normal_return_url'] = next_url
+ params.pop('binpath')
code, error, form = self.execute('request', params)
if int(code) == 0:
return params[ORDER_ID], HTML, form