Skip to content

Commit 58c0086

Browse files
committed
Drop sys.path shim from notebook
Notebook now relies on a properly-configured environment (`pip install -e .` from this worktree) rather than a worktree-detection shim in cell 1. Signed-off-by: Pascal Tomecek <pascal.tomecek@cubistsystematic.com>
1 parent 83daf93 commit 58c0086

2 files changed

Lines changed: 136 additions & 149 deletions

File tree

build_notebook.py

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -115,16 +115,6 @@ def query(lineitem):
115115
""")
116116

117117
code(r"""
118-
import sys
119-
from pathlib import Path
120-
121-
# Ensure this worktree's ccflow takes precedence over any editable install.
122-
_WORKTREE = Path.cwd()
123-
while _WORKTREE != _WORKTREE.parent and not (_WORKTREE / "ccflow" / "models" / "narwhals.py").exists():
124-
_WORKTREE = _WORKTREE.parent
125-
if str(_WORKTREE) not in sys.path:
126-
sys.path.insert(0, str(_WORKTREE))
127-
128118
import warnings
129119
130120
warnings.filterwarnings("ignore", category=DeprecationWarning)

0 commit comments

Comments
 (0)