gitpod-io / gitpod-io/gitpod

Tasks log output is too chatty (especially with prebuilds enabled)

Open
#4,306 4 comments 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

component: ide feature: prebuilds feature: terminal meta: never-stale type: feature request type: improvement user experience
Dominant language
TypeScript
Stars
13.8k
Forks
1.4k
Avg merge
17h 58m
Merged PRs (30d)
5

Description

Bug description

When my project has a .gitpod.yml that looks like this (each command prints nothing itself):

tasks:
  - before: BEFORE
    init: INIT
    prebuild: PREBUILD

And then I open a prebuilt workspace for my project, I would expect the first Terminal to show something like this:

gitpod /workspace/project $ { BEFORE } && { INIT } && { PREBUILD }

🤙 This task ran as a workspace prebuild

However, currently, the first Terminal shows all this stuff:

 HISTFILE=/workspace/.gitpod/cmd-0 history -r; {
BEFORE
} && {
[ -r /workspace/.prebuild-log-0 ] && cat /workspace/.prebuild-log-0; [ -r /workspace/.gitpod/prebuild-log-0 ] && cat /workspace/.gitpod/prebuild-log-0; true
}
gitpod /workspace/project $  HISTFILE=/workspace/.gitpod/cmd-0 history -r; {
> BEFORE
> } && {
> [ -r /workspace/.prebuild-log-0 ] && cat /workspace/.prebuild-log-0; [ -r /workspace/.gitpod/prebuild-log-0 ] && cat /workspace/.gitpod/prebuild-log-0; true
> }
{
BEFORE
} && {
INIT
} && {
PREBUILD
}; exit
gitpod /workspace/project $ {
> BEFORE
> } && {
> INIT
> } && {
> PREBUILD
> }; exit
exit

🤙 This task ran as a workspace prebuild
Steps to reproduce
  1. Add a simple .gitpod.yml to a project, with tasks, and enable prebuilds
  2. Open a workspace for that project, and look at the first Terminal output
Expected behavior

The Terminal output should:

  • Not show anything unrelated to me, the user (e.g. all these HISTFILE things, and the prebuild log catting logic)
  • Only print my own commands once, not twice (INIT, PREBUILD) or 4 times (BEFORE)
Example repository

https://github.com/jankeromnes/gitpod-staging-prebuilds

Anything else?

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

The issue names a .gitpod.yml task configuration and an example repository, but no source files or tests. Reproduce the output with before, init, and prebuild commands and trace the task/prebuild terminal handling; done means user commands appear once without internal HISTFILE or log-reading details.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
developer-experience
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.