Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

infinite loop Restart notebook (required) #2312

Closed
SimonEnsemble opened this issue Oct 12, 2022 · 6 comments
Closed

infinite loop Restart notebook (required) #2312

SimonEnsemble opened this issue Oct 12, 2022 · 6 comments
Assignees
Labels
package manager Pluto's built-in package manager

Comments

@SimonEnsemble
Copy link

the problem in the Pluto notebook

I am experiencing an infinite loop of "Restart notebook (required)" requests (each time I click restart, it doesn't resolve).

this happens both (i) on a notebook I have launched before and (ii) upon creating a new notebook.

problem does not resolve after restarting Julia and/or Pluto.

the error message in the REPL from which Pluto is launched

┌ Warning: PlutoPkg: Failed to add/remove packages! Resetting package environment...
│   PLUTO_VERSION = v"0.19.13"VERSION = v"1.8.2"
│   old_packages = String[]
│   new_packages =4-element Vector{String}:"Statistics""PlutoUI""CSV""DataFrames"
│   exception ="/private/var/folders/mc/q4kv7qs121gc_0h42v317dyw0000gn/T/jl_uA6Zfj/Project.toml": No such file
│    Stacktrace:
│      [1] error(::String, ::String)
│        @ Base ./error.jl:44
│      [2] readstring
│        @ /Applications/Julia-1.8.app/Contents/Resources/julia/share/julia/stdlib/v1.8/TOML/src/TOML.jl:21 [inlined]
│      [3] parsefile(f::String)
│        @ TOML /Applications/Julia-1.8.app/Contents/Resources/julia/share/julia/stdlib/v1.8/TOML/src/TOML.jl:43
│      [4] _modify_compat(f!::Pluto.PkgCompat.var"#27#28"{Pkg.Types.Context}, ctx::Pkg.Types.Context)
│        @ Pluto.PkgCompat ~/.julia/packages/Pluto/U4wvO/src/packages/PkgCompat.jl:408
│      [5] write_auto_compat_entries
│        @ ~/.julia/packages/Pluto/U4wvO/src/packages/PkgCompat.jl:430 [inlined]
│      [6] (::Pluto.var"#187#199"{Vector{String}, Pluto.Notebook, Pluto.IOListener})()
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:178
│      [7] withinteractive(f::Pluto.var"#187#199"{Vector{String}, Pluto.Notebook, Pluto.IOListener}, value::Bool)
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:528
│      [8] #186
│        @ ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:150 [inlined]
│      [9] withio(f::Pluto.var"#186#198"{Vector{String}, Pluto.Notebook, Pluto.IOListener}, ctx::Pkg.Types.Context, io::IOContext{IOBuffer})
│        @ Pluto.PkgCompat ~/.julia/packages/Pluto/U4wvO/src/packages/PkgCompat.jl:129
│     [10] (::Pluto.var"#182#193"{Pluto.Notebook, Pluto.IOListener, Vector{String}, Vector{String}, Bool, Bool})()
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:149
│     [11] withtoken(f::Pluto.var"#182#193"{Pluto.Notebook, Pluto.IOListener, Vector{String}, Vector{String}, Bool, Bool}, token::Pluto.Token)
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/evaluation/Tokens.jl:19
│     [12] sync_nbpkg_core(notebook::Pluto.Notebook, old_topology::Pluto.NotebookTopology, new_topology::Pluto.NotebookTopology; on_terminal_output::Pluto.var"#iocallback#209"{Pluto.ServerSession, Pluto.Notebook}, lag::Float64)
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:112
│     [13] (::Pluto.var"#206#208"{Pluto.ServerSession, Pluto.Notebook, Pluto.NotebookTopology, Pluto.NotebookTopology})()
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:262
│     [14] #205
│        @ ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:253 [inlined]
│     [15] sync_nbpkg(session::Pluto.ServerSession, notebook::Pluto.Notebook, old_topology::Pluto.NotebookTopology, new_topology::Pluto.NotebookTopology; save::Bool, take_token::Bool)
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:253
│     [16] (::Pluto.var"#260#264"{Bool, Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, Pluto.ServerSession, Pluto.Notebook})()
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/evaluation/Run.jl:396
│     [17] withtoken(f::Pluto.var"#260#264"{Bool, Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, Pluto.ServerSession, Pluto.Notebook}, token::Pluto.Token)
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/evaluation/Tokens.jl:19
│     [18] #259
│        @ ~/.julia/packages/Pluto/U4wvO/src/evaluation/Run.jl:395 [inlined]
│     [19] macro expansion
│        @ ~/.julia/packages/Pluto/U4wvO/src/evaluation/Tokens.jl:58 [inlined]
│     [20] (::Pluto.var"#252#253"{Pluto.var"#259#263"{Bool, Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, Pluto.ServerSession, Pluto.Notebook}})()
│        @ Pluto ./task.jl:484
└ @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:286
┌ Info: Backup saved to
└   backup_path = "/Users/cokes/intro_to_data_science_fall_2022/lectures/complete/working_with_data backup 4.jl"

version info

Pluto v0.19.13

julia> versioninfo()
Julia Version 1.8.2
Commit 36034abf260 (2022-09-29 15:21 UTC)
Platform Info:
  OS: macOS (arm64-apple-darwin21.3.0)
  CPU: 8 × Apple M1
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-13.0.1 (ORCJIT, apple-m1)
  Threads: 1 on 4 virtual cores
@SimonEnsemble
Copy link
Author

well, relaunching Pluto now opens the notebook and allows it run. but I get this error?

 LogLevel(1999): handle_connection handler error
│   exception =
│    Server never wrote a response
│    Stacktrace:
│     [1] error(s::String)
│       @ Base ./error.jl:35
│     [2] handle_connection(f::Function, c::HTTP.ConnectionPool.Connection, listener::HTTP.Servers.Listener{Nothing, Sockets.TCPServer}, readtimeout::Int64, access_log::Nothing)
│       @ HTTP.Servers ~/.julia/packages/HTTP/fthyG/src/Servers.jl:445
│     [3] (::HTTP.Servers.var"#16#17"{Pluto.var"#396#406"{Pluto.ServerSession, HTTP.Handlers.Router{typeof(Pluto.default_404), typeof(HTTP.Handlers.default405), Nothing}}, HTTP.Servers.Listener{Nothing, Sockets.TCPServer}, Set{HTTP.ConnectionPool.Connection}, Int64, Nothing, Base.Semaphore, HTTP.ConnectionPool.Connection})()
│       @ HTTP.Servers ./task.jl:484
└ @ HTTP.Servers ~/.julia/packages/HTTP/fthyG/src/Servers.jl:456LogLevel(1999): error while handling connection
│   exception =
│    IOError: write: broken pipe (EPIPE)
│    Stacktrace:
│     [1] uv_write(s::Sockets.TCPSocket, p::Ptr{UInt8}, n::UInt64)
│       @ Base ./stream.jl:1064
│     [2] unsafe_write(s::Sockets.TCPSocket, p::Ptr{UInt8}, n::UInt64)
│       @ Base ./stream.jl:1118
│     [3] unsafe_write(c::HTTP.ConnectionPool.Connection, p::Ptr{UInt8}, n::UInt64)
│       @ HTTP.ConnectionPool ~/.julia/packages/HTTP/fthyG/src/ConnectionPool.jl:105
│     [4] write(io::HTTP.ConnectionPool.Connection, s::String)
│       @ Base ./strings/io.jl:244
│     [5] write
│       @ ./io.jl:674 [inlined]
│     [6] unsafe_write(http::HTTP.Streams.Stream{HTTP.Messages.Request, HTTP.ConnectionPool.Connection}, p::Ptr{UInt8}, n::UInt64)
│       @ HTTP.Streams ~/.julia/packages/HTTP/fthyG/src/Streams.jl:96
│     [7] write(io::HTTP.Streams.Stream{HTTP.Messages.Request, HTTP.ConnectionPool.Connection}, s::String)
│       @ Base ./strings/io.jl:244
│     [8] handle_connection(f::Function, c::HTTP.ConnectionPool.Connection, listener::HTTP.Servers.Listener{Nothing, Sockets.TCPServer}, readtimeout::Int64, access_log::Nothing)
│       @ HTTP.Servers ~/.julia/packages/HTTP/fthyG/src/Servers.jl:461
│     [9] (::HTTP.Servers.var"#16#17"{Pluto.var"#396#406"{Pluto.ServerSession, HTTP.Handlers.Router{typeof(Pluto.default_404), typeof(HTTP.Handlers.default405), Nothing}}, HTTP.Servers.Listener{Nothing, Sockets.TCPServer}, Set{HTTP.ConnectionPool.Connection}, Int64, Nothing, Base.Semaphore, HTTP.ConnectionPool.Connection})()
│       @ HTTP.Servers ./task.jl:484
└ @ HTTP.Servers ~/.julia/packages/HTTP/fthyG/src/Servers.jl:473
┌ Info:
└ Opening http://localhost:1234/open?secret=wzYRw6uf&path=%2FUsers%2Fcokes%2Fintro_to_data_science_fall_2022%2Flectures%2Fcomplete%2Fworking_with_data.jl in your default browser... ~ have fun!
┌ Info:
│ Press Ctrl+C in this terminal to stop Pluto
└
    Updating registry at `~/.julia/registries/General`
    Updating ┌ LogLevel(1999): handle_connection handler error
│   exception =
│    SystemError: opening file "/Users/cokes/.julia/packages/Pluto/U4wvO/frontend-dist/logo.004c1d7c.svg": Too many open files
│    Stacktrace:
│      [1] systemerror(p::String, errno::Int32; extrainfo::Nothing)
│        @ Base ./error.jl:176
│      [2] #systemerror#80
│        @ ./error.jl:175 [inlined]
│      [3] systemerror
│        @ ./error.jl:175 [inlined]
│      [4] open(fname::String; lock::Bool, read::Nothing, write::Nothing, create::Nothing, truncate::Nothing, append::Nothing)
│        @ Base ./iostream.jl:293
│      [5] open
│        @ ./iostream.jl:275 [inlined]
│      [6] open(f::Base.var"#385#386"{Tuple{}}, args::String; kwargs::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
│        @ Base ./io.jl:382
│      [7] open
│        @ ./io.jl:381 [inlined]
│      [8] read
│        @ ./io.jl:460 [inlined]
│      [9] asset_response(path::String; cacheable::Bool)
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/webserver/Static.jl:54
│     [10] (::Pluto.var"#serve_asset#329")(request::HTTP.Messages.Request)
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/webserver/Static.jl:422
│     [11] (::HTTP.Handlers.Router{typeof(Pluto.default_404), typeof(HTTP.Handlers.default405), Nothing})(req::HTTP.Messages.Request)
│        @ HTTP.Handlers ~/.julia/packages/HTTP/fthyG/src/Handlers.jl:439
│     [12] (::Pluto.var"#396#406"{Pluto.ServerSession, HTTP.Handlers.Router{typeof(Pluto.default_404), typeof(HTTP.Handlers.default405), Nothing}})(http::HTTP.Streams.Stream{HTTP.Messages.Request, HTTP.ConnectionPool.Connection})
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/webserver/WebServer.jl:249
│     [13] #invokelatest#2
│        @ ./essentials.jl:729 [inlined]
│     [14] invokelatest
│        @ ./essentials.jl:726 [inlined]
│     [15] handle_connection(f::Function, c::HTTP.ConnectionPool.Connection, listener::HTTP.Servers.Listener{Nothing, Sockets.TCPServer}, readtimeout::Int64, access_log::Nothing)
│        @ HTTP.Servers ~/.julia/packages/HTTP/fthyG/src/Servers.jl:442
│     [16] (::HTTP.Servers.var"#16#17"{Pluto.var"#396#406"{Pluto.ServerSession, HTTP.Handlers.Router{typeof(Pluto.default_404), typeof(HTTP.Handlers.default405), Nothing}}, HTTP.Servers.Listener{Nothing, Sockets.TCPServer}, Set{HTTP.ConnectionPool.Connection}, Int64, Nothing, Base.Semaphore, HTTP.ConnectionPool.Connection})()
│        @ HTTP.Servers ./task.jl:484
└ @ HTTP.Servers ~/.julia/packages/HTTP/fthyG/src/Servers.jl:456LogLevel(1999): handle_connection handler error
│   exception =
│    SystemError: opening file "/Users/cokes/.julia/packages/Pluto/U4wvO/frontend-dist/favicon_unsaturated.d1387b25.svg": Too many open files
│    Stacktrace:
│      [1] systemerror(p::String, errno::Int32; extrainfo::Nothing)
│        @ Base ./error.jl:176
│      [2] #systemerror#80
│        @ ./error.jl:175 [inlined]
│      [3] systemerror
│        @ ./error.jl:175 [inlined]
│      [4] open(fname::String; lock::Bool, read::Nothing, write::Nothing, create::Nothing, truncate::Nothing, append::Nothing)
│        @ Base ./iostream.jl:293
│      [5] open
│        @ ./iostream.jl:275 [inlined]
│      [6] open(f::Base.var"#385#386"{Tuple{}}, args::String; kwargs::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
│        @ Base ./io.jl:382
│      [7] open
│        @ ./io.jl:381 [inlined]
│      [8] read
│        @ ./io.jl:460 [inlined]
│      [9] asset_response(path::String; cacheable::Bool)
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/webserver/Static.jl:54
│     [10] (::Pluto.var"#serve_asset#329")(request::HTTP.Messages.Request)
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/webserver/Static.jl:422
│     [11] (::HTTP.Handlers.Router{typeof(Pluto.default_404), typeof(HTTP.Handlers.default405), Nothing})(req::HTTP.Messages.Request)
│        @ HTTP.Handlers ~/.julia/packages/HTTP/fthyG/src/Handlers.jl:439
│     [12] (::Pluto.var"#396#406"{Pluto.ServerSession, HTTP.Handlers.Router{typeof(Pluto.default_404), typeof(HTTP.Handlers.default405), Nothing}})(http::HTTP.Streams.Stream{HTTP.Messages.Request, HTTP.ConnectionPool.Connection})
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/webserver/WebServer.jl:249
│     [13] #invokelatest#2
│        @ ./essentials.jl:729 [inlined]
│     [14] invokelatest
│        @ ./essentials.jl:726 [inlined]
│     [15] handle_connection(f::Function, c::HTTP.ConnectionPool.Connection, listener::HTTP.Servers.Listener{Nothing, Sockets.TCPServer}, readtimeout::Int64, access_log::Nothing)
│        @ HTTP.Servers ~/.julia/packages/HTTP/fthyG/src/Servers.jl:442
│     [16] (::HTTP.Servers.var"#16#17"{Pluto.var"#396#406"{Pluto.ServerSession, HTTP.Handlers.Router{typeof(Pluto.default_404), typeof(HTTP.Handlers.default405), Nothing}}, HTTP.Servers.Listener{Nothing, Sockets.TCPServer}, Set{HTTP.ConnectionPool.Connection}, Int64, Nothing, Base.Semaphore, HTTP.ConnectionPool.Connection})()
│        @ HTTP.Servers ./task.jl:484
└ @ HTTP.Servers ~/.julia/packages/HTTP/fthyG/src/Servers.jl:456
git-repo `https://github.com/JuliaRegistries/General` LogLevel(1999): error while handling connection
│   exception =
│    IOError: write: broken pipe (EPIPE)
│    Stacktrace:
│     [1] uv_write(s::Sockets.TCPSocket, p::Ptr{UInt8}, n::UInt64)
│       @ Base ./stream.jl:1064
│     [2] unsafe_write(s::Sockets.TCPSocket, p::Ptr{UInt8}, n::UInt64)
│       @ Base ./stream.jl:1118
│     [3] unsafe_write(c::HTTP.ConnectionPool.Connection, p::Ptr{UInt8}, n::UInt64)
│       @ HTTP.ConnectionPool ~/.julia/packages/HTTP/fthyG/src/ConnectionPool.jl:105
│     [4] write(io::HTTP.ConnectionPool.Connection, s::String)
│       @ Base ./strings/io.jl:244
│     [5] write
│       @ ./io.jl:674 [inlined]
│     [6] unsafe_write(http::HTTP.Streams.Stream{HTTP.Messages.Request, HTTP.ConnectionPool.Connection}, p::Ptr{UInt8}, n::UInt64)
│       @ HTTP.Streams ~/.julia/packages/HTTP/fthyG/src/Streams.jl:96
│     [7] write(io::HTTP.Streams.Stream{HTTP.Messages.Request, HTTP.ConnectionPool.Connection}, s::String)
│       @ Base ./strings/io.jl:244
│     [8] handle_connection(f::Function, c::HTTP.ConnectionPool.Connection, listener::HTTP.Servers.Listener{Nothing, Sockets.TCPServer}, readtimeout::Int64, access_log::Nothing)
│       @ HTTP.Servers ~/.julia/packages/HTTP/fthyG/src/Servers.jl:461
│     [9] (::HTTP.Servers.var"#16#17"{Pluto.var"#396#406"{Pluto.ServerSession, HTTP.Handlers.Router{typeof(Pluto.default_404), typeof(HTTP.Handlers.default405), Nothing}}, HTTP.Servers.Listener{Nothing, Sockets.TCPServer}, Set{HTTP.ConnectionPool.Connection}, Int64, Nothing, Base.Semaphore, HTTP.ConnectionPool.Connection})()
│       @ HTTP.Servers ./task.jl:484
└ @ HTTP.Servers ~/.julia/packages/HTTP/fthyG/src/Servers.jl:473LogLevel(1999): error while handling connection
│   exception =
│    IOError: write: broken pipe (EPIPE)
│    Stacktrace:
│     [1] uv_write(s::Sockets.TCPSocket, p::Ptr{UInt8}, n::UInt64)
│       @ Base ./stream.jl:1064
│     [2] unsafe_write(s::Sockets.TCPSocket, p::Ptr{UInt8}, n::UInt64)
│       @ Base ./stream.jl:1118
│     [3] unsafe_write(c::HTTP.ConnectionPool.Connection, p::Ptr{UInt8}, n::UInt64)
│       @ HTTP.ConnectionPool ~/.julia/packages/HTTP/fthyG/src/ConnectionPool.jl:105
│     [4] write(io::HTTP.ConnectionPool.Connection, s::String)
│       @ Base ./strings/io.jl:244
│     [5] write
│       @ ./io.jl:674 [inlined]
│     [6] unsafe_write(http::HTTP.Streams.Stream{HTTP.Messages.Request, HTTP.ConnectionPool.Connection}, p::Ptr{UInt8}, n::UInt64)
│       @ HTTP.Streams ~/.julia/packages/HTTP/fthyG/src/Streams.jl:96
│     [7] write(io::HTTP.Streams.Stream{HTTP.Messages.Request, HTTP.ConnectionPool.Connection}, s::String)
│       @ Base ./strings/io.jl:244
│     [8] handle_connection(f::Function, c::HTTP.ConnectionPool.Connection, listener::HTTP.Servers.Listener{Nothing, Sockets.TCPServer}, readtimeout::Int64, access_log::Nothing)
│       @ HTTP.Servers ~/.julia/packages/HTTP/fthyG/src/Servers.jl:461
│     [9] (::HTTP.Servers.var"#16#17"{Pluto.var"#396#406"{Pluto.ServerSession, HTTP.Handlers.Router{typeof(Pluto.default_404), typeof(HTTP.Handlers.default405), Nothing}}, HTTP.Servers.Listener{Nothing, Sockets.TCPServer}, Set{HTTP.ConnectionPool.Connection}, Int64, Nothing, Base.Semaphore, HTTP.ConnectionPool.Connection})()
│       @ HTTP.Servers ./task.jl:484
└ @ HTTP.Servers ~/.julia/packages/HTTP/fthyG/src/Servers.jl:473
┌ Error: Some registries failed to update:
│     — /Users/cokes/.julia/registries/General — failed to fetch from repo: failed to fetch from https://github.com/JuliaRegistries/General, error: GitError(Code:ERROR, Class:Net, failed to resolve address for github.com: nodename nor servname provided, or not known)
└ @ Pkg.Registry /Users/administrator/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-macmini-aarch64-1.0/build/default-macmini-aarch64-1-0/julialang/julia-release-1-dot-8/usr/share/julia/stdlib/v1.8/Pkg/src/Registry/Registry.jl:449
┌ Warning: The project dependencies or compat requirements have changed since the manifest was last resolved.
│ It is recommended to `Pkg.resolve()` or consider `Pkg.update()` if necessary.
└ @ Pkg.API /Users/administrator/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-macmini-aarch64-1.0/build/default-macmini-aarch64-1-0/julialang/julia-release-1-dot-8/usr/share/julia/stdlib/v1.8/Pkg/src/API.jl:1532

@SimonEnsemble
Copy link
Author

ok this is now happening with all of my notebooks. weird. another error message below.

    Updating registry at `~/.julia/registries/General`
┌ Warning: PlutoPkg: Failed to add/remove packages! Resetting package environment...
│   PLUTO_VERSION = v"0.19.13"VERSION = v"1.8.2"
│   old_packages =11-element Vector{String}:"CSV""Statistics""DataFrames"
│   new_packages =11-element Vector{String}:"Statistics""StatsBase""DataFrames"
│   exception =GitError(Code:ENOTFOUND, Class:OS, failed to open directory '/Users/cokes/.julia/registries/General/': Too many open files)
│    Stacktrace:
│      [1] macro expansion
│        @ /Applications/Julia-1.8.app/Contents/Resources/julia/share/julia/stdlib/v1.8/LibGit2/src/error.jl:110 [inlined]
│      [2] diff_tree(repo::LibGit2.GitRepo, tree::LibGit2.GitTree, pathspecs::String; cached::Bool)
│        @ LibGit2 /Applications/Julia-1.8.app/Contents/Resources/julia/share/julia/stdlib/v1.8/LibGit2/src/diff.jl:34
│      [3] isdiff(repo::LibGit2.GitRepo, treeish::String, paths::String; cached::Bool)
│        @ LibGit2 /Applications/Julia-1.8.app/Contents/Resources/julia/share/julia/stdlib/v1.8/LibGit2/src/LibGit2.jl:160
│      [4] #isdirty#101
│        @ /Applications/Julia-1.8.app/Contents/Resources/julia/share/julia/stdlib/v1.8/LibGit2/src/LibGit2.jl:135 [inlined]
│      [5] isdirty (repeats 2 times)
│        @ /Applications/Julia-1.8.app/Contents/Resources/julia/share/julia/stdlib/v1.8/LibGit2/src/LibGit2.jl:135 [inlined]
│      [6] (::Pkg.Registry.var"#59#63"{Base.TTY, Pkg.Registry.RegistryInstance, Vector{Tuple{String, String}}, String})(repo::LibGit2.GitRepo)
│        @ Pkg.Registry /Applications/Julia-1.8.app/Contents/Resources/julia/share/julia/stdlib/v1.8/Pkg/src/Registry/Registry.jl:402
│      [7] with(f::Pkg.Registry.var"#59#63"{Base.TTY, Pkg.Registry.RegistryInstance, Vector{Tuple{String, String}}, String}, obj::LibGit2.GitRepo)
│        @ LibGit2 /Applications/Julia-1.8.app/Contents/Resources/julia/share/julia/stdlib/v1.8/LibGit2/src/types.jl:1159
│      [8] update(regs::Vector{Pkg.Registry.RegistrySpec}; io::Base.TTY, force::Bool)
│        @ Pkg.Registry /Applications/Julia-1.8.app/Contents/Resources/julia/share/julia/stdlib/v1.8/Pkg/src/Registry/Registry.jl:401
│      [9] update(regs::Vector{Pkg.Registry.RegistrySpec}) (repeats 2 times)
│        @ Pkg.Registry /Applications/Julia-1.8.app/Contents/Resources/julia/share/julia/stdlib/v1.8/Pkg/src/Registry/Registry.jl:344
│     [10] update_registries(; force::Bool)
│        @ Pluto.PkgCompat ~/.julia/packages/Pluto/U4wvO/src/packages/PkgCompat.jl:169
│     [11] (::Pluto.var"#189#201"{Pluto.Notebook})()
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:202
│     [12] withio(f::Pluto.var"#189#201"{Pluto.Notebook}, ctx::Pkg.Types.Context, io::IOContext{IOBuffer})
│        @ Pluto.PkgCompat ~/.julia/packages/Pluto/U4wvO/src/packages/PkgCompat.jl:129
│     [13] (::Pluto.var"#182#193"{Pluto.Notebook, Pluto.IOListener, Vector{String}, Vector{String}, Bool, Bool})()
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:193
│     [14] withtoken(f::Pluto.var"#182#193"{Pluto.Notebook, Pluto.IOListener, Vector{String}, Vector{String}, Bool, Bool}, token::Pluto.Token)
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/evaluation/Tokens.jl:19
│     [15] sync_nbpkg_core(notebook::Pluto.Notebook, old_topology::Pluto.NotebookTopology, new_topology::Pluto.NotebookTopology; on_terminal_output::Pluto.var"#iocallback#209"{Pluto.ServerSession, Pluto.Notebook}, lag::Float64)
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:112
│     [16] (::Pluto.var"#206#208"{Pluto.ServerSession, Pluto.Notebook, Pluto.NotebookTopology, Pluto.NotebookTopology})()
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:262
│     [17] #205
│        @ ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:253 [inlined]
│     [18] sync_nbpkg(session::Pluto.ServerSession, notebook::Pluto.Notebook, old_topology::Pluto.NotebookTopology, new_topology::Pluto.NotebookTopology; save::Bool, take_token::Bool)
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:253
│     [19] (::Pluto.var"#260#264"{Bool, Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, Pluto.ServerSession, Pluto.Notebook})()
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/evaluation/Run.jl:396
│     [20] withtoken(f::Pluto.var"#260#264"{Bool, Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, Pluto.ServerSession, Pluto.Notebook}, token::Pluto.Token)
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/evaluation/Tokens.jl:19
│     [21] #259
│        @ ~/.julia/packages/Pluto/U4wvO/src/evaluation/Run.jl:395 [inlined]
│     [22] macro expansion
│        @ ~/.julia/packages/Pluto/U4wvO/src/evaluation/Tokens.jl:58 [inlined]
│     [23] (::Pluto.var"#252#253"{Pluto.var"#259#263"{Bool, Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, Pluto.ServerSession, Pluto.Notebook}})()
│        @ Pluto ./task.jl:484
└ @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:286
┌ Info: Backup saved to
└   backup_path = "/

then the next one after I restart is

┌ Warning: PlutoPkg: Failed to add/remove packages! Resetting package environment...
│   PLUTO_VERSION = v"0.19.13"VERSION = v"1.8.2"
│   old_packages = String[]
│   new_packages =11-element Vector{String}:"Statistics""StatsBase""DataFrames"
│   exception ="/private/var/folders/mc/q4kv7qs121gc_0h42v317dyw0000gn/T/jl_7J0gDB/Project.toml": No such file
│    Stacktrace:
│      [1] error(::String, ::String)
│        @ Base ./error.jl:44
│      [2] readstring
│        @ /Applications/Julia-1.8.app/Contents/Resources/julia/share/julia/stdlib/v1.8/TOML/src/TOML.jl:21 [inlined]
│      [3] parsefile(f::String)
│        @ TOML /Applications/Julia-1.8.app/Contents/Resources/julia/share/julia/stdlib/v1.8/TOML/src/TOML.jl:43
│      [4] _modify_compat(f!::Pluto.PkgCompat.var"#27#28"{Pkg.Types.Context}, ctx::Pkg.Types.Context)
│        @ Pluto.PkgCompat ~/.julia/packages/Pluto/U4wvO/src/packages/PkgCompat.jl:408
│      [5] write_auto_compat_entries
│        @ ~/.julia/packages/Pluto/U4wvO/src/packages/PkgCompat.jl:430 [inlined]
│      [6] (::Pluto.var"#187#199"{Vector{String}, Pluto.Notebook, Pluto.IOListener})()
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:178
│      [7] withinteractive(f::Pluto.var"#187#199"{Vector{String}, Pluto.Notebook, Pluto.IOListener}, value::Bool)
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:528
│      [8] #186
│        @ ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:150 [inlined]
│      [9] withio(f::Pluto.var"#186#198"{Vector{String}, Pluto.Notebook, Pluto.IOListener}, ctx::Pkg.Types.Context, io::IOContext{IOBuffer})
│        @ Pluto.PkgCompat ~/.julia/packages/Pluto/U4wvO/src/packages/PkgCompat.jl:129
│     [10] (::Pluto.var"#182#193"{Pluto.Notebook, Pluto.IOListener, Vector{String}, Vector{String}, Bool, Bool})()
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:149
│     [11] withtoken(f::Pluto.var"#182#193"{Pluto.Notebook, Pluto.IOListener, Vector{String}, Vector{String}, Bool, Bool}, token::Pluto.Token)
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/evaluation/Tokens.jl:19
│     [12] sync_nbpkg_core(notebook::Pluto.Notebook, old_topology::Pluto.NotebookTopology, new_topology::Pluto.NotebookTopology; on_terminal_output::Pluto.var"#iocallback#209"{Pluto.ServerSession, Pluto.Notebook}, lag::Float64)
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:112
│     [13] (::Pluto.var"#206#208"{Pluto.ServerSession, Pluto.Notebook, Pluto.NotebookTopology, Pluto.NotebookTopology})()
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:262
│     [14] #205
│        @ ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:253 [inlined]
│     [15] sync_nbpkg(session::Pluto.ServerSession, notebook::Pluto.Notebook, old_topology::Pluto.NotebookTopology, new_topology::Pluto.NotebookTopology; save::Bool, take_token::Bool)
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:253
│     [16] (::Pluto.var"#260#264"{Bool, Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, Pluto.ServerSession, Pluto.Notebook})()
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/evaluation/Run.jl:396
│     [17] withtoken(f::Pluto.var"#260#264"{Bool, Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, Pluto.ServerSession, Pluto.Notebook}, token::Pluto.Token)
│        @ Pluto ~/.julia/packages/Pluto/U4wvO/src/evaluation/Tokens.jl:19
│     [18] #259
│        @ ~/.julia/packages/Pluto/U4wvO/src/evaluation/Run.jl:395 [inlined]
│     [19] macro expansion
│        @ ~/.julia/packages/Pluto/U4wvO/src/evaluation/Tokens.jl:58 [inlined]
│     [20] (::Pluto.var"#252#253"{Pluto.var"#259#263"{Bool, Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, Pluto.ServerSession, Pluto.Notebook}})()
│        @ Pluto ./task.jl:484
└ @ Pluto ~/.julia/packages/Pluto/U4wvO/src/packages/Packages.jl:286

@SimonEnsemble
Copy link
Author

if this happens to anyone else, 🥳 resolved by deleting ~/.julia/registries/General!

@fonsp fonsp self-assigned this Oct 13, 2022
@fonsp fonsp added the package manager Pluto's built-in package manager label Oct 13, 2022
@fonsp
Copy link
Owner

fonsp commented Oct 17, 2022

Thanks @SimonEnsemble !

I have seen other issues related to the registry folder getting "corrupted" in the past, but this problem should start to get resolved by the move to a tarball registry in Julia 1.6 (JuliaLang/Pkg.jl#2017 (comment)).

The logs in this issue happened in the finally block after the actual error, where Pkg.add failed because of a corrupt registry. I fixed the error in the logs in 9aad08d , but unfortunately there are no logs about the underlying issue.

After the fix of 9aad08d , we will be able to get a better error message when this happens again, but it seems like this issue will be too difficult to reproduce, so I will close this for now.

@fonsp fonsp closed this as completed Oct 17, 2022
@fonsp
Copy link
Owner

fonsp commented Oct 17, 2022

@SimonEnsemble Do you remember setting up the General registry manually? Is it possible that you were using a git registry instead of a tarball registry? JuliaLang/Pkg.jl#2431

@SimonEnsemble
Copy link
Author

👁️
at one point I had compiled Julia from the master branch to get it to work on my M1 silicon.
other than this information, I don't recall ever doing anything manual with the General registry.

thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
package manager Pluto's built-in package manager
Projects
None yet
Development

No branches or pull requests

2 participants