Skip to content
Snippets Groups Projects

Drop a Python 2 compatibility hack and fix handling of bool properties in GaudiPython

Merged Marco Clemencic requested to merge 276-jos-wrong-return-type into master

Going from type(v) is int to isinstance(v, int) in !1415 (merged) changed the way GaudiPython handles bool properties, because, surprisingly,

>>> isinstance(True, int)
True
>>> type(True) is int
False

Since the check was actually meant only for the special Python 2 type long and we do not support anymore Python 2, dropping that check fixes the issue reported in #276 (closed).

Closes #276 (closed)

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
  • Loading
  • Loading
  • Loading
Please register or sign in to reply
Loading