Project

General

Profile

Actions

Bug #16437

closed

workaround gerrit misclassifying awk test T.misc as binary

Added by Bill Sommerfeld 20 days ago. Updated 15 days ago.

Status:
Closed
Priority:
Normal
Category:
tests
Start date:
Due date:
% Done:

100%

Estimated time:
Difficulty:
Bite-size
Tags:
Gerrit CR:
External Bug:

Description

The awk test usr/src/test/util-tests/tests/awk/tests/T.misc is mistakenly considered by gerrit to be non-diffable "binary" file.

Some experimentation in the context of https://code.illumos.org/c/illumos-gate/+/3393 and https://code.illumos.org/c/illumos-gate/+/3394 has led me to conclude that the problem is the carriage return on line 310, amid a bunch of special characters (FF, CR, BS, VT, BEL); changing just the CR to the \r escape sequence appears to resolve this for subsequent patches.

Actions #1

Updated by Electric Monk 20 days ago

  • Gerrit CR set to 3395
Actions #2

Updated by Bill Sommerfeld 20 days ago

  • Description updated (diff)
Actions #3

Updated by Bill Sommerfeld 20 days ago

This was "developed" in the two gerrit changes linked above - the first phase was making a series of changes to the first patch that removed unusual characters from the script until the 2nd change in the patch was correctly found to be diffable.

My initial suspects were the non-UTF8 octal 200 characters and the ASCII BEL (^G or \007), but removing both of them them didn't made a difference;at that point, the only remaining unusual characters were the set of carriage control characters on line 310; once those were swapped for their string escape sequence equivalents, the 2nd patch became diffable; I then reverted the other changes one by one until only the CR change remained.

As I was doing this I ensured that the old and new shell fragments I changed generated exactly the same output.

Actions #4

Updated by Bill Sommerfeld 20 days ago

  • Description updated (diff)
Actions #5

Updated by Bill Sommerfeld 19 days ago

Testing notes:

- ran the T.misc from change 3395 on its own; it passed as expected.
- ran nightly build with this change and #16435 included
- uninstalled locale/ru-extra prior to running tests (had been installed for an earlier version of the fix)
- onu'ed nightly-nd bits on to a VM; ran /opt/util-tests/bin/utiltest as non-root; got 100% pass (47/47)
- onu'ed nightly (DEBUG) bits onto a VM; ran /opt/util-tests/bin/utiltest as non-root; got 100% pass (47/47)

Actions #6

Updated by Bill Sommerfeld 18 days ago

  • Status changed from In Progress to Pending RTI
Actions #7

Updated by Electric Monk 15 days ago

  • Status changed from Pending RTI to Closed
  • % Done changed from 0 to 100

git commit 8becd264f090383e754dfc0f1aa07109620465d0

commit  8becd264f090383e754dfc0f1aa07109620465d0
Author: Bill Sommerfeld <sommerfeld@hamachi.org>
Date:   2024-04-06T13:28:26.000Z

    16435 util-tests setup fixes
    16437 workaround gerrit misclassifying awk test T.misc as binary
    Reviewed by: Gordon Ross <Gordon.W.Ross@gmail.com>
    Reviewed by: Andy Fiddaman <illumos@fiddaman.net>
    Reviewed by: Toomas Soome <tsoome@me.com>
    Approved by: Robert Mustacchi <rm@fingolfin.org>

Actions

Also available in: Atom PDF