diff --git a/snakemake/io.py b/snakemake/io.py
index 1d5bf24b..d3fa5d6a 100755
--- a/snakemake/io.py
+++ b/snakemake/io.py
@@ -955,7 +955,7 @@ def expand(*args, **wildcards):
         combinator = product
     elif len(args) == 2:
         combinator = args[1]
-    if isinstance(filepatterns, str):
+    if isinstance(filepatterns, str) or isinstance(filepatterns, Path):
         filepatterns = [filepatterns]
 
     def path_to_str(f):
diff --git a/snakemake/workflow.py b/snakemake/workflow.py
index 5dc4f148..ccf603d3 100644
--- a/snakemake/workflow.py
+++ b/snakemake/workflow.py
@@ -952,7 +952,7 @@ class Workflow:
 
         success = scheduler.schedule()
 
-        if not immediate_submit:
+        if not immediate_submit and not dryrun:
             dag.cleanup_workdir()
 
         if success:

diff --git a/tests/test_io.py b/tests/test_io.py
index bbad3b13..a53bad2f 100644
--- a/tests/test_io.py
+++ b/tests/test_io.py
@@ -1,3 +1,5 @@
+from pathlib import PosixPath
+
 from snakemake.io import _wildcard_regex, expand
 from snakemake.exceptions import WildcardError
 
@@ -100,3 +102,6 @@ def test_expand():
     assert sorted(
         expand(["a: {a} + b: {b}", "c: {c}"], a="aa", b=["b", "bb"], c=["c", "cc"])
     ) == sorted(["a: aa + b: b", "a: aa + b: bb", "c: c", "c: cc"])
+
+    # expand on pathlib.Path objects
+    assert expand(PosixPath() / "{x}" / "{y}", x="Hello", y="world",) == ["Hello/world"]

Support pathlib in expand()
**Is your feature request related to a problem? Please describe.**
Pathlib works most places in snakemake, which is great. However, in calls to expand(), pathlib paths must be converted to `str`, otherwise the following error occurs:

```sh
TypeError in line 29 of /Users/.../Snakefile:
'PosixPath' object is not iterable
  File "/Users/.../Snakefile", line 29, in <module>
```

**Describe the solution you'd like**
Update the `expand()` function to check whether the first argument is a `Path` object, and convert it to a string if so.


tests/test_io.py::test_expand
tests/test_io.py::test_wildcard_regex