Closed cunninghamd closed 11 months ago
Just want to take time to thank you for giving a breakdown of all that you currently have open @cunninghamd! That's useful. What size of projects are you working in? What languages and frameworks are your projects in?
What size of projects are you working in?
It's a nodejs project. Excluding the node_modules
folders, there are 8500+ files.
Worth noting, it's also a monorepo, so multiple projects in one folder.
Most files are small. We're pretty diligent about breaking things apart, so the largest individual files would likely not exceed say 1000 lines or so, and most are a lot smaller.
I feel like my terminal usage is the culprit. But I didn't troubleshoot (i.e.: close all my terminals and restart them). Which is something I'll do should the issue recur.
Also: I don't restart my computer or editor very often. I'd estimate that Zed had been running at least a week, if not a couple weeks, when this issue occurred.
Thank you a ton for the awesome write up with all these details! Super helpful!
Quick question @cunninghamd, did you open Zed at all in your $HOME directory at all during the time when the memory spiked?
I did not gather as much information as @cunninghamd did, but I came here to report a similar issue, wondering if there's a memory leak. Zed was using 68.11GB of memory at the time MacOS showed me a warning.
I had one window open in Zed, displaying a mixed Rust/C++ project. Tokei tells me there are 2663 files in the repo, including ones pulled in from git submodules, but I had only one file tab open at the time. Zed had been running for a couple of days at that point, since whenever it took the most recent update. This has not happened with Zed before. After a restart, opening a single project window for the same project uses 354.6MB of memory, which seems more typical.
ETA: I do not use Zed's terminal.
Quick question @cunninghamd, did you open Zed at all in your $HOME directory at all during the time when the memory spiked?
Tough to say. I'm doubtful, as the editor just stays open all the time. I may have cd
'd into my $HOME directory in a terminal, if that's the same thing. But to open a new window, or start it from the command line in my home directory, seems very unlikely for me.
I also get this only on the latest Zed 0.107.6 and it was running all morning when I ran into this. I JUST updated this morning.
This leak is hard to track down, so we really appreciate all the details you all have provided.
@JosephTLyons I can reproduce it every time by opening zed in an elixir project, and leaving it open in the background. Couple hours to 18gb.
If possible, can you share which Elixir project?
https://github.com/jeregrine/svg-ex I just have the paths.ex file open (i committed with syntax errors as I'm porting some clojure)
here are my settings
// Zed settings
//
// For information on how to configure Zed, see the Zed
// documentation: https://zed.dev/docs/configuring-zed
//
// To see all of Zed's default settings without changing your
// custom settings, run the `open default settings` command
// from the command palette or from `Zed` application menu.
{
"theme": "Gruvbox Dark Hard",
"buffer_font_size": 15,
"vim_mode": true,
"buffer_font_family": "FiraCode Nerd Font Mono",
"autosave": "on_focus_change",
"language_overrides": {
"elixir": {
"lsp": "next_ls",
"format_on_save": {
"external": {
"command": "mix",
"arguments": [
"format",
"--stdin-filename",
"{buffer_path}",
"-"
]
}
}
}
}
}
Good callout @jeregrine , here are my settings:
{
"theme": "Ayu Dark",
"buffer_font_size": 15,
"base_keymap": "SublimeText",
"format_on_save": "off",
"tab_size": 2,
"tabs": {
"git_status": true
},
"extend_comment_on_newline": false,
"assistant": {
"default_open_ai_model": "gpt-3.5-turbo-0613"
},
"scrollbar": {
"show": "always"
},
"language_overrides": {
"JavaScript": {
"format_on_save": {
"external": {
"command": "npx", // you could also specify "node_modules/.bin/prettier" here
"arguments": [
"prettier",
"--stdin-filepath",
"{buffer_path}"
]
}
}
}
}
}
{
"base_keymap": "VSCode",
"theme": "Andromeda",
"buffer_font_size": 15,
"preferred_line_length": 100,
"hard_tabs": true,
"terminal": {
"dock": "right"
},
"languages": {
"Plain Text": {
"soft_wrap": "preferred_line_length"
},
"Elixir": {
"tab_size": 2
},
"Go": {
"tab_size": 4,
"hard_tabs": true
},
"Markdown": {
"soft_wrap": "preferred_line_length"
},
"JavaScript": {
"tab_size": 4
},
"TypeScript": {
"tab_size": 4
},
"TSX": {
"tab_size": 4
},
"YAML": {
"tab_size": 4
},
"JSON": {
"tab_size": 4
},
"Rust": {
"hard_tabs": false
}
}
}
Whatever the trigger is for the leak, I haven't hit it since yesterday's restart. Sitting at 423.5MB in use with 3 files open.
This is not very helpful I know, but this morning I saw 205GB with Zed Preview 0.108.1:
If you can reproduce, what about tracking allocations using Xcode Instruments?
@Pringlers I don't have access to do that.
@Pringlers I don't have access to do that.
@jeregrine If you mean you get “Failed to get authorization”, this workaround has worked for me
tbf I'm not a contributor to this project, I am just affected by this bug. If the zed team wants me to go deeper I will try to oblige.
Thanks so much for the reproduction info @jeregrine. That is very useful.
I'm experiencing this same issue (40+ GB) but even with small projects (only 3 lua files), and without even using the terminal.
I'm on macOS Catalina 10.15.7, signed in, no Github Copilot, no ChatGPT, no panels open, minimal settings:
{
"telemetry": {
"diagnostics": false,
"metrics": false
},
"theme": "One Light",
"buffer_font_size": 12,
"hard_tabs": true,
"tab_size": 4,
"format_on_save": "off",
"terminal": {
"blinking": "on"
}
}
I'm not absolutely sure about this, but it seems I don't even have to do anything but leave it open and the megabytes start climbing...
Today's preview release (v0.109.0-pre) has some code to prevent us from storing an excessive amount of data from the language server's logs. We're not sure if what is going on here is related to that or not, but if anyone could test preview out when it is released today, and check back in every so often and let us know if the issue comes back, that would be super helpful. 🙏
Definitely seems better so far! hovering around 198mb
Definitely seems better so far! hovering around 198mb
Hey @jeregrine, this is the preview update that has a potential fix:
I'm experiencing this same issue (40+ GB) but even with small projects (only 3 lua files), and without even using the terminal.
I'm on macOS Catalina 10.15.7, signed in, no Github Copilot, no ChatGPT, no panels open, minimal settings:
{ "telemetry": { "diagnostics": false, "metrics": false }, "theme": "One Light", "buffer_font_size": 12, "hard_tabs": true, "tab_size": 4, "format_on_save": "off", "terminal": { "blinking": "on" } }
I'm not absolutely sure about this, but it seems I don't even have to do anything but leave it open and the megabytes start climbing...
What languages / frameworks are you working in?
I had a vue repo, which is a monorepo, for quite sometime. Here are a few lines of the sample that I took from activity monitor's sampling. And a screenshot attached:
I had a vue repo, which is a monorepo, for quite sometime. Here are a few lines of the sample that I took from activity monitor's sampling. And a screenshot attached:
Hey, what version of Zed did you have this in?
0.109.0 seems to be growing but much much slower than before. Its settled in at about 600mb after a day or so.
I had a vue repo, which is a monorepo, for quite sometime. Here are a few lines of the sample that I took from activity monitor's sampling. And a screenshot attached:
Hey, what version of Zed did you have this in?
Zed 0.107.7
I'm experiencing this same issue (40+ GB) but even with small projects (only 3 lua files), and without even using the terminal. I'm on macOS Catalina 10.15.7, signed in, no Github Copilot, no ChatGPT, no panels open, minimal settings:
{ "telemetry": { "diagnostics": false, "metrics": false }, "theme": "One Light", "buffer_font_size": 12, "hard_tabs": true, "tab_size": 4, "format_on_save": "off", "terminal": { "blinking": "on" } }
I'm not absolutely sure about this, but it seems I don't even have to do anything but leave it open and the megabytes start climbing...
What languages / frameworks are you working in?
Only Lua (command line LuaJIT 2.0 run outside Zed), no frameworks.
0.109.0 seems to be growing but much much slower than before. Its settled in at about 600mb after a day or so.
Thanks for the update - let us know if it continues to grow. It seems high here, but its hard to tell if its stable or not at this point.
Now its open for two days and its sitting at 936MB. So it is slowly growing/leaking.
Who would've thought memory management could be hard 😁 ?
Don't know if this helps, but on macOS 12.6.6 using Zed 0.108.2, I get the same result as jeregrine on Zed 0.109.0, settling to 600-800MB after a day, regardless of what project is open (HTML site, Lua game, etc.):
0.109.0 seems to be growing but much much slower than before. Its settled in at about 600mb after a day or so.
Has anyone broken into the multiple-gigabyte territory yet, after updating to v109+? I'm wondering if the work we did is preventing it from getting into that territory that others were in prior, or if we are still in a place where we hit that range. Either way, it seems like its still high.
Nah mine mostly tops around 800mb from the initial 180mb On Oct 30, 2023, at 10:06 AM, Joseph T. Lyons @.***> wrote: Has anyone broken into the multiple-gigabyte territory yet? I'm wondering if the work we did is preventing it from getting into that territory that others were in prior, or if we are still in that range.
—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you were mentioned.Message ID: @.***>
Has anyone broken into the multiple-gigabyte territory yet, after updating to v109+? I'm wondering if the work we did is preventing it from getting into that territory that others were in prior, or if we are still in a place where we hit that range. Either way, it seems like its still high.
I'm hovering at a common 890MB, which seems to be where it normally hovers. All good so far. :)
Sounds like we do not have any multi-gigabyte usage reports anymore, so closing this.
Hi, I'm facing a perhaps similar problem on Zed 0.123.6, MacOS Ventura. I sometimes get a very nasty memory leak while I'm working on a Rust project. When it is triggered, memory usage is filled very quickly; Zed can reach 40 GB of memory consumption within a few minutes before requiring a force quit (it is completely frozen since the beginning of the leak). Not sure what causes it; last time it was after selecting a block of code, at least. Worth mentioning that it is a relatively large Rust project. Should I open a new issue?
I looked at the logs, and I found these logs from around the moment of the leak; they could be relevant (but not sure):
``` 2024-02-26T01:09:46-03:00 [WARN] Generic lsp request to rust-analyzer failed: Invalid Range [... line above is repeated tens of times, repetitions omitted ...] 2024-02-26T01:09:46-03:00 [WARN] Generic lsp request to rust-analyzer failed: Invalid Range 2024-02-26T01:09:46-03:00 [WARN] Generic lsp request to rust-analyzer failed: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 969}, offset: 188, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 969}, offset: 188, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 969}, offset: 188, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 969}, offset: 188, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 969}, offset: 188, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 969}, offset: 188, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 969}, offset: 188, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:46-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:47-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:48-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:51-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range 2024-02-26T01:09:56-03:00 [WARN] request completed with error: request or operation took longer than the configured timeout time 2024-02-26T01:09:56-03:00 [ERROR] crates/client/src/telemetry.rs:583: request or operation took longer than the configured timeout time Caused by: [28] Timeout was reached 2024-02-26T01:09:57-03:00 [ERROR] inlay hint update task for range Anchor { timestamp: Lamport {0: 819}, offset: 0, bias: Right, buffer_id: Some(BufferId(2)) }..Anchor { timestamp: Lamport {0: 727}, offset: 4, bias: Right, buffer_id: Some(BufferId(2)) } failed: inlay hint fetch task: inlay hints LSP request: Invalid Range ```
Should I open a new issue?
Yeah, I think that'd be good. Ideally it would include information about memory usage of rust-analyzer too.
Will do, thanks!
Edit: Opened at https://github.com/zed-industries/zed/issues/8436
Somehow have been having some memory leaks here too. To reproduce:
Uninstalled the XML extension and it has since ceased to explode.
Some of the logs I've seen:
2024-07-19T07:17:21.258857Z [ERROR] failed to get git blame data: Failed to blame "public/assets/sell/vip.svg"
Caused by:
Broken pipe (os error 32)
2024-07-19T07:17:24.773229Z [ERROR] Io(Os { code: 2, kind: NotFound, message: "No such file or directory" })
2024-07-19T07:17:24.784085Z [ERROR] Io(Os { code: 2, kind: NotFound, message: "No such file or directory" })
2024-07-19T07:17:24.78607Z [ERROR] Io(Os { code: 2, kind: NotFound, message: "No such file or directory" })
2024-07-19T07:17:26.021671Z [ERROR] failed to get git blame data: Failed to blame "app/assets/builds/tailwind.css"
Caused by:
Broken pipe (os error 32)
2024-07-19T07:17:45.440557Z [INFO] starting language servers for XML:
2024-07-19T07:18:23.299041Z [INFO] starting language servers for XML:
2024-07-19T07:18:24.250875Z [INFO] starting language servers for XML:
2024-07-19T07:18:24.54431Z [INFO] starting language servers for XML:
2024-07-19T07:18:24.557087Z [INFO] starting language servers for XML:
2024-07-19T07:18:24.568554Z [INFO] starting language servers for XML:
2024-07-19T07:18:24.591786Z [INFO] starting language servers for XML:
2024-07-19T07:18:24.608061Z [INFO] starting language servers for XML:
2024-07-19T07:18:24.644193Z [INFO] starting language servers for XML:
2024-07-19T07:18:24.672888Z [INFO] starting language servers for XML:
2024-07-19T07:18:24.702848Z [INFO] starting language servers for XML:
2024-07-19T07:18:24.776445Z [INFO] starting language servers for XML:
2024-07-19T07:18:25.244841Z [INFO] starting language servers for XML:
2024-07-19T07:18:25.309228Z [INFO] starting language servers for XML:
2024-07-19T07:18:25.385426Z [INFO] starting language servers for XML:
2024-07-19T07:18:25.470835Z [INFO] starting language servers for XML:
2024-07-19T07:18:25.484032Z [INFO] starting language servers for XML:
2024-07-19T07:18:25.544595Z [INFO] starting language servers for XML:
2024-07-19T07:18:25.642314Z [INFO] starting language servers for XML:
2024-07-19T07:18:25.738548Z [INFO] starting language servers for XML:
2024-07-19T07:18:25.760768Z [INFO] starting language servers for XML:
2024-07-19T07:18:25.802681Z [INFO] starting language servers for XML:
2024-07-19T07:18:25.843899Z [INFO] starting language servers for XML:
2024-07-19T07:18:25.949424Z [INFO] starting language servers for XML:
2024-07-19T07:18:25.994089Z [INFO] starting language servers for XML:
2024-07-19T07:18:26.203367Z [INFO] starting language servers for XML:
2024-07-19T07:18:26.467777Z [INFO] starting language servers for XML:
2024-07-19T07:18:26.928148Z [INFO] starting language servers for XML:
2024-07-19T07:18:27.008891Z [INFO] starting language servers for XML:
2024-07-19T07:18:27.029523Z [INFO] starting language servers for XML:
2024-07-19T07:18:27.501047Z [INFO] starting language servers for XML:
2024-07-19T07:18:27.565874Z [INFO] starting language servers for XML:
2024-07-19T07:18:28.024618Z [INFO] starting language servers for XML:
2024-07-19T07:18:28.171681Z [INFO] starting language servers for XML:
2024-07-19T07:18:28.585169Z [INFO] starting language servers for XML:
2024-07-19T07:18:29.175794Z [INFO] starting language servers for XML:
2024-07-19T07:18:29.236172Z [INFO] starting language servers for XML:
2024-07-19T07:18:29.542006Z [INFO] starting language servers for XML:
2024-07-19T07:18:31.11794Z [INFO] starting language servers for XML:
2024-07-19T07:18:31.579456Z [INFO] starting language servers for XML:
2024-07-19T07:18:31.681328Z [INFO] starting language servers for XML:
2024-07-19T07:18:32.822126Z [INFO] starting language servers for XML:
2024-07-19T07:18:35.361496Z [INFO] starting language servers for XML:
2024-07-19T07:18:35.987887Z [INFO] starting language servers for XML:
2024-07-19T07:18:36.960046Z [INFO] starting language servers for XML:
2024-07-19T07:18:39.986532Z [INFO] starting language servers for XML:
2024-07-19T07:18:40.14862Z [INFO] starting language servers for XML:
2024-07-19T07:18:40.313338Z [INFO] starting language servers for XML:
2024-07-19T07:18:40.314657Z [INFO] starting language servers for XML:
2024-07-19T07:18:40.730386Z [INFO] starting language servers for XML:
2024-07-19T07:18:40.900951Z [INFO] starting language servers for XML:
2024-07-19T07:18:43.002375Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:43.088359Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:43.21111Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:43.224954Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:43.345321Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:43.392037Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:43.432778Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:43.53348Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:43.849542Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:44.323345Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:44.342404Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:44.500348Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:44.510429Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:44.547038Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:44.70632Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:44.775072Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:44.802665Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:44.974061Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.025124Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.069159Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.129692Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.205426Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.311458Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.394499Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.477123Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.572478Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.574767Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.576485Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.648298Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.68148Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.724654Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.774953Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.793892Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.829191Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.877388Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.91653Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:45.951337Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:46.0108Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:46.04436Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:46.068861Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:18:46.122009Z [INFO] starting language servers for Ruby: solargraph, rubocop
2024-07-19T07:21:35.770842Z [WARN] Theme "One Dark Pro" is using a deprecated style property: scrollbar_thumb.background. Use `scrollbar.thumb.background` instead.
2024-07-19T07:21:35.773865Z [INFO] rebuilt extension index in 16.146458ms
2024-07-19T07:21:35.774103Z [INFO] extensions updated. loading 0, reloading 0, unloading 1
2024-07-19T07:21:35.779598Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.780176Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.781791Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.783153Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.784508Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.785895Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.787233Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.788696Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.792678Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.793997Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.795441Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.799589Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.80031Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.801649Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.854439Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.858792Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.860411Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.862046Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.862656Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.863832Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.864419Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.866065Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.868582Z [INFO] starting language servers for Ruby: solargraph, rubocop
2024-07-19T07:21:35.869209Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.869694Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.870915Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.874417Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.875843Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.876573Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.877458Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.87802Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.879495Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.880201Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.881771Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.886808Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.887365Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.888889Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.897363Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.898019Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.900402Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.911108Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.924519Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.92461Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.924672Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.924736Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.924798Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.924859Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.924922Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.924983Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.925047Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.925127Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.925192Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.925265Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.925326Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.925385Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.925447Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.925507Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.925568Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.925629Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.925689Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.925751Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.925809Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.925869Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.925929Z [INFO] starting language servers for Ruby: solargraph, rubocop
2024-07-19T07:21:35.925992Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.926052Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.926111Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.926191Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.926263Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.926335Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.9264Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.926457Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.926515Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.926571Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.926627Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.926684Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.926741Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.926797Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.926853Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.92691Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.926966Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:35.927023Z [INFO] starting language servers for YAML: yaml-language-server
2024-07-19T07:21:39.597698Z [INFO] Language server with id 1 sent unhandled notification @/tailwindCSS/clearColors:
[
null
]
Why is this issue closed? Even the latest Zed build causes my machine to run out of memory. I open a few rust files, and terminal. Do nothing, wait an hour or two, operating system runs out of memory. Culprit Zed with over 40gb consumed. Zed version: 0.152.4 MacOS: Sonoma Aarc: Intel/Amd64
Still occurring, as mentioned above. On Fedora Linux, crashed my PC a couple of times, started happening as of the latest update.
Please check this issue careful since it's reproducible on the latest Zed 0.154.3 on my MBP M1. The memory consumption gains exponentially when I open the home folder as the active working directory.
Please check this issue careful since it's reproducible on the latest Zed
Can you reproduce it with a minimal, reproducible example?
I encountered this same issue today. In my case, it happens when I use the AI chat and I pass it some files using /file or /tab Memory usage starts to grow quickly and exponentially, until the entire system collapses. This happens rather quickly, collapsing the system within a few minutes or only a few interactions with the AI.
I'm working on a simple Rust project, but the IDE keeps freezing, and macOS M2 (Sonoma 14.4.1) repeatedly alerts me about high memory usage. I’m forced to kill the process each time. I'm currently using Zed version 0.158.2.
I'm working on a simple Rust project, but the IDE keeps freezing
Is that project open-source? Can you share it?
I've also been encountering the same issue. I use neovim for almost all of my use cases, I only use Zed (Preview) for a phoenix project. So relatively isolated, and nothing too crazy. Couple files open (I hate having too many tabs), normally one vsplit, then a terminal running an iex -S mix phx.server
.
I can use Zed for hours without much of a problem. Memory consumption will range between 300MB normally and 3GB on the upper end. However, if I leave the computer long enough to sleep, and come back to wake it, it will shoot up to 8-12GB (my machine only has 16GB total so it seems to just use up 'whatever is left'). Closing all files and terminals does not help, nor restarting the LSP does not affect it, nor just waiting.
Because of Zed's ridiculous startup speed, it's not much of an issue. Force quite, reopen, back where I was in less than a second. But at this point it's been pretty reliably reproducible: open a phoenix project, start a server, leave the computer for a few hours and come back.
Happened today with Zed Preview 0.160.2, macOS 15.1, M1 Pro. Been happening for months though
Check for existing issues
Describe the bug / provide steps to reproduce it
My mac complained it was entirely out of system memory, which seemed odd. Upon investigating, it turns out Zed was using over 174GB of RAM.
Now, my workflow may not be what you consider ideal, just as an FYI:
So, yeah, there's possibly an awkward memory leak in there somewhere. :)
Environment
Zed: v0.106.2 (stable) OS: macOS 13.6.0 Memory: 32 GiB Architecture: aarch64
If applicable, add mockups / screenshots to help explain present your vision of the feature
If applicable, attach your
~/Library/Logs/Zed/Zed.log
file to this issue.If you only need the most recent lines, you can run the
zed: open log
command palette action to see the last 1000.No response