Skip to content

Fix the + operator that doesn't work with python dict_keys objects

Evan Goetz requested to merge fix-operator into master

We've been seeing this error message:

  File "/home/detchar/etc/ligo-channel-lists/tools/clf-check", line 221, in <module>
    for key in set(missing.keys()+bad_rates.keys()):
TypeError: unsupported operand type(s) for +: 'dict_keys' and 'dict_keys'

This changes the + operator to |, which does what I think the intended operation was supposed to do, that is join the two dict_keys objects.

Merge request reports

Loading