chingu-voyage7 / Bears-Team-13

Secret Santa Online Shop | Voyage-7 | https://chingu.io/
https://secret-santa-13.herokuapp.com
3 stars 2 forks source link

Heroku deployment crashed #59

Open innaleikina opened 4 years ago

innaleikina commented 4 years ago

I was using the site. I logged in and selected shop, then I selected an item, after selecting an item I pressed to add it to cart, but didn't select the recipient. The item didn't render the photo or price, then the site crashed for me.

I revisited it a couple hours later and did the same thing.All the photos and prices were there. I was still able to navigate the websites, but no photos loaded afterwards, not even frames. Then the website crashed completely and won't refresh

Alex-Cannon commented 4 years ago

@innaleikina I visited the site. It loaded for me. Then I...

  1. Logged in as "root"
  2. Selected "shop"
  3. Selected an item
  4. Pressed "add to cart". The photo and item rendered.

This is where the item didn't render the photo or price then crashed for you?

  1. In my case, the site did not crash. Instead, "add to cart" did nothing.

Did I follow your footsteps correctly? If so, it may have been an issue with heroku?

innaleikina commented 4 years ago

I retraced my steps. I did everything like you, except after I pressed add to cart I clicked all the nav items, and when I went back to the shop page there were no items rendering. Then I hit refresh, and the website crashed.

I think all we need is an error message if a user tries to add something to the cart without having a recipient.

Alex-Cannon commented 4 years ago

@innaleikina I wasn't able to reproduce the error. I followed these steps:

  1. Logged in as "root"
  2. Selected "shop"
  3. Pressed "add to cart". The photo and item rendered.
  4. Hit all the nav buttons except logout
  5. Went back to the "shop" page
  6. Everything rendered correctly.

Were you logged out when you went back to the shop page? If you logged out, then hit the back arrow in your browser, it could have tried to get the shop items, but since you weren't authenticated, failed.

innaleikina commented 4 years ago

Sorry for taking so long. I will take a video of the issue tomorrow and will send it to you.

innaleikina commented 4 years ago

https://drive.google.com/file/d/1Aji8MvEtZ5YgvFVBYemMPYVP7mQDIuf7/view here is a link to the screen cast. I'm not sure if it shows well, but after I added to cart and then clicked around and came back to shop, I refreshed.

Alex-Cannon commented 4 years ago

Interesting. It looks like it may have to do with a specific item. Let me check the database to see if there's an unordinary item.

Alex-Cannon commented 4 years ago

Ok, I think I found the issue. I haven't tested this, but it appears to be an issue with GETing a single item from the API. When I login as root (admin), I do NOT have the issue.

This has something to do with the logic separating admin users from non-admin users or it could be an issue you have by not having an active event. One of the two. I don't have time to fix this today, but I'll get to it as soon as I can. I plan to get a fix by the end of the week.