@@ -261,7 +261,7 @@ def getClassNames(self, className=None, recursive=False, qualified=False, sort=F
261261# conditions. This is also the reason for OMPathABC, a simple base class to be used in ModelicaSystem* classes.
262262# Reason: before Python 3.12, pathlib.PurePosixPath can not be derived from; therefore, OMPathABC is not possible
263263if sys .version_info < (3 , 12 ):
264- class _OMPathCompatibility (pathlib .Path ):
264+ class OMPathCompatibility (pathlib .Path ):
265265 """
266266 Compatibility class for OMPathABC in Python < 3.12. This allows to run all code which uses OMPathABC (mainly
267267 ModelicaSystem) on these Python versions. There are remaining limitation as only local execution is possible.
@@ -272,8 +272,8 @@ def __new__(cls, *args, **kwargs):
272272 logger .warning ("Python < 3.12 - using a version of class OMCPath "
273273 "based on pathlib.Path for local usage only." )
274274
275- if cls is _OMPathCompatibility :
276- cls = _OMPathCompatibilityWindows if os .name == 'nt' else _OMPathCompatibilityPosix
275+ if cls is OMPathCompatibility :
276+ cls = OMPathCompatibilityWindows if os .name == 'nt' else OMPathCompatibilityPosix
277277 self = cls ._from_parts (args )
278278 if not self ._flavour .is_supported :
279279 raise NotImplementedError (f"cannot instantiate { cls .__name__ } on your system" )
@@ -285,21 +285,22 @@ def size(self) -> int:
285285 """
286286 return self .stat ().st_size
287287
288- class _OMPathCompatibilityPosix (pathlib .PosixPath , _OMPathCompatibility ):
288+ class OMPathCompatibilityPosix (pathlib .PosixPath , OMPathCompatibility ):
289289 """
290290 Compatibility class for OMCPath on Posix systems (Python < 3.12)
291291 """
292292
293- class _OMPathCompatibilityWindows (pathlib .WindowsPath , _OMPathCompatibility ):
293+ class OMPathCompatibilityWindows (pathlib .WindowsPath , OMPathCompatibility ):
294294 """
295295 Compatibility class for OMCPath on Windows systems (Python < 3.12)
296296 """
297297
298- OMPathABC = _OMPathCompatibility
299- OMCPath = _OMPathCompatibility
300- OMPathRunnerABC = _OMPathCompatibility
301- OMPathRunnerLocal = _OMPathCompatibility
302- OMPathRunnerBash = _OMPathCompatibility
298+ OMPathABC = OMPathCompatibility
299+ OMCPath = OMPathCompatibility
300+ OMPathRunnerABC = OMPathCompatibility
301+ OMPathRunnerLocal = OMPathCompatibility
302+ OMPathRunnerBash = OMPathCompatibility
303+
303304else :
304305 class OMPathABC (pathlib .PurePosixPath , metaclass = abc .ABCMeta ):
305306 """
0 commit comments