Fix a compatibility issue with our custom rbssh plugin for Bazaar.
Review Request #11755 — Created July 28, 2021 and submitted
We bundle a plugin for Bazaar that enables rbssh as a SSH transport.
This plugin has been the source of some frustration around broken unit
tests, and potentially issues in certain production environments.
The plugin made use of a Django import, just to get access to
the sole purpose of
six.text_type. The problem was, if Bazaar was
installed system-wide, and Review Board was installed in a virtualenv,
SSH operations would fail.
bzrlocally would invoke
bzron the other
side of the SSH connection, but outside of the virtualenv, and the
Django import could fail.
This import isn't really useful. It's easy enough to
number we wanted into a string. This change does that, simplifying the
code and preventing this common problem.
Encountered this frequently with unit tests. They now pass.