Sometimes the font color of `julia>` in the VSCode REPL will become yellow

Sometimes the font color of julia> in the VSCode REPL will become yellow:
image
Normal:
image

I know when there are some errors in the code it will become yellow, but sometimes it still keeps yellow even I have fixed the errors.

Revise.jl will change the color of the prompt if it finds an error that prevents it from working. Unfortunately this is not documented at all :expressionless:

It usually also shows a warning indicating that it’s a revise problem, and that you should try running Revise.retry(). Though I don’t know why that doesn’t appear in this case.

1 Like

Thank you! Although nothing has changed after I ran Revise.retry() :handshake: :grinning:

image

There are a few reasons is can stay yellow, one is if you switched to another REPL mode when it was fixed. Similarly, if you enter another REPL mode and a revise error occurs that mode can become yellow instead. Once this mixup has occurred, it has to be manually fixed or the Julia REPL restarted.

1 Like

Oh, so it is! Thank you very much! :handshake:

But I’m not ready to restart the REPL for quite some time, because there is
important data in it that I haven’t found a proper way to save… :smiling_face_with_tear:

I have heard it can be unreliable, but JDL2.jl has worked fine for me for short-term data storage: save variables to file, restart REPL, load variables from file, continue.

1 Like

Yes, I’m aware of it. thanks! But unfortunately, I have been just faced with a situation that it can’t save&load a trained model successfully. :woozy_face: