Skip to content

Confusing behavior between interesting exit code and interesting regexp, at least with treereduce-rust #195

Description

@pacak

Consider options --interesting-exit-code and --interesting-stderr.

Right now the reduction is considered to be interesting when either condition matches:

let is_interesting = (interesting_code || stdout_match || stderr_match)

Suppose I'm tracking a specific compiler crash, I would pass --interesting-stderr my-error and don't specify any interesting exit code. This leaves it at a default value of 0 and treereduce-rust quickly reduces the example to empty file - "code 0 is interesting" according to default command line options.

Next attempt is me passing an expected exit code along with interesting stderr, but this can lead to minimization for some other compiler crash.

As a result to track a specific crash I need to pass --interesting-stderr my-error as well as --interesting-exit-code 12345 - some exit code that doesn't match.

There's several ways to solve it, least confusing would be to get rid of default code of 0 and ask user to specify at least one interesting criteria - exit code or regexp.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions