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

Revised handling of PERSISTENCE_HASH data #809

Merged
merged 1 commit into from
Apr 27, 2023

Conversation

taniwallach
Copy link
Member

@taniwallach taniwallach commented Apr 13, 2023

Persistent problem data - modify to retrieve from $envir and to allow update and get operations.
Paired with openwebwork/webwork2#1940
The webwork2 side will now store this in a special field.

@taniwallach
Copy link
Member Author

This is initially intended to allow saving "state" of scaffolds so I can resume work on #506 however it will support any other data a problem author might want to remain available.

I think it should provide a better mechanism to support file (image uploads) as envisioned in #482 than in the last_answer field as currently done there.

The problem author decides when data gets stored into the PERSISTENCE_HASH and the webwork2 side will save it after the problem is rendered (and not only on submission of an answer).

Copy link
Member

@drgrice1 drgrice1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This generally looks good, but I have a few suggestions that I think clarify the usage of the new methods added.

lib/PGcore.pm Outdated Show resolved Hide resolved
lib/PGcore.pm Outdated Show resolved Hide resolved
macros/PG.pl Outdated Show resolved Hide resolved
macros/PG.pl Outdated Show resolved Hide resolved
macros/PG.pl Outdated Show resolved Hide resolved
taniwallach added a commit to taniwallach/pg that referenced this pull request Apr 19, 2023
and to allow update and get operations. The webwork2 side
will now store this in a special field.
Includes changes and suggestions from Dr. Glenn Rice.
See: openwebwork#809
@taniwallach taniwallach marked this pull request as ready for review April 19, 2023 12:32
@taniwallach taniwallach requested a review from drgrice1 April 19, 2023 12:32
lib/PGcore.pm Outdated Show resolved Hide resolved
and to allow update and get operations. The webwork2 side
will now store this in a special field.
Includes changes and suggestions from Dr. Glenn Rice.
See: openwebwork#809
Copy link
Member

@drgrice1 drgrice1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good.

@taniwallach taniwallach changed the base branch from develop to PG-2.18 April 22, 2023 19:20
@taniwallach taniwallach requested review from pstaabp and removed request for pstaabp April 25, 2023 22:15
@pstaabp pstaabp merged commit 9ee0b9e into openwebwork:PG-2.18 Apr 27, 2023
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

Successfully merging this pull request may close these issues.

3 participants