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

i've lost a lot of hours of work due to: "Failed to load notebook" #2794

Closed
carrapaz opened this issue Jan 28, 2024 · 4 comments
Closed

i've lost a lot of hours of work due to: "Failed to load notebook" #2794

carrapaz opened this issue Jan 28, 2024 · 4 comments

Comments

@carrapaz
Copy link

carrapaz commented Jan 28, 2024

i had a big file that i was using to prepare my exam (albeith still in the early phase) it was more than 20hours worth of work and now i cannot find a way to open it.
the entire computer crashed during a cell execution after i computed a parametric function and i had to manually turn it off. after turning it back on the file is unaccessible
here is the error:
image

File is not a Pluto.jl notebook.
Stacktrace:
[1] error(s::String)
@ Base .\error.jl:35
[2] _notebook_metadata!(io::IO)
@ Pluto C:\Users\carra.julia\packages\Pluto\h22mT\src\notebook\saving and loading.jl:166
[3] load_notebook_nobackup(io::IO, path::AbstractString)
@ Pluto C:\Users\carra.julia\packages\Pluto\h22mT\src\notebook\saving and loading.jl:313
[4] #67
@ Pluto C:\Users\carra.julia\packages\Pluto\h22mT\src\notebook\saving and loading.jl:339 [inlined]
[5] open(::Pluto.var"#67#68"{String}, ::String, ::Vararg{String}; kwargs::@kwargs{})
@ Base .\io.jl:396
[6] open
@ Base .\io.jl:393 [inlined]
[7] load_notebook_nobackup(path::String)
@ Pluto C:\Users\carra.julia\packages\Pluto\h22mT\src\notebook\saving and loading.jl:338
[8] load_notebook(path::String; disable_writing_notebook_files::Bool)
@ Pluto C:\Users\carra.julia\packages\Pluto\h22mT\src\notebook\saving and loading.jl:357
[9] load_notebook
@ Pluto C:\Users\carra.julia\packages\Pluto\h22mT\src\notebook\saving and loading.jl:347 [inlined]
[10] open(session::Pluto.ServerSession, path::String; execution_allowed::Bool, run_async::Bool, compiler_options::Nothing, as_sample::Bool, risky_file_source::Nothing, clear_frontmatter::Bool, notebook_id::Base.UUID)
@ Pluto.SessionActions C:\Users\carra.julia\packages\Pluto\h22mT\src\webserver\SessionActions.jl:68
[11] open
@ C:\Users\carra.julia\packages\Pluto\h22mT\src\webserver\SessionActions.jl:44 [inlined]
[12] (::Pluto.var"#try_launch_notebook_response#294"{Pluto.var"#try_launch_notebook_response#288#295"{Pluto.ServerSession}})(action::typeof(Pluto.SessionActions.open), path_or_url::String; as_redirect::Bool, title::String, advice::String, home_url::String, action_kwargs::@kwargs{execution_allowed::Bool, as_sample::Bool, risky_file_source::Nothing})
@ Pluto C:\Users\carra.julia\packages\Pluto\h22mT\src\webserver\Router.jl:23
[13] (::Pluto.var"#serve_openfile#297"{Pluto.ServerSession})(request::HTTP.Messages.Request)
@ Pluto C:\Users\carra.julia\packages\Pluto\h22mT\src\webserver\Router.jl:51
[14] (::HTTP.Handlers.Router{typeof(Pluto.default_404), typeof(HTTP.Handlers.default405), Nothing})(req::HTTP.Messages.Request)
@ HTTP.Handlers C:\Users\carra.julia\packages\HTTP\bDoga\src\Handlers.jl:439
[15] (::Pluto.var"#281#283"{HTTP.Handlers.Router{typeof(Pluto.default_404), typeof(HTTP.Handlers.default405), Nothing}})(request::HTTP.Messages.Request)
@ Pluto C:\Users\carra.julia\packages\Pluto\h22mT\src\webserver\Authentication.jl:101
[16] #278
@ C:\Users\carra.julia\packages\Pluto\h22mT\src\webserver\Authentication.jl:53 [inlined]
[17] (::Pluto.var"#381#391"{Pluto.ServerSession, Pluto.var"#278#280"{Pluto.var"#281#283"{HTTP.Handlers.Router{typeof(Pluto.default_404), typeof(HTTP.Handlers.default405), Nothing}}, Pluto.ServerSession}})(http::HTTP.Streams.Stream{HTTP.Messages.Request, HTTP.Connections.Connection{Sockets.TCPSocket}})
@ Pluto C:\Users\carra.julia\packages\Pluto\h22mT\src\webserver\WebServer.jl:274
[18] #invokelatest#2
@ .\essentials.jl:887 [inlined]
[19] invokelatest
@ .\essentials.jl:884 [inlined]
[20] handle_connection(f::Function, c::HTTP.Connections.Connection{Sockets.TCPSocket}, listener::HTTP.Servers.Listener{Nothing, Sockets.TCPServer}, readtimeout::Int64, access_log::Nothing)
@ HTTP.Servers C:\Users\carra.julia\packages\HTTP\bDoga\src\Servers.jl:450
[21] (::HTTP.Servers.var"#16#17"{Pluto.var"#381#391"{Pluto.ServerSession, Pluto.var"#278#280"{Pluto.var"#281#283"{HTTP.Handlers.Router{typeof(Pluto.default_404), typeof(HTTP.Handlers.default405), Nothing}}, Pluto.ServerSession}}, HTTP.Servers.Listener{Nothing, Sockets.TCPServer}, Set{HTTP.Connections.Connection}, Int64, Nothing, Base.Semaphore, HTTP.Connections.Connection{Sockets.TCPSocket}})()
@ HTTP.Servers `C:\Users\carra.julia\packages\HTTP\bDoga\src\Servers.jl:386

this is what i see if i open it with vsc...

image
same things with the backups
image

all the othe notebooks work

@fonsp
Copy link
Owner

fonsp commented Jan 29, 2024

I'm really sorry that this happened! I'm not sure how Pluto could generate a corrupt file, something really bad must have happened in the OS.

Can you send us the VoloDV.jl file? You might need to put it in a .zip to be able to attach it to this issue

@carrapaz
Copy link
Author

carrapaz commented Jan 29, 2024

sure here it is.
corrupted one: VoloDV.zip
thankfully I remebered I exported to a html to show a friend and i was able to recover some of it :D
also main reason it took long was because it is my first time coding in pluto and julia for a project but now i'm getting faster.
since you are here may I ask if it could be interesting (ofc after translating it in english) to gift this notebook once finished? i mean like the other examples and open sourcing it.
i'm an aereospace engeneering student from Polimi in italy and this is my last exam atmospheric flight mechanics this is where i am at with the notebook:
recovered one: VoloDVUpdated.zip
maybe somebody else is interested in learning how airplanes fly :)

@fonsp
Copy link
Owner

fonsp commented Jan 29, 2024

Hey @carrapaz! Happy to hear that you were able to recover some of it! I looked at the corrupted file, but it is empty. If you open it (with read("VoloDV.jl")), you see that every byte is 0.

The notebook looks really cool!! We would be happy to feature it, feel free to make a Pull Request to https://github.com/JuliaPluto/featured to add it. Be sure to write a little introduction and maybe add a picture. Right now you go straight into the mathematics ("con r si indica il vettore posizione in..."), but people reading the featured notebooks come from all different backgrounds, and they might not immediately know what the notebook is about.

I would actually propose that you submit the notebook in Italian! There are lots of other Italian-speaking people out there who might really appreciate to read something in their native language. In fact, we were hoping to find more featured notebooks that are not written in English! Let me know if you have any doubts or questions :)

@carrapaz
Copy link
Author

thanks for taking the time to look into the file and for the the advices @fonsp ! I will surely do that and i will gladly submit once is done, right now is at only 10% of what i need to do but it should be done in about a couple of weeks.
i'll close the issue now and hopefully open the pull request soon, cya! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants