Closed zspencer closed 10 months ago
@KellyAH or @daltonrpruitt - Are either of you willing to write up some repro steps for this (or a test that isolates it?)
I have 5 assigned issues right now. I don't have anymore bandwidth for this one. Can you take it @daltonrpruitt ? Thanks. 🙏 🙇♀️
Sure thing. Will try do that in a couple hours ish.
Steps to reproduce:
convene
(the base dev instance for now), sign in as "space-member" via regular stepsExpected Behavior: Return to Edit screen for "Listed Room 1" with "Markdown Text Block" gone (so no Gizmos in this case) Actual Behavior: Returned to Edit screen for "Listed Room 1" with "Markdown Text Block" still present
Steps 5-6 can be repeated any number of times for a Gizmo with the same results. This also applies to the other Gizmos that have "Remove Gizmo 🗑️" as an option in their configure page: "Livestream" and "Embedded Form"
These were great! I added some typographical flourishes and put them in the main issue body so it's easier to find without scrolling.
I'm also going to assign this to myself so I know what to pick up next, but if the spirit moves you and anyone wants to tilt at fixing it; don't let my glowering avatar stop you!
Also, if I get to it before next wednesday, it means Convene will have a system test that @KellyAH can crib off of for https://github.com/zinc-collective/convene/pull/1562!
@daltonrpruitt - Can you confirm that this is fixed in production when you get a chance and then close this out?
I have tried to go through this a few times today, but I keep running into different issues when I try to get to the configure/edit page of my space. The latest one occurs in a fresh instance when I try to go to the configuration/edit page (clicking the gear) for a room I add. The error is shown below. I think it has something to do with some of the changes we were looking at today? I can try to look at it more later.
Also, my fresh devcontainer instance does not have the two spaces it usually has (System Test and something else). Any insight on this? Is the bin/setup
script not doing what I expected it to? Or is something else maybe going on?
I have tried to go through this a few times today, but I keep running into different issues when I try to get to the configure/edit page of my space. The latest one occurs in a fresh instance when I try to go to the configuration/edit page (clicking the gear) for a room I add. The error is shown below. I think it has something to do with some of the changes we were looking at today? I can try to look at it more later.
Also, my fresh devcontainer instance does not have the two spaces it usually has (System Test and something else). Any insight on this? Is the
bin/setup
script not doing what I expected it to? Or is something else maybe going on?
The error implies there's no space.entrance
. 🤔 Maybe no space exists in your dev environment. I think I have to always manually create a space when start from a fresh dev environment.
Lemme delete spaces on my local and see if I can replicate the break.
🤦♀️ I also notice I forgot to add space.entrance.furnitures.blank?
to the outer if condition when coding https://github.com/zinc-collective/convene/pull/1593
🤔 Maybe I should also add a safe navigational operator too to handle nils.
<% if space&.entrance&.furnitures.blank? %>
This was after creating a space and trying to go to its edit page. So, there was no entrance, like you said, but the space did exist (I thought, anyways?)
And yeah, that next part makes sense to me, since if you are checking for both whether the entrance exists and if the entrance has furniture, then there is a non-zero chance there is no entrance to fetch furniture for. That operator seems like a good way to avoid more complex/dense branching here. I am not familiar with the syntax, so I'm a little hesitant to say that is definitely set up to do what you want it to, but I'm sure testing or reading the docs more would clear that up.
I will try to look into this more before Wednesday's session. In the meantime, if we want this closed sooner, I will trust anyone saying it's fixed and can gladly close this. (Until I find a way to break it in a different way and have to open another issue or re-open this one for some reason... 😅 🤞 let's hope not)
Woops! I should have caught the need for a safe navigation operator when reviewing https://github.com/zinc-collective/convene/pull/1593! But yes, tossing a space.entrance&.gizmos.present?
should fix this.
@daltonrpruitt - now that the missing-entrance-causes-boom issue is resolved; if you can retest I would be delighted!
It took a few days to get back to this, but I can confirm that the three Gizmo
s now behave in a way that doesn't allow this problem to occur. Thank you all for the work on this!
To Do
Gizmo
Steps to Reproduce:
convene
(the base dev instance for now), sign in as "space-member" via regular stepsExpected Behavior: Return to Edit screen for "Listed Room 1" with "Markdown Text Block" gone (so no Gizmos in this case)
Actual Behavior: Returned to Edit screen for "Listed Room 1" with "Markdown Text Block" still present
Note: Steps 5-6 can be repeated any number of times for a Gizmo with the same results. This also applies to the other Gizmos that have "Remove Gizmo 🗑️" as an option in their configure page: "Livestream" and "Embedded Form"