Oops, Calibrator.save_results should be a static method.
authorW. Trevor King <wking@tremily.us>
Tue, 29 May 2012 12:48:36 +0000 (08:48 -0400)
committerW. Trevor King <wking@tremily.us>
Tue, 29 May 2012 12:48:41 +0000 (08:48 -0400)
commitf541163fca6e7644a631b270143df35374dabb13
tree1078a48f03331eeac6d77725c0b86c761837326d
parent877eb8a130324bc1edd92da328eb43bc734d842f
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 <module>
      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