Skip to content

v3.6.2 adds empty line to stderr when cli.Exit is called with empty message #2263

Closed

Description

@mustafabayar

My urfave/cli version is

v3.3.3

Checklist

  • Are you running the latest v3 release? The list of releases is here.
  • Did you check the manual for your release? The v3 manual is here
  • Did you perform a search about this problem? Here's the GitHub guide about searching.

Dependency Management

  • My project is using go modules.

Describe the bug

The change from #2237 that is released in version v3.6.2 causes empty line to be added to stderr if cli.Exit is called with an empty message such as:

cli.Exit("", exitError.ExitCode())

To reproduce

cli.Exit("", exitError.ExitCode())

Observed behavior

Our test assertions are now broken due to unnecessary empty line in the output.

Expected behavior

I want to understand if this was intentional, because Exit accepts empty string as valid input. I believe it should either not accept it, or not add unnecessary empty lines.

Activity

  1. added
    kind/bugdescribes or fixes a bug
    status/triagemaintainers still need to look into this
    area/v3relates to / is being considered for v3
    on Feb 11, 2026
  2. changed the title [-]your bug title goes here[/-] [+]v3.6.2 adds empty line to stderr when cli.Exit is called with empty message[/+] on Feb 11, 2026
  3. dearchap commented on Feb 22, 2026

    @dearchap
    Contributor

    @mustafabayar Yes that change was intentional. It seems to have had an unintended side effect that you mention.

  4. added a commit that references this issue on Apr 12, 2026
    6ce476e
  5. added a commit that references this issue on Apr 13, 2026
    bb2e3ea
  6. alliasgher commented on Apr 13, 2026

    @alliasgher
    Contributor

    Opened #2312 for this.

  7. added a commit that references this issue on Apr 15, 2026
    5200861
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

    area/v3relates to / is being considered for v3kind/bugdescribes or fixes a bugstatus/triagemaintainers still need to look into this

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions