{"record":{"id":"72be36e2a855eb99","repo":"juicedata/juicefs","slug":"the-proppatch-method-is-not-currently-enabled-plea","errorCode":null,"errorMessage":"The PROPPATCH method is not currently enabled,please add the --enable-proppatch parameter and run it again","messagePattern":"The PROPPATCH method is not currently enabled,please add the --enable-proppatch parameter and run it again","errorType":"http","errorClass":null,"httpStatus":501,"severity":"error","filePath":"pkg/fs/http.go","lineNumber":334,"sourceCode":"\t//\n\t// On the other hand, the Go standard library's encoding/xml package\n\t// accepts an empty xmlns namespace, as per the discussion at\n\t// https://github.com/golang/go/issues/8068\n\t//\n\t// Empty namespaces seem disallowed in the second (2006) edition of the XML\n\t// standard, but allowed in a later edition. The grammar differs between\n\t// http://www.w3.org/TR/2006/REC-xml-names-20060816/#ns-decl and\n\t// http://www.w3.org/TR/REC-xml-names/#dt-prefix\n\t//\n\t// Thus, we assume that the propfind_invalid2 test is obsolete, and\n\t// hard-code the 400 Bad Request response that the test expects.\n\tif r.Header.Get(\"X-Litmus\") == \"props: 3 (propfind_invalid2)\" {\n\t\thttp.Error(w, \"400 Bad Request\", http.StatusBadRequest)\n\t\treturn\n\t}\n\n\tif !h.EnableProppatch && r.Method == \"PROPPATCH\" {\n\t\thttp.Error(w, \"The PROPPATCH method is not currently enabled,please add the --enable-proppatch parameter and run it again\", http.StatusNotImplemented)\n\t\treturn\n\t}\n\n\th.Handler.ServeHTTP(w, r)\n}\n\nfunc newWebdavHandler(fs *FileSystem, config WebdavConfig) http.Handler {\n\tctx := meta.NewContext(uint32(os.Getpid()), uint32(utils.GetCurrentUID()), []uint32{uint32(utils.GetCurrentGID())})\n\thfs := &webdavFS{ctx, fs, uint16(utils.GetUmask()), config}\n\tsrv := &webdav.Handler{\n\t\tFileSystem: hfs,\n\t\tLockSystem: webdav.NewMemLS(),\n\t\tLogger: func(r *http.Request, err error) {\n\t\t\tif err != nil {\n\t\t\t\tlogger.Errorf(\"WEBDAV [%s]: %s, ERROR: %s\", r.Method, r.URL, err)\n\t\t\t} else {\n\t\t\t\tlogger.Debugf(\"WEBDAV [%s]: %s\", r.Method, r.URL)\n\t\t\t}","sourceCodeStart":316,"sourceCodeEnd":352,"githubUrl":"https://github.com/juicedata/juicefs/blob/c9a67b23e8e08ec23ec331aa6f1675e2319e921c/pkg/fs/http.go#L316-L352","documentation":"The WebDAV server rejects PROPPATCH requests with HTTP 501 unless explicitly enabled, because property modification (dead properties / live property updates such as last-modified) is disabled by default in JuiceFS. ServeHTTP in pkg/fs/http.go intercepts PROPPATCH before delegating to the webdav handler when h.EnableProppatch is false.","triggerScenarios":"Issuing a PROPPATCH method request (e.g. via a WebDAV client trying to set properties or update mtime) against a WebDAV server started without the --enable-proppatch flag.","commonSituations":"WebDAV clients like Windows mapped drives, Cyberduck, or sync tools that attempt to preserve timestamps by setting properties on upload; CI tools copying files with metadata preservation.","solutions":["Restart the WebDAV server with the --enable-proppatch flag to allow PROPPATCH","Configure the client to skip setting WebDAV properties / timestamps (e.g. mount with read-only property semantics or disable mtime preservation)","Treat the 501 as 'server does not support property modification' and fall back to plain PUT/GET operations"],"exampleFix":"// before\njuicefs webdav sqlite3://test.db /mnt/jfs\n// after\njuicefs webdav --enable-proppatch sqlite3://test.db /mnt/jfs","handlingStrategy":"fallback","validationCode":"// Feature-detect PROPPATCH with an OPTIONS request before using it\nresp, _ := http.NewRequest(\"OPTIONS\", url, nil); // check Allow header for PROPPATCH","typeGuard":"func proppatchSupported(allowMethods []string) bool {\n\tfor _, m := range allowMethods { if m == \"PROPPATCH\" { return true } }\n\treturn false\n}","tryCatchPattern":"resp, err := client.Do(proppatchReq)\nif err != nil { return err }\nif resp.StatusCode == http.StatusNotImplemented { /* skip property update */ return nil }","preventionTips":["Start the WebDAV server with --enable-proppatch if clients need timestamp/property preservation","Feature-detect via OPTIONS Allow header before issuing PROPPATCH","Configure WebDAV clients to tolerate 501 on property updates"],"tags":["http","webdav","feature-flag"],"backgroundTag":"feature-not-enabled","analyzedSha":"c9a67b23e8e08ec23ec331aa6f1675e2319e921c","analyzedAt":"2026-09-06T17:55:48.476Z","contentChangedAt":"2026-09-06T17:55:48.476Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}