kassonlab / gmxapi

(outdated) fork of https://gitlab.com/gromacs/gromacs
http://gmxapi.org/
Other
52 stars 13 forks source link

Invalid attempt to use Context.rank in Context.work setter. #232

Closed eirrgang closed 5 years ago

eirrgang commented 5 years ago

When the Context.work setter fails to find a factory function for an operation, it tries to issue a log message on only the master rank. But in the current implementation, an MPI communicator is not acquired (if at all) until the work width is known and the Session is launching. This prevents useful handling of the error condition and instead creates a confusing Type error.

We should remove the check from Context.work. It should be implemented in the logging infrastructure instead, anyway.