-
Notifications
You must be signed in to change notification settings - Fork 1.3k
progress: do not block on async filesystems #6612
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
Conversation
|
@isidentical Personally, the second option seems to be way too convoluted and looks out of place in the callback itself. The first option seems nicer. But I'm not sure I fully understand
could you elaborate, please? |
|
I have gone through other filesystems and have been doing |
|
Hmm, that's weird. I'd expect Google Cloud Storage to provide a uniform response, unlike HTTP servers. |
|
From what I have observed, it does on the cases I have tried. This was just an example of what could have happen if it didn't (or another provider didn't, e.g a mock server). |
|
@isidentical if mock server doesn't provide it - it is a bug in the mock server and it should be fixed to follow the behaviour of the real thing. So we probably don't need to overengineer it like that and could use a simpler option. |
236a730 to
e62caa5
Compare
dvc/progress.py
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So looks like we no longer need self.fs and self.path_info anymore?
|
btw, please rebase on. top of master, we've increased timeouts for now (though windows taking half an hour is not normal) |
e62caa5 to
c9db3d9
Compare
c9db3d9 to
e2c9ba6
Compare

When an async filesystem (fsspec-level) makes a call to
set_size()callback withNone(the size is not inferrable), we call theinfo()on the dvc-level sync filesystem which delates this call to fsspec's async function run in a separate loop. This situation is creating a deadlock where we make a call from an async function (e.g_get_file) to another async function (_info) with a wrapped sync execution (info()) between them.For the simplicity, this patch drops the current behavior of consulting to
info()onset_size(None).