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

[Q&A]: Possible to retain values of code written in a code cell on refresh? #21

Open
tomicapretto opened this issue Jun 14, 2024 · 4 comments
Labels
s: question-answered t: question Further information is requested

Comments

@tomicapretto
Copy link

What's your question?

I would like to know if it's on the roadmap to have the ability to save the code that one writes on a pyodide-python cell.
We're considering using this extension in our class. Students would write code in the cells, and it would be nice if the changes they made in there are not lost when they load the same file again.

Thanks very much for the extension, it's really interesting.

@tomicapretto tomicapretto added s: question-needs-answer Question has yet to be answered. t: question Further information is requested labels Jun 14, 2024
@coatless
Copy link
Collaborator

In short, yes.

Two kinds of files we're looking at:

  1. history of all commands run.
  2. last state of active code cells.

@coatless
Copy link
Collaborator

For the when part, that'll be the infamous soon (tm).

@coatless coatless added s: question-answered and removed s: question-needs-answer Question has yet to be answered. labels Jun 16, 2024
@coatless
Copy link
Collaborator

@tomicapretto so a happy update for you... Over in {quarto-webr} I managed to knock out the logging of commands.

c.f. coatless/quarto-webr#213

So, I'll probably incorporate a similar scope into the pyodide variant sometime this week.

@coatless coatless changed the title [Q&A]: [Q&A]: Possible to retain values of code written in a code cell on refresh? Jun 16, 2024
@tomicapretto
Copy link
Author

@coatless this is amazing, thank you very much. Anything I can do to help you?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
s: question-answered t: question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants