Skip to content

Progress cuts off prints to the terminal #20119

Closed as not planned
Closed as not planned
@NicoElbers

Description

@NicoElbers

Zig Version

0.13.0-dev.339+6b020c3d1

Steps to Reproduce and Observed Behavior

Create a template project using zig init

paste the following in src/main.zig

const std = @import("std");

pub fn main() !void {
    std.debug.print("0\n", .{});
    std.debug.print("1\n", .{});
    std.debug.print("2\n", .{});
    std.debug.print("3\n", .{});
    std.debug.print("4\n", .{});
    std.debug.print("5\n", .{});
    std.debug.print("6\n", .{});
    std.debug.print("7\n", .{});
    std.debug.print("8\n", .{});
    std.debug.print("9\n", .{});
    std.debug.print("10\n", .{});
}

Run zig build run

Your ouput should look something like this:

❯ zig build run           
[2/7] steps
└─ [5] zig build-exe ProgressObscuresLogging De
   └─ LLVM Emit Object
0
1
2
3
4
5
6
7

Notice that the "8", "9" and "10" prints are cut off.

From my testing the same holds true for printing to std out.

Expected Behavior

That all 10 debug print statements are successfully displayed in the terminal.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugObserved behavior contradicts documented or intended behaviorzig build systemstd.Build, the build runner, `zig build` subcommand, package management

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions