tilt
tilt copied to clipboard
Tilt WebUI keeps flickering and scrolling to the top of the resource log history
Expected Behavior
When nothing is changing in the resource and no new logs are generated, Tilt should not visually flicker or move the scroll position in the resource log window.
Current Behavior
Every ~1sec, the entire resource log panel flickers and snaps the scroll position to the top of the window or the bottom of the window.
Steps to Reproduce
I am not sure how easy this will be for others, but here is what I have
- Create a tiltfile that includes a
docker_buildand uses docker_compose or kustomize to deploy resources (not sure if this is relevant). tilt up- Go to the list-view of resources and scroll to the middle of a resource log.
- Wait a few seconds and watch the scroll bar snap to the top of the log history.
Context
tilt doctor Output
Tilt: v0.32.0, built 2023-03-13
System: linux-amd64
---
Docker
- Host: unix:///var/run/docker.sock
- Server Version: 20.10.23+azure-2
- API Version: 1.41
- Builder: 2
- Compose Version: v2.16.0 (build azure-2)
---
Kubernetes
- Env: kind
- Context: kind-kerfed
- Cluster Name: kind-kerfed
- Namespace: default
- Container Runtime: containerd
- Version: v1.25.2
- Cluster Local Registry: &RegistryHosting{Host:localhost:5863,HostFromClusterNetwork:kerfed-registry:5000,HostFromContainerRuntime:,Help:https://github.com/tilt-dev/ctlptl,SingleName:,}
---
Thanks for seeing the Tilt Doctor!
Please send the info above when filing bug reports. 💗
The info below helps us understand how you're using Tilt so we can improve,
but is not required to ask for help.
---
Analytics Settings
--> (These results reflect your personal opt in/out status and may be overridden by an `analytics_settings` call in your Tiltfile)
- User Mode: default
- Machine: anon
- Repo: 1kUo2fc12eYQzafhxY0yhw==
I am viewing the WebUI in Chrome for Linux Version 112.0.5615.49 (Official Build) (64-bit).
There are no outputs or errors in the browser console window as this is occurring.
About Your Use Case
This is a major usability problem for me as I can't really view logs at all, and the constant flickering means I have to minimize the Tilt window because it causes me eye strain.
It looks like the underlying issue is that for a small number of frames, the logs are completely cleared and then refilled again, which I can see in the Chrome performance profiler:

Thanks for the report! We've never heard this bug before, so we'll need to figure out some repro steps Can you check:
-
are you able to reproduce the problem in the example project? That will confirm if it's specific to your tiltfile. https://github.com/tilt-dev/tilt-example-html
-
are you able to reproduce incognito window or another browser? That will check if it's related to an extension.
Thanks, I tried it on the example repo, and I do not see the issue there. :exploding_head:
However, I do see the issue in at least two unrelated projects where I am using Tiltfiles. So it must be some specific construction in my Tiltfile that causes the issue. Let me see if I can create a more minimal repro case that I can share.
Here are some candidate things that I will be looking at:
- Running tilt from within a docker container and using port-forwarding to my host
- Using parametric for-loops to create k8s or dc resources
- Making a lot of resources (I have ~50 in the projects that have issues)
- Leaving things running a very long time (I often have to refresh the tilt page to get it to be responsive if I leave it more than a day or so, maybe this is related)
Confirming the problem does happen in a Chrome incognito window as well.
Also, I opened up multiple browser windows and confirmed the flicker is synchronized across the two windows. Both scroll to the top/bottom at the same moment.
This bug affects me a lot as well
This bug affects me too.
Reproduces in MacOS as well. Happens in Safari, Chrome and Firefox.
My cluster has 10 running containers, 5 of which use docker_build.
After fresh tilt up, the flickering happens now and then. This is barely noticeable. However, if the containers start producing a lot of logs quickly at the same time e.g. due to error scenario, the flickering becomes constant. Log screen flips between empty and filled log view multiple times a second. The flickering also affects the log view of all resources, even those that have barely any logs.
If I restart Tilt, the flickering is not affected at all.
If I restart Docker Desktop, the flickering goes away (until the next time it starts).
Tilt: v0.33.12, built 2024-03-28
System: darwin-arm64
---
Docker
- Host: unix:///Users/unkhz/.docker/run/docker.sock
- Server Version: 26.0.0
- API Version: 1.45
- Builder: 2
- Compose Version: v2.26.1-desktop.1
---
Kubernetes
- Env: kind
- Context: kind-kind
- Cluster Name: kind-kind
- Namespace: default
- Container Runtime: containerd
- Version: v1.28.7
- Cluster Local Registry: &RegistryHosting{Host:localhost:5001,HostFromClusterNetwork:,HostFromContainerRuntime:,Help:https://kind.sigs.k8s.io/docs/user/local-registry/,SingleName:,}