From f541163fca6e7644a631b270143df35374dabb13 Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Tue, 29 May 2012 08:48:36 -0400 Subject: [PATCH] Oops, Calibrator.save_results should be a static method. Without this fix, you get errors like: Traceback (most recent call last): File "/usr/bin/calibcant-calibrate.py-2.7", line 46, in sys.exit(main(sys.argv[1:])) File "/usr/bin/calibcant-calibrate.py-2.7", line 36, in main k,k_s,data = calibrator.calibrate(filename=filename) File "/usr/lib/python2.7/site-packages/calibcant/calibrate.py", line 495, in calibrate spring_constant=k, spring_constant_deviation=k_s, **data) TypeError: save_results() got multiple values for keyword argument 'filename' --- calibcant/calibrate.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/calibcant/calibrate.py b/calibcant/calibrate.py index 964ee24..b6a304b 100644 --- a/calibcant/calibrate.py +++ b/calibcant/calibrate.py @@ -594,4 +594,4 @@ class Calibrator (object): data[name].append(loader(group=cwg)) return data -Calibrator.save_results = _save_results +Calibrator.save_results = staticmethod(_save_results) -- 2.26.2