Skip to content

Unintuitive navigation in Problem Editor if a .tmp version exists #2782

@dlglin

Description

@dlglin

If there is a .tmp version of a .pg file, then the Problem Editor always loads that instead of the actual file that the user requested. I run into two issues with this:

  1. If I'm editing a .pg file I often miss the message at the top telling me that there are unsaved changes, and end up building new changes on top of experimental stuff that I never intended to keep.
  2. In 2.20 when you click on the Problem Editor you are asked to choose between a new problem template, an existing file, or a sample problem. If I choose the first or third option then I expect to get what I asked for (i.e. a blank problem or a sample problem), but if there is a .tmp version, then I'm not actually getting a sample problem. Instead I'm getting my previous edits of the sample problem. There is still the message at the top about unsaved changes, but it isn't what I asked for.

I'm not sure how to make this more intuitive.

For the second issue one option is to not allow edits of sample problems and blank problems until a copy with a new name has been saved, which would mean that there would never be a .tmp version for the Problem Editor to find. This would guarantee that you always get the true blank/sample problem that you asked for.

A different approach is to make the user decide whether to use the edited version or the original as soon as the problem is loaded into the editor. i.e. if a .tmp version of the requested file exists, then send the user to a screen that says "There are unsaved changes to this problem file", and then makes them explicitly choose whether to revert the changes and edit the original, or continue from the unsaved changes.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions