An addition to :ticket:`441` fixed in 0.9.5, we forgot to also filter
for the ``+`` sign in migration names which also breaks due to the relative
migrations feature.
Change-Id: I94d3882e84ba13e7569b47230dc9422a8ac6408c
Fixes: #445
from ..util import compat
_relative_destination = re.compile(r'(?:(.+?)@)?(\w+)?((?:\+|-)\d+)')
-_revision_illegal_chars = ['@', '-']
+_revision_illegal_chars = ['@', '-', '+']
class RevisionError(Exception):
--- /dev/null
+.. change::
+ :tags: bug, commands
+ :tickets: 441
+
+ An addition to :ticket:`441` fixed in 0.9.5, we forgot to also filter
+ for the ``+`` sign in migration names which also breaks due to the relative
+ migrations feature.
\ No newline at end of file
self.cfg, message="some message", rev_id="no@atsigns-ordashes"
)
+ assert_raises_message(
+ util.CommandError,
+ r"Character\(s\) '\+' not allowed in revision "
+ r"identifier 'no\+plussignseither'",
+ command.revision,
+ self.cfg, message="some message", rev_id="no+plussignseither"
+ )
+
def test_create_script_branches(self):
rev = command.revision(
self.cfg, message="some message", branch_label="foobar")