Skip to content

Commit ad9309b

Browse files
committed
os: Import path automatically if available.
This matches CPython behavior: ``` >>> import os >>> os.path.sep '/' ``` Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
1 parent f1039fd commit ad9309b

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

python-stdlib/os/os/__init__.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,8 @@
11
# Replace built-in os module.
22
from uos import *
3+
4+
# Provide optional dependencies (which may be installed separately).
5+
try:
6+
from . import path
7+
except ImportError:
8+
pass

0 commit comments

Comments
 (0)