diff options
author | Omar Sandoval <osandov@fb.com> | 2018-11-13 23:46:57 -0800 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2018-11-26 16:45:14 +0100 |
commit | 5776a70b3024d03eeb4beb57b66b8a5092a803db (patch) | |
tree | cc2ede36a1b7c9de0b4343d44939c93fa3c73516 /libbtrfsutil/python/module.c | |
parent | 563affcd42d4575d477e0f7fe067e1259dfb3687 (diff) |
libbtrfsutil: change async parameters to async_ in Python bindings
async became a keyword in Python 3.7, so, e.g., create_subvolume('foo',
async=True) is now a syntax error. Fix it with the Python convention of
adding a trailing underscore to the keyword (async -> async_). This is
what several other Python libraries did to handle this.
Signed-off-by: Omar Sandoval <osandov@fb.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'libbtrfsutil/python/module.c')
-rw-r--r-- | libbtrfsutil/python/module.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/libbtrfsutil/python/module.c b/libbtrfsutil/python/module.c index 2dbdc7be..625cc9c6 100644 --- a/libbtrfsutil/python/module.c +++ b/libbtrfsutil/python/module.c @@ -233,22 +233,22 @@ static PyMethodDef btrfsutil_methods[] = { "this ID instead of the given path"}, {"create_subvolume", (PyCFunction)create_subvolume, METH_VARARGS | METH_KEYWORDS, - "create_subvolume(path, async=False)\n\n" + "create_subvolume(path, async_=False)\n\n" "Create a new subvolume.\n\n" "Arguments:\n" "path -- string, bytes, or path-like object\n" - "async -- create the subvolume without waiting for it to commit to\n" + "async_ -- create the subvolume without waiting for it to commit to\n" "disk and return the transaction ID"}, {"create_snapshot", (PyCFunction)create_snapshot, METH_VARARGS | METH_KEYWORDS, - "create_snapshot(source, path, recursive=False, read_only=False, async=False)\n\n" + "create_snapshot(source, path, recursive=False, read_only=False, async_=False)\n\n" "Create a new snapshot.\n\n" "Arguments:\n" "source -- string, bytes, path-like object, or open file descriptor\n" "path -- string, bytes, or path-like object\n" "recursive -- also snapshot child subvolumes\n" "read_only -- create a read-only snapshot\n" - "async -- create the subvolume without waiting for it to commit to\n" + "async_ -- create the subvolume without waiting for it to commit to\n" "disk and return the transaction ID"}, {"delete_subvolume", (PyCFunction)delete_subvolume, METH_VARARGS | METH_KEYWORDS, |