File tree Expand file tree Collapse file tree 4 files changed +19
-4
lines changed Expand file tree Collapse file tree 4 files changed +19
-4
lines changed Original file line number Diff line number Diff line change @@ -20,6 +20,8 @@ The released versions correspond to PyPI releases.
2020### Fixes
2121* fixes a problem with `Path` type hints using the pipe symbol in wrapped functions
2222 inside an `fs` dependent fixture (see [#1242](../../issues/1242))
23+ * fixes problem with new `coverage` in Python 3.14 using the fake filesystem
24+ (see [#1245](../../issues/1245))
2325
2426## [Version 5.10.2](https://pypi.python.org/pypi/pyfakefs/5.10.2) (2025-11-04)
2527Fixes a problem with `pathlib.glob` in Python 3.14.
Original file line number Diff line number Diff line change @@ -1012,7 +1012,12 @@ def _refresh(self) -> None:
10121012 for name in self ._fake_module_classes :
10131013 self .fake_modules [name ] = self ._fake_module_classes [name ](self .fs )
10141014 if hasattr (self .fake_modules [name ], "skip_names" ):
1015- self .fake_modules [name ].skip_names = self .skip_names
1015+ self .fake_modules [name ].skip_names = self .skip_names | {
1016+ # also skip non-build-in skipped modules
1017+ m .__name__
1018+ for m in self .SKIPMODULES
1019+ if m and "." in m .__name__
1020+ }
10161021 self .fake_modules [PATH_MODULE ] = self .fake_modules ["os" ].path
10171022 for name in self ._unfaked_module_classes :
10181023 self .unfaked_modules [name ] = self ._unfaked_module_classes [name ]()
Original file line number Diff line number Diff line change @@ -19,14 +19,21 @@ def my_fakefs_test(fs):
1919
2020try :
2121 from _pytest import pathlib
22+
23+ Patcher .SKIPMODULES .add (pathlib )
2224except ImportError :
23- pathlib = None # type:ignore[assignment]
25+ pass
26+
27+ try :
28+ from coverage import python # type:ignore[import]
29+
30+ Patcher .SKIPMODULES .add (python )
31+ except ImportError :
32+ pass
2433
2534Patcher .SKIPMODULES .add (py )
2635Patcher .SKIPMODULES .add (pytest )
2736Patcher .SKIPMODULES .add (capture )
28- if pathlib is not None :
29- Patcher .SKIPMODULES .add (pathlib )
3037
3138
3239@pytest .fixture
Original file line number Diff line number Diff line change @@ -73,6 +73,7 @@ xdist = [
7373
7474[tool .setuptools ]
7575include-package-data = true
76+ py-modules = [" pyfakefs" ]
7677
7778[tool .setuptools .package-data ]
7879where = [" pyfakefs" ]
You can’t perform that action at this time.
0 commit comments