Hi all, suddenly from time to time my Appsheet app doesnโt show pictures when running on iOS as can be seen on this clip. There are moments that everything works OK and therefore I thought it has something to do with Internet speed but it doesnโt seem to be the case. Iโve reported the problem to support but it has being there for 5 days now with no progress.
Iโd appreciate any help to get it fixed even though I think it would be up to Appsheet to do it but may be there is some work around to be used
Many thanks in advance
Hi @iSimon,
I took a look in your app and it seems like Drive is rate limiting your access.
Your app has many images in a deck view, so whenever you scroll down, the app need to fetch more images from Drive. After doing it for a while, Drive sees too many image requests coming from the device and blocks it for a certain amount of time.
One more thing to notice is that the images in your app were added as links to Drive, and werenโt uploaded through AppSheet. Our server can cache images that were uploaded through an app, but it doesnโt cache generic urls. If the images were cached in our server, the app could fetch the image from there instead of Drive and the rate limiting would less likely to be triggered.
Hereโs what you can do to fix this:
Doing any of these should solve the problem.
Hi Gil, many thanks for your email, Iโm in doubt about your diagnosis because sometimes everything works fine and I wonder why it would be so. If the problem is related with the quantity of picture accessโฆin other words as the quantity of picture and picture access is constant then in my humble opinion it should always work or should notโฆmoreover as a matter of fact it was working until sometime ago and suddenly it started to show this strange behaviour.
Anyway having a workaround will be good enough for me and therefore let me explore the options you gave:
Re-upload the images through the app or change the values in your image column to be the path to where the images are located in Drive relative to the spreadsheet. Doing either one of these will cause the images to be cached by our servers.
Not sure how to do thisโฆcan you guide me? Moreover how can I automatically update all the links I already have?
Turning on offline content caching (Behavior -> Offline/Sync -> โStore content for offline useโ). This will cause the app to cache all images to in the userโs device, so each image will be fetched from Drive only once. Note that since your app has a massive amount of images, this would take a lot of storage space on the userโs device.
As you mentioned this wouldnโt be an option due to the userโs storage required.
Donโt display the images in the deck view. You can still show them in a detail view once the user clicks on a row, but taking the images off the deck view will eliminate most of the calls to Drive.
This option will negatively impact the beauty of the application user interface and doesn`t seem to be a valid approach.
That leaves me with the first option only but for it to work Iโd need your help.
p.s.: shouldn`t this behaviour be mentioned in the documentation as some kind of limitation or is it mentioned and I didnโt see it?
Once again many thanks for your help
I myself agree with @Gilโs assessment.
@iSimon,
The reason youโre not facing this issue all the time, is that Driveโs rate limiting only takes effect after many images were fetched over a short period of time. And even then, itโs only blocking the app for some time.
Unfortunately, I donโt know of any automatic way to make this change. Let me try to explain where the images should be located:
Letโs say your spreadsheet is called my_spreadsheet
, and itโs located in a drive folder called AppSheet
. Youโll need to create a new folder under the AppSheet
folder named (for example) my_images
, and place a photo named (again, for example) photo0001.jpeg
in the my_images
folder.
Then, in your spreadsheet, whenever you want to reference this photo youโll have use: my_images\photo0001.jpeg
.
Everything I described here happens automatically when you use the app to upload a photo.
I donโt believe this issue appears in our docs, but this is a very niche issue. It only effects apps with a large number of images, that wasnโt uploaded through the app, displayed in a scrollable view and using Drive (as apposed to SQL database for example) as a data source.
Hi Gil and Steve, many thanks for your answers and recommendations.
I did as suggested and the problem was fixed.
Best.
User | Count |
---|---|
42 | |
33 | |
24 | |
23 | |
14 |