webdav: fix macos-finder connect delay (closes #1242);

if both `quota-available-bytes` and `quotaused` are ignored
(not even returned as 404), then macos Finder is able to
connect instantly, avoiding this longstanding bug in macos

the presence of `quotaused` is the trigger for this logic, which
is a property apple invented and only apple uses, meaning we can
safely break the webdav spec as required in this case

thx @freddyheppell for the observation
This commit is contained in:
ed
2026-01-25 16:35:15 +00:00
parent 296362fc84
commit 8e046fb6a8

View File

@@ -1833,7 +1833,9 @@ class HttpCli(object):
zi = (
vn.flags["du_iwho"]
if vn.realpath and "quota-available-bytes" in props
if vn.realpath
and "quota-available-bytes" in props
and "quotaused" not in props # macos finder; ingnore it
else 0
)
if zi and (
@@ -1864,10 +1866,6 @@ class HttpCli(object):
"quota-available-bytes": str(bfree),
"quota-used-bytes": str(btot - bfree),
}
if "quotaused" in props: # macos finder crazytalk
df["quotaused"] = df["quota-used-bytes"]
if "quota" in props:
df["quota"] = df["quota-available-bytes"] # idk, makes it happy
else:
df = {}
else: