You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Disk size gets trimmed to default size on init method #240
If my disk size is more than default size, it gets trimmed to default size on initialising PINCache.
Due to that, my images are downloading again and again and getting stored in disk.
changed the title [-]Disk size gets trimmed to default size on Init itself[/-][+]Disk size gets trimmed to default size on init method[/+]on Mar 28, 2019
@rajeshs73 if you set the byteLimit immediately after initialization this shouldn't be an issue in practice (though I agree we should allow setting this on init) because the trimming doesn't happen until the file state is known which takes a while. Have you tried setting the byteLimit immediately after initializing the disk?
Activity
rajeshs73 commentedon Mar 28, 2019
One suggestion would be, Keeping byteLimit as initialising parameter for PINCache.
[-]Disk size gets trimmed to default size on Init itself[/-][+]Disk size gets trimmed to default size on init method[/+]garrettmoon commentedon Jun 11, 2019
@rajeshs73 if you set the byteLimit immediately after initialization this shouldn't be an issue in practice (though I agree we should allow setting this on init) because the trimming doesn't happen until the file state is known which takes a while. Have you tried setting the byteLimit immediately after initializing the disk?
rajeshs73 commentedon Jun 12, 2019
@garrettmoon I did set the byteLimit soon after the initialization. It falls back to default size on app open (mostly 6 out of 10 times)
trungnguyen1791 commentedon Sep 7, 2019
Did you solve this problem @rajeshs73?
rajeshs73 commentedon Sep 16, 2019
No. I haven't.
mycroftcanner commentedon Jul 15, 2021
Any chance we could fix this?
mycroftcanner commentedon Jul 15, 2021
@rajeshs73 are you initialising PINCache and setting its configuration from the main thread?
gumbypp commentedon Jun 16, 2022
this is fixed by #312, which as on
masterafter the 3.0.3 release