I have a Ruby on Rails web application (deployed on Google App Engine) using Spree/Solidus core, which is connected to Google Cloud Storage for file storage. We have an admin dashboard for our app where we can upload images related to objects and we have a webpage in which we show those images. The images show up at first when we recently deployed the project, but they fail to show up after a while! We get the following 400 error for the images shown on the console:
Failed to load resource: the server responded with a status of 400 ()
When we check the admin dashboard, the same images are still visible, but they are shown as broken on the homepage. Our Google Cloud Storage bucket has public access (though I don't think it really needs it, since the app is on the same project and we have the GC_access JSON file deployed).
We are using the following code to show the images:
<% if image_url = image.try(:url, size) %>
<%= image_tag image_url %>
<% else %>
<span class="image-placeholder <%= size %>"></span>
<% end %>
I will appreciate any help or advice on what to try to fix this issue! I'm not sure what other information may be helpful, but if you think more information on something can be helpful I can add more details.