Skip to content
Snippets Groups Projects

Feat/boolarg convert to false

Merged Karim Ahmed requested to merge feat/boolarg_convert_to_false into master
1 unresolved thread

@karnem This MR enable turning a Boolean in the calibration configurations from a default true to false.

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Karim Ahmed resolved all discussions

    resolved all discussions

  • Karim Ahmed added 1 commit

    added 1 commit

    • d209427b - adding the -no option to calibrate.py

    Compare with previous version

  • 336 # forcing to convert a bool to False.
    337 # Otherwise leave the default value from the notebook
    338 # or convert to true if the bool arg is given.
    339 if consolize_name("--no-{}".format(p.name)) in sys.argv:
    340 pars_group.add_argument("--{}".format(consolize_name(p.name)),
    341 action="store_false",
    342 default=False,
    343 help=helpstr,
    344 required=required)
    345 sys.argv.remove(consolize_name("--no-{}".format(p.name)))
    346 else:
    347 pars_group.add_argument("--{}".format(consolize_name(p.name)),
    348 action="store_true",
    349 default=default,
    350 help=helpstr,
    351 required=required)
    • @karnem This is the main part in adding an option for converting a bool arg from True to False.

      The other changes were done automatically by pycharm and is not related.

      Sorry for that.

    • Please register or sign in to reply
  • Karim Ahmed added 1 commit

    added 1 commit

    Compare with previous version

  • LGTM.

  • Karim Ahmed added 1 commit

    added 1 commit

    • 44513be0 - revert max-pulses in available options change

    Compare with previous version

  • merged

  • Karim Ahmed mentioned in commit 9b9b4eda

    mentioned in commit 9b9b4eda

  • Please register or sign in to reply
    Loading