Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disk size gets trimmed to default size on init method #240

Open
rajeshs73 opened this issue Mar 28, 2019 · 8 comments
Open

Disk size gets trimmed to default size on init method #240

rajeshs73 opened this issue Mar 28, 2019 · 8 comments

Comments

@rajeshs73
Copy link

rajeshs73 commented Mar 28, 2019

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.

I have set the byteLimit to 100MB too.

@rajeshs73
Copy link
Author

One suggestion would be, Keeping byteLimit as initialising parameter for PINCache.

@rajeshs73 rajeshs73 changed the title Disk size gets trimmed to default size on Init itself Disk size gets trimmed to default size on init method Mar 28, 2019
@garrettmoon
Copy link
Collaborator

@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
Copy link
Author

@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
Copy link

Did you solve this problem @rajeshs73?

@rajeshs73
Copy link
Author

Did you solve this problem @rajeshs73?

No. I haven't.

@mycroftcanner
Copy link

Any chance we could fix this?

@mycroftcanner
Copy link

@rajeshs73 are you initialising PINCache and setting its configuration from the main thread?

@gumbypp
Copy link

gumbypp commented Jun 16, 2022

this is fixed by #312, which as on master after the 3.0.3 release

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants