File tree Expand file tree Collapse file tree 2 files changed +4
-6
lines changed
Expand file tree Collapse file tree 2 files changed +4
-6
lines changed Original file line number Diff line number Diff line change 113113 "onCreateCommand" : [
114114 " bash" ,
115115 " -c" ,
116- " echo '🚀 Creating Python virtual environment in workspace...' && /usr/local/bin/python3.12 -m venv /workspaces/Apim-Samples/.venv --copies && source /workspaces/Apim-Samples/.venv/bin/activate && pip install --upgrade pip setuptools wheel && echo '✅ Virtual environment created'"
116+ " echo '🚀 Creating Python virtual environment in workspace...' && /usr/local/bin/python3.12 -m venv /workspaces/Apim-Samples/.venv --copies && source /workspaces/Apim-Samples/.venv/bin/activate && pip install --upgrade pip setuptools wheel ipykernel && echo '✅ Virtual environment created' && echo '🔧 Registering Jupyter kernel during prebuild...' && python -m ipykernel install --user --name=apim-samples --display-name='APIM Samples Python 3.12' --python= \" $(which python) \" && echo '🧹 Removing default python3 kernel...' && rm -rf /workspaces/Apim-Samples/.venv/share/jupyter/kernels/python3 2>/dev/null || true && echo '✅ Jupyter kernel registered in prebuild '"
117117 ],
118118 "updateContentCommand" : [
119119 " bash" ,
120120 " -c" ,
121- " echo '📦 Installing/updating Python packages from requirements.txt...' && source /workspaces/Apim-Samples/.venv/bin/activate && pip install -r requirements.txt && pip install pytest pytest-cov coverage ipykernel && echo '✅ Python packages installed/updated' && python setup/setup_python_path.py --generate-env && echo '✅ Environment configuration updated' && echo '🔧 Registering Jupyter kernel...' && python -m ipykernel install --user --name=apim-samples --display-name='APIM Samples Python 3.12' --python= \" $(which python) \" && echo '✅ Jupyter kernel registered ' && echo '⚙️ Configuring Azure CLI...' && az config set core.login_experience_v2=off 2>/dev/null || true && az extension add --name containerapp --only-show-errors 2>/dev/null || true && az extension add --name front-door --only-show-errors 2>/dev/null || true && echo '✅ Azure CLI configured for Codespaces'"
121+ " echo '📦 Installing/updating Python packages from requirements.txt...' && source /workspaces/Apim-Samples/.venv/bin/activate && pip install -r requirements.txt && pip install pytest pytest-cov coverage && echo '✅ Python packages installed/updated' && python setup/setup_python_path.py --generate-env && echo '✅ Environment configuration updated' && echo '⚙️ Configuring Azure CLI...' && az config set core.login_experience_v2=off 2>/dev/null || true && az extension add --name containerapp --only-show-errors 2>/dev/null || true && az extension add --name front-door --only-show-errors 2>/dev/null || true && echo '✅ Azure CLI configured for Codespaces'"
122122 ],
123123 "postStartCommand" : [
124124 " bash" ,
Original file line number Diff line number Diff line change 5252
5353# Quick Jupyter kernel check
5454if jupyter kernelspec list 2> /dev/null | grep -q " apim-samples" ; then
55- echo " ✅ Jupyter kernel"
55+ echo " ✅ Jupyter kernel (prebuild) "
5656else
57- echo " ⚠️ Jupyter kernel missing (fallback registration...)"
58- python -m ipykernel install --user --name=apim-samples --display-name=" APIM Samples Python 3.12" > /dev/null 2>&1
59- echo " ✅ Jupyter kernel registered"
57+ echo " ⚠️ Jupyter kernel missing - check prebuild logs"
6058fi
6159
6260# Calculate total duration
You can’t perform that action at this time.
0 commit comments