Skip to content

Commit 39555a5

Browse files
committed
Report energy_correction in __repr__ of a Configuration.
This could help when reporting Configuration objects, and at least makes debugging less misleading. Without this offset, all your energies are wrong. See #2791. But this alone doesn't fix the issue since Configuration objects are not printed inte Arkane input files using __repr__. We should generally have better unit tests that __repr__ reproduces things.
1 parent 5d13e8c commit 39555a5

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

rmgpy/pdep/configuration.pyx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@ cdef class Configuration(object):
7373
if self.sum_states is not None: string += 'sum_states={0}, '.format(self.sum_states)
7474
string += 'active_k_rotor={0}, '.format(self.active_k_rotor)
7575
string += 'active_j_rotor={0}, '.format(self.active_j_rotor)
76+
if self.energy_correction != 0.0: string += 'energy_correction={0}, '.format(self.energy_correction)
7677
string += ')'
7778
return string
7879

0 commit comments

Comments
 (0)