Skip to content

Commit 7545f98

Browse files
Fix add to sys path after cloning (#2849)
Fix #2808 (comment) If the notebook is launched after the OpenVoice repository has already been cloned, the repository path might not be added to the system path. The clone_repo function can handle this, so we only need to ensure that openvoice/text/english.py is properly fixed.
1 parent ae3507d commit 7545f98

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

notebooks/openvoice/openvoice.ipynb

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -109,8 +109,11 @@
109109
"\n",
110110
"repo_dir = Path(\"OpenVoice\")\n",
111111
"\n",
112-
"if not repo_dir.exists():\n",
113-
" clone_repo(\"https://github.com/myshell-ai/OpenVoice\")\n",
112+
"clone_repo(\"https://github.com/myshell-ai/OpenVoice\")\n",
113+
"orig_english_path = Path(\"OpenVoice/openvoice/text/_orig_english.py\")\n",
114+
"english_path = Path(\"OpenVoice/openvoice/text/english.py\")\n",
115+
"\n",
116+
"if not orig_english_path.exists():\n",
114117
" orig_english_path = Path(\"OpenVoice/openvoice/text/_orig_english.py\")\n",
115118
" english_path = Path(\"OpenVoice/openvoice/text/english.py\")\n",
116119
"\n",

0 commit comments

Comments
 (0)