Closed azmec closed 3 months ago
Reproduced, added to my list.
Hm, only intermittently reproducible, per the report. Hypothesis:
[projectid] > +page.svelte
calls Projects.get
to retrieve the corresponding projectProjectsDatabase.track
is called to track the project retrieved from Firebase, but it's set to not editable even if it's owned by the person retrieving it.This would only happen if the +page.svelte
asks for the project before the Firebase query returns, which could easily happen intermittently.
The fix would be to ensure we mark the project editable in ProjectsDatabase.get
based on the current user, and then update the project loaded to editable if the user later changes.
I believe I reproduced this successfully and that it should be resolved. Check, and if you can still reproduce, please reopen.
What happened?
Opening projects that you own should bring you to an editable instance or buffer for that project. Instead, some projects open as immutable instances or buffers when opened from external hyperlinks or the "Projects" page.
The above steps reproduce the defect with the following projects:
For the above projects, appending
?play
to the project ID in the URL and loading the URL will produce the defect described below.A related defect may be that some projects, when opened from the "Projects" page, initially appear to be immutable when in "play" mode (
?play
is appended to the project ID in the URL) but is found to be mutable when the code is revealed (when?play
is removed from the tail of the project ID in the URL).Anything else?
Below is a screenshot of an owned Wordplay project opened from an external hyperlink. The project was opened with an account that owns the project, but it is immutable.
Below is a screenshot of an owned Wordplay project opened from the "Projects" directory with an account that owns the project. In the top-right, it states "copy this project", suggesting the code is immutable.
However, clicking the eye button to see the project's code reveals that it is mutable (when
?play
is removed from the tail of the project's ID in the URL).What browsers are you seeing the problem on?
Firefox, Chrome
What operating system are you using?
macOS, Linux