Ticket #3786 (closed defect: fixed)
extfs: rpm helper doesn't always preserve <backslash> in some fields, making one test fail
Reported by: | mooffie | Owned by: | mooffie |
---|---|---|---|
Priority: | major | Milestone: | 4.8.20 |
Component: | tests | Version: | master |
Keywords: | Cc: | ||
Blocked By: | Blocking: | #3781 | |
Branch state: | merged | Votes for changeset: | committed-master |
Description
(I'll publish a branch soon.)
Change History
comment:2 Changed 8 years ago by mooffie
(comment:1 was copied by Trac from the blocked ticket. Don't be confused by it.)
comment:3 Changed 8 years ago by andrew_b
In addition to this rpm bug, rpm.custom.output doesn't contain some items.
Testing /home/andrew/work.c/mc/mc-3784_extfs_tester_diff/tests/src/vfs/extfs/helpers-list/data/rpm.custom.input /home/andrew/work.c/mc/mc-3784_extfs_tester_diff/tests/src/vfs/extfs/helpers-list/data/rpm.custom.output /tmp/.private/andrew/rpm.actual-parsed-output.KldpnYMV differ: char 42, line 1 ERROR: rpm has produced output that's different than the expected output. Expected output (after parsing): /home/andrew/work.c/mc/mc-3784_extfs_tester_diff/tests/src/vfs/extfs/helpers-list/data/rpm.custom.output Actual output (after parsing): /tmp/.private/andrew/rpm.actual-parsed-output.KldpnYMV This might mean that a bug was introduced into rpm. Or that a bug was fixed. Please compare the files. If the actual output is the correct one, just copy the latter file onto the former (and commit to the git repository). ------------ diff of the expected output vs the actual output: ------------- --- /home/andrew/work.c/mc/mc-3784_extfs_tester_diff/tests/src/vfs/extfs/helpers-list/data/rpm.custom.output 2017-01-22 08:37:04.000000000 +0300 +++ /tmp/.private/andrew/rpm.actual-parsed-output.KldpnYMV 2017-03-08 09:14:50.000000000 +0300 @@ -1,3 +1,3 @@ --r--r--r-- 1 0 0 539 2017-01-05 00:00:00 HEADER +-r--r--r-- 1 0 0 597 2017-01-05 00:00:00 HEADER -r-xr-xr-x 1 0 0 39 2017-01-05 00:00:00 INSTALL -r-xr-xr-x 1 0 0 39 2017-01-05 00:00:00 UPGRADE @@ -14,4 +14,5 @@ -r--r--r-- 1 0 0 0 2017-01-05 00:00:00 INFO/VENDOR -r--r--r-- 1 0 0 0 2017-01-05 00:00:00 INFO/DESCRIPTION +-r--r--r-- 1 0 0 0 2017-01-05 00:00:00 INFO/SUMMARY -r--r--r-- 1 0 0 0 2017-01-05 00:00:00 INFO/SCRIPTS/PRETRANS -r--r--r-- 1 0 0 0 2017-01-05 00:00:00 INFO/SCRIPTS/POSTTRANS @@ -29,4 +30,11 @@ -r--r--r-- 1 0 0 0 2017-01-05 00:00:00 INFO/SCRIPTS/POSTUNPROG -r--r--r-- 1 0 0 0 2017-01-05 00:00:00 INFO/SCRIPTS/VERIFYSCRIPTPROG +-r--r--r-- 1 0 0 0 2017-01-05 00:00:00 INFO/PACKAGER +-r--r--r-- 1 0 0 0 2017-01-05 00:00:00 INFO/URL +-r--r--r-- 1 0 0 0 2017-01-05 00:00:00 INFO/EPOCH +-r--r--r-- 1 0 0 0 2017-01-05 00:00:00 INFO/LICENSE +-r--r--r-- 1 0 0 0 2017-01-05 00:00:00 INFO/REQUIRES +-r--r--r-- 1 0 0 0 2017-01-05 00:00:00 INFO/OBSOLETES +-r--r--r-- 1 0 0 0 2017-01-05 00:00:00 INFO/PROVIDES -r--r--r-- 1 0 0 0 2017-01-05 00:00:00 INFO/CHANGELOG -r--r--r-- 1 0 0 0 2017-01-05 00:00:00 CONTENTS.cpio ------------------------------- end of diff --------------------------------
comment:4 Changed 8 years ago by mooffie
Tip:
To reproduce the bug (if you don't already see it on your system):
- Make your system's /bin/sh point to a shell that behaves substantially different than Dash. E.g., make it point to Bash.
- Or: change the shebang of the rpm helper to "#!/bin/bash".
(Explanation: since our "expected output" was created under Dash, you won't see any problem stemming from variations in shell behaviors if your /bin/sh is also Dash.)
comment:5 Changed 8 years ago by mooffie
- Owner set to mooffie
- Status changed from new to accepted
- Branch state changed from no branch to on review
- Milestone changed from Future Releases to 4.8.20
branch: 3786_rpm_echo
Initial changeset:e2f5034303ab4ea06a86c577b863d6c39946c884
(The explanation is in the commit messages.)
comment:6 Changed 8 years ago by mooffie
Some background:
The commit messages speak of a DESCRIPTION field having weird characters in it. For your convenience, here's the value of our DESCRIPTION field:
Multi-line description field with "double", 'single quotes', and $weird | \characters i\n = i\\t, empty line... ...and a tab: [ ].'
I intentionally put weird characters in it in case some programmer, in the future, would want to work on the rpm helper and need non-trivial mock data. Had I known it'd cause trouble I wouldn't have done it. On reflection, that helper should have been written in Perl.
comment:8 Changed 8 years ago by andrew_b
- Votes for changeset changed from zaytsev to zaytsev andrew_b
- Branch state changed from on review to approved
comment:9 Changed 8 years ago by mooffie
- Status changed from accepted to testing
- Votes for changeset changed from zaytsev andrew_b to committed-master
- Resolution set to fixed
- Branch state changed from approved to merged
Merged to master: [556d213a65bc41d88c4c591b324d26ca4b67d092]
comment:10 Changed 8 years ago by mooffie
- Status changed from testing to closed
NEWS-4.8.20 updated.
(In #3781) Replying to mooffie:
Ok, I decided it for you: since we don't have @slyfox available for us 24/7, I started a new ticket for the 'sort' issue.
I'm making this ticket blocked by the two new tickets. When @slyfox tells us all is fixed we'll close it.