CI: skip copying own models to avoid duplicate SQLAlchemy table defs
All checks were successful
Build and Deploy / build-and-deploy (push) Successful in 1m52s
All checks were successful
Build and Deploy / build-and-deploy (push) Successful in 1m52s
Each app has its own models/ at the root (imported as bare `models.X`).
The CI copy was also creating {app}/models/ (imported as `{app}.models.X`),
causing SQLAlchemy to see the same table defined twice.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -39,8 +39,9 @@ jobs:
|
||||
git fetch origin ${{ github.ref_name }}
|
||||
git reset --hard origin/${{ github.ref_name }}
|
||||
git submodule update --init --recursive
|
||||
# Copy sibling app models for cross-domain imports (read from git objects to avoid race conditions)
|
||||
# Copy sibling app models for cross-domain imports (skip self to avoid duplicate table defs)
|
||||
for sibling in blog market cart events; do
|
||||
[ \"\$sibling\" = \"${{ env.IMAGE }}\" ] && continue
|
||||
rm -rf \$sibling/__init__.py \$sibling/models
|
||||
repo=/root/rose-ash/\$sibling
|
||||
if [ -d \$repo/.git ]; then
|
||||
|
||||
Reference in New Issue
Block a user