aboutsummaryrefslogtreecommitdiff
path: root/.gitignore
diff options
context:
space:
mode:
authorDaniel Axtens <dja@axtens.net>2016-11-16 16:58:44 +1100
committerStephen Finucane <stephen@that.guru>2016-11-18 01:01:01 +0000
commit25a7aaec437bf39306563e4c62d7fcc95ddbeade (patch)
tree1fc9106e442ea65eb2f194249d64e58b9bf15924 /.gitignore
parentc3137fe212d0eeaaf99a331d8d05cfac37896d38 (diff)
downloadpatchwork-25a7aaec437bf39306563e4c62d7fcc95ddbeade.tar
patchwork-25a7aaec437bf39306563e4c62d7fcc95ddbeade.tar.gz
Fix parsing of un-numbered messages in series
Say we are sent the following: - [PATCH 0/2] A sample series - [PATCH 1/2] test: Add some lorem ipsum - Random message with diff We expect that: 1) we parse normally without errors 2) we get a series with a cover letter and a patch 3) the random message is orphaned What happens is that we get an integrity error, boiling down to: (1048, "Column 'number' cannot be null") This is caused because we believe that the random message belongs to the series because of the headers, but because there are no numbers in the Subject, we pass "None" into the number field of SeriesPatch. That turns into a null, and rightly hits an integrity error. Fix this by requring that a message has a series _and_ a number before we try to add it to the series. Add a test to verify correctness. Reported-by: Daniel Wagner <wagi@monom.org> Signed-off-by: Daniel Axtens <dja@axtens.net> Reviewed-by: Stephen Finucane <stephen@that.guru>
Diffstat (limited to '.gitignore')
0 files changed, 0 insertions, 0 deletions