@shepai/cli 1.139.0-pr446.9a4d670 → 1.139.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/packages/core/src/infrastructure/services/deployment/deployment.service.d.ts.map +1 -1
- package/dist/packages/core/src/infrastructure/services/deployment/deployment.service.js +20 -41
- package/dist/src/presentation/web/app/actions/deploy-feature.d.ts.map +1 -1
- package/dist/src/presentation/web/app/actions/deploy-feature.js +0 -8
- package/dist/src/presentation/web/app/actions/deploy-repository.d.ts.map +1 -1
- package/dist/src/presentation/web/app/actions/deploy-repository.js +0 -8
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/web/.next/BUILD_ID +1 -1
- package/web/.next/build-manifest.json +2 -2
- package/web/.next/fallback-build-manifest.json +2 -2
- package/web/.next/prerender-manifest.json +3 -3
- package/web/.next/required-server-files.js +3 -3
- package/web/.next/required-server-files.json +3 -3
- package/web/.next/server/app/(dashboard)/@drawer/adopt/page/server-reference-manifest.json +28 -28
- package/web/.next/server/app/(dashboard)/@drawer/adopt/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/adopt/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/create/page/server-reference-manifest.json +28 -28
- package/web/.next/server/app/(dashboard)/@drawer/create/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/create/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page/server-reference-manifest.json +36 -36
- package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page.js +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page/server-reference-manifest.json +36 -36
- package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page.js +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page/server-reference-manifest.json +26 -26
- package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/create/page/server-reference-manifest.json +28 -28
- package/web/.next/server/app/(dashboard)/create/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/create/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page/server-reference-manifest.json +36 -36
- package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page.js +1 -1
- package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/feature/[featureId]/page/server-reference-manifest.json +36 -36
- package/web/.next/server/app/(dashboard)/feature/[featureId]/page.js +1 -1
- package/web/.next/server/app/(dashboard)/feature/[featureId]/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/feature/[featureId]/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/page/server-reference-manifest.json +26 -26
- package/web/.next/server/app/(dashboard)/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page/server-reference-manifest.json +26 -26
- package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/_global-error.html +2 -2
- package/web/.next/server/app/_global-error.rsc +1 -1
- package/web/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
- package/web/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/web/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
- package/web/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
- package/web/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/web/.next/server/app/_not-found/page/server-reference-manifest.json +3 -3
- package/web/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/api/attachments/preview/route.js.nft.json +1 -1
- package/web/.next/server/app/api/evidence/route.js.nft.json +1 -1
- package/web/.next/server/app/api/graph-data/route.js.nft.json +1 -1
- package/web/.next/server/app/settings/page/server-reference-manifest.json +8 -8
- package/web/.next/server/app/settings/page.js.nft.json +1 -1
- package/web/.next/server/app/settings/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/skills/page/server-reference-manifest.json +8 -8
- package/web/.next/server/app/skills/page.js.nft.json +1 -1
- package/web/.next/server/app/skills/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/tools/page/server-reference-manifest.json +8 -8
- package/web/.next/server/app/tools/page.js.nft.json +1 -1
- package/web/.next/server/app/tools/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/version/page/server-reference-manifest.json +3 -3
- package/web/.next/server/app/version/page_client-reference-manifest.js +1 -1
- package/web/.next/server/chunks/[root-of-the-server]__a402b567._.js +1 -1
- package/web/.next/server/chunks/ssr/744ca_web_components_common_control-center-drawer_create-drawer-client_tsx_5e26fc0a._.js +1 -1
- package/web/.next/server/chunks/ssr/744ca_web_components_common_control-center-drawer_create-drawer-client_tsx_5e26fc0a._.js.map +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__2c703b78._.js +4 -0
- package/web/.next/server/chunks/ssr/[root-of-the-server]__2c703b78._.js.map +1 -0
- package/web/.next/server/chunks/ssr/[root-of-the-server]__357d99f9._.js +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__3ef34e4c._.js +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__43f51aa6._.js +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__43f51aa6._.js.map +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__59a3897b._.js +4 -0
- package/web/.next/server/chunks/ssr/[root-of-the-server]__59a3897b._.js.map +1 -0
- package/web/.next/server/chunks/ssr/[root-of-the-server]__78aecdd5._.js +4 -0
- package/web/.next/server/chunks/ssr/[root-of-the-server]__78aecdd5._.js.map +1 -0
- package/web/.next/server/chunks/ssr/[root-of-the-server]__815546bd._.js +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__815546bd._.js.map +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__a5f9c6e5._.js +2 -2
- package/web/.next/server/chunks/ssr/[root-of-the-server]__a5f9c6e5._.js.map +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__aad040c0._.js +2 -2
- package/web/.next/server/chunks/ssr/[root-of-the-server]__aad040c0._.js.map +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__d48c5b11._.js +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__d48c5b11._.js.map +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__f222995d._.js +4 -0
- package/web/.next/server/chunks/ssr/[root-of-the-server]__f222995d._.js.map +1 -0
- package/web/.next/server/chunks/ssr/_02ec1aea._.js +1 -1
- package/web/.next/server/chunks/ssr/_02ec1aea._.js.map +1 -1
- package/web/.next/server/chunks/ssr/_0c5f56e3._.js +2 -2
- package/web/.next/server/chunks/ssr/_0c5f56e3._.js.map +1 -1
- package/web/.next/server/chunks/ssr/_1b719e7f._.js +1 -1
- package/web/.next/server/chunks/ssr/_1b719e7f._.js.map +1 -1
- package/web/.next/server/chunks/ssr/_37e8548b._.js +1 -1
- package/web/.next/server/chunks/ssr/_37e8548b._.js.map +1 -1
- package/web/.next/server/chunks/ssr/_55d763e2._.js +1 -1
- package/web/.next/server/chunks/ssr/_55d763e2._.js.map +1 -1
- package/web/.next/server/chunks/ssr/_64bdfc6f._.js +2 -2
- package/web/.next/server/chunks/ssr/_64bdfc6f._.js.map +1 -1
- package/web/.next/server/chunks/ssr/_7dca1882._.js +1 -1
- package/web/.next/server/chunks/ssr/_7dca1882._.js.map +1 -1
- package/web/.next/server/chunks/ssr/{_362a65ec._.js → _a3a344a8._.js} +2 -2
- package/web/.next/server/chunks/ssr/{_362a65ec._.js.map → _a3a344a8._.js.map} +1 -1
- package/web/.next/server/chunks/ssr/_a9f57758._.js +1 -1
- package/web/.next/server/chunks/ssr/_b71645b4._.js +1 -1
- package/web/.next/server/chunks/ssr/_b71645b4._.js.map +1 -1
- package/web/.next/server/chunks/ssr/_d8575088._.js +1 -1
- package/web/.next/server/chunks/ssr/_d8575088._.js.map +1 -1
- package/web/.next/server/chunks/ssr/{_92a1e417._.js → _ebd0ef7f._.js} +2 -2
- package/web/.next/server/chunks/ssr/{_92a1e417._.js.map → _ebd0ef7f._.js.map} +1 -1
- package/web/.next/server/chunks/ssr/_f39a1adb._.js +1 -1
- package/web/.next/server/chunks/ssr/_f39a1adb._.js.map +1 -1
- package/web/.next/server/chunks/ssr/b1a17_presentation_web_components_features_settings_settings-page-client_tsx_6ed9d5f8._.js +1 -1
- package/web/.next/server/chunks/ssr/b1a17_presentation_web_components_features_settings_settings-page-client_tsx_6ed9d5f8._.js.map +1 -1
- package/web/.next/server/chunks/ssr/{src_presentation_web_8832f8a0._.js → src_presentation_web_582e5037._.js} +2 -2
- package/web/.next/server/chunks/ssr/{src_presentation_web_8832f8a0._.js.map → src_presentation_web_582e5037._.js.map} +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app_skills_page_actions_1b176e3c.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app_skills_page_actions_1b176e3c.js.map +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app_tools_page_actions_bd9f0dda.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app_tools_page_actions_bd9f0dda.js.map +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_app_actions_open-ide_ts_baaca5d5._.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_components_e599bb8c._.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_components_e599bb8c._.js.map +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_components_features_control-center_7ac3562e._.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_components_features_control-center_7ac3562e._.js.map +1 -1
- package/web/.next/server/pages/500.html +2 -2
- package/web/.next/server/server-reference-manifest.js +1 -1
- package/web/.next/server/server-reference-manifest.json +44 -44
- package/web/.next/static/chunks/{55a21a7f828091b4.js → 13451dd1c5eb854a.js} +1 -1
- package/web/.next/static/chunks/{a083cbc927bb8708.js → 1a46d832fb5dbb4d.js} +1 -1
- package/web/.next/static/chunks/{5241d86d18aea5a8.js → 26f8c1dc8e8d3a85.js} +1 -1
- package/web/.next/static/chunks/284bdcf374b23190.js +1 -0
- package/web/.next/static/chunks/2a318598dee02204.js +1 -0
- package/web/.next/static/chunks/4d521e80c86070db.js +1 -0
- package/web/.next/static/chunks/{310de4832855feb0.js → 5aac1b0e10edc3d4.js} +1 -1
- package/web/.next/static/chunks/{656b8c7be54a9a62.js → 7d4461c2f06d2cb9.js} +1 -1
- package/web/.next/static/chunks/{e47d4364e6de6a3c.js → 9d59552a1eb58b20.js} +1 -1
- package/web/.next/static/chunks/{784d4bcaebc16e66.js → add583b93a6e62ef.js} +1 -1
- package/web/.next/static/chunks/c4c3d56eac00b6a3.js +2 -0
- package/web/.next/static/chunks/{2bc95df962e4ccb4.js → d14b401b9ac6b439.js} +1 -1
- package/dist/src/presentation/web/lib/is-same-shep-instance.d.ts +0 -7
- package/dist/src/presentation/web/lib/is-same-shep-instance.d.ts.map +0 -1
- package/dist/src/presentation/web/lib/is-same-shep-instance.js +0 -18
- package/web/.next/server/chunks/ssr/[root-of-the-server]__2bdf88a0._.js +0 -4
- package/web/.next/server/chunks/ssr/[root-of-the-server]__2bdf88a0._.js.map +0 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__42faf5ae._.js +0 -4
- package/web/.next/server/chunks/ssr/[root-of-the-server]__42faf5ae._.js.map +0 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__685ee565._.js +0 -4
- package/web/.next/server/chunks/ssr/[root-of-the-server]__685ee565._.js.map +0 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__74756aae._.js +0 -4
- package/web/.next/server/chunks/ssr/[root-of-the-server]__74756aae._.js.map +0 -1
- package/web/.next/static/chunks/1e4101146fba345a.js +0 -1
- package/web/.next/static/chunks/7cddbd2eef52fb7d.js +0 -2
- package/web/.next/static/chunks/c4289472b20b5ca3.js +0 -1
- package/web/.next/static/chunks/dec195dca4c1ddc1.js +0 -1
- /package/web/.next/static/{mySbQkxwHdK9HUj3SJDSq → dDoTmkPtcr9knH6GiOhGo}/_buildManifest.js +0 -0
- /package/web/.next/static/{mySbQkxwHdK9HUj3SJDSq → dDoTmkPtcr9knH6GiOhGo}/_clientMiddlewareManifest.json +0 -0
- /package/web/.next/static/{mySbQkxwHdK9HUj3SJDSq → dDoTmkPtcr9knH6GiOhGo}/_ssgManifest.js +0 -0
package/dist/packages/core/src/infrastructure/services/deployment/deployment.service.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deployment.service.d.ts","sourceRoot":"","sources":["../../../../../../../packages/core/src/infrastructure/services/deployment/deployment.service.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,KAAK,EAAmC,MAAM,oBAAoB,CAAC;AAK5E,OAAO,KAAK,QAAQ,MAAM,gBAAgB,CAAC;AAK3C,OAAO,KAAK,EACV,kBAAkB,EAClB,gBAAgB,EAChB,QAAQ,EACT,MAAM,qEAAqE,CAAC;AAC7E,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAiCzD,MAAM,WAAW,qBAAqB;IACpC,KAAK,EAAE,OAAO,KAAK,CAAC;IACpB,eAAe,EAAE,OAAO,eAAe,CAAC;IACxC,IAAI,EAAE,CAAC,GAAG,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,OAAO,GAAG,MAAM,KAAK,IAAI,CAAC;IAC7D,OAAO,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,OAAO,CAAC;CACnC;AA0CD,qBAAa,iBAAkB,YAAW,kBAAkB;IAC1D,OAAO,CAAC,QAAQ,CAAC,WAAW,CAAsC;IAClE,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAwB;IAC7C,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAsB;IAC9C,OAAO,CAAC,EAAE,CAAkC;gBAEhC,IAAI,GAAE,OAAO,CAAC,qBAAqB,CAAM;IAIrD;;OAEG;IACH,WAAW,CAAC,EAAE,EAAE,QAAQ,CAAC,QAAQ,GAAG,IAAI;IAIxC;;;;;;;;;;;;OAYG;IACH,UAAU,IAAI,IAAI;
|
|
1
|
+
{"version":3,"file":"deployment.service.d.ts","sourceRoot":"","sources":["../../../../../../../packages/core/src/infrastructure/services/deployment/deployment.service.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,KAAK,EAAmC,MAAM,oBAAoB,CAAC;AAK5E,OAAO,KAAK,QAAQ,MAAM,gBAAgB,CAAC;AAK3C,OAAO,KAAK,EACV,kBAAkB,EAClB,gBAAgB,EAChB,QAAQ,EACT,MAAM,qEAAqE,CAAC;AAC7E,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAiCzD,MAAM,WAAW,qBAAqB;IACpC,KAAK,EAAE,OAAO,KAAK,CAAC;IACpB,eAAe,EAAE,OAAO,eAAe,CAAC;IACxC,IAAI,EAAE,CAAC,GAAG,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,OAAO,GAAG,MAAM,KAAK,IAAI,CAAC;IAC7D,OAAO,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,OAAO,CAAC;CACnC;AA0CD,qBAAa,iBAAkB,YAAW,kBAAkB;IAC1D,OAAO,CAAC,QAAQ,CAAC,WAAW,CAAsC;IAClE,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAwB;IAC7C,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAsB;IAC9C,OAAO,CAAC,EAAE,CAAkC;gBAEhC,IAAI,GAAE,OAAO,CAAC,qBAAqB,CAAM;IAIrD;;OAEG;IACH,WAAW,CAAC,EAAE,EAAE,QAAQ,CAAC,QAAQ,GAAG,IAAI;IAIxC;;;;;;;;;;;;OAYG;IACH,UAAU,IAAI,IAAI;IAgFlB;;;OAGG;IACH,KAAK,CAAC,QAAQ,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE,UAAU,SAAe,GAAG,IAAI;IA0G5E;;;;OAIG;IACH,SAAS,CAAC,QAAQ,EAAE,MAAM,GAAG,gBAAgB,GAAG,IAAI;IA4CpD;;OAEG;IACG,IAAI,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IA0D3C;;OAEG;IACH,OAAO,IAAI,IAAI;IAef;;OAEG;IACH,OAAO,CAAC,QAAQ,EAAE,MAAM,GAAG,QAAQ,EAAE,GAAG,IAAI;IAM5C;;OAEG;IACH,EAAE,CAAC,KAAK,EAAE,KAAK,EAAE,OAAO,EAAE,CAAC,KAAK,EAAE,QAAQ,KAAK,IAAI,GAAG,IAAI;IAI1D;;OAEG;IACH,GAAG,CAAC,KAAK,EAAE,KAAK,EAAE,OAAO,EAAE,CAAC,KAAK,EAAE,QAAQ,KAAK,IAAI,GAAG,IAAI;IAM3D,OAAO,CAAC,QAAQ;IAuBhB,OAAO,CAAC,aAAa;IAWrB,OAAO,CAAC,QAAQ;IAShB,OAAO,CAAC,MAAM;IAed,OAAO,CAAC,WAAW;IAQnB;;;OAGG;IACH,OAAO,CAAC,oBAAoB;YA4Dd,aAAa;IAW3B,OAAO,CAAC,WAAW;IAUnB;;;;OAIG;YACW,kBAAkB;IAsChC;;;OAGG;IACH,OAAO,CAAC,SAAS;CAwBlB"}
|
|
@@ -99,12 +99,6 @@ export class DeploymentService {
|
|
|
99
99
|
recoverAll() {
|
|
100
100
|
if (!this.db)
|
|
101
101
|
return;
|
|
102
|
-
// Child dev servers spawned by DeploymentService share the same global DB.
|
|
103
|
-
// Skip recovery to avoid killing processes owned by the parent instance.
|
|
104
|
-
if (process.env.SHEP_SKIP_RECOVERY) {
|
|
105
|
-
log.info('SHEP_SKIP_RECOVERY set — skipping dev server recovery');
|
|
106
|
-
return;
|
|
107
|
-
}
|
|
108
102
|
let rows;
|
|
109
103
|
try {
|
|
110
104
|
const stmt = this.db.prepare('SELECT * FROM dev_servers');
|
|
@@ -143,16 +137,20 @@ export class DeploymentService {
|
|
|
143
137
|
continue;
|
|
144
138
|
}
|
|
145
139
|
if (alive) {
|
|
146
|
-
// Strategy 2: Process alive but stuck in Booting —
|
|
147
|
-
//
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
140
|
+
// Strategy 2: Process alive but stuck in Booting — can't re-attach stdout
|
|
141
|
+
// Kill the orphan so we can re-spawn with proper listeners
|
|
142
|
+
log.info(`Orphan "${row.target_id}" (pid=${row.pid}) stuck in ${row.state} — killing to re-spawn`);
|
|
143
|
+
try {
|
|
144
|
+
this.deps.kill(row.pid, 'SIGKILL');
|
|
145
|
+
}
|
|
146
|
+
catch {
|
|
147
|
+
// already dead
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
else {
|
|
151
|
+
log.info(`Dev server "${row.target_id}" (pid=${row.pid}) is dead — will re-spawn`);
|
|
153
152
|
}
|
|
154
|
-
// Strategy 3:
|
|
155
|
-
log.info(`Dev server "${row.target_id}" (pid=${row.pid}) is dead — will re-spawn`);
|
|
153
|
+
// Strategy 2 & 3: Re-spawn if target directory still has a package.json
|
|
156
154
|
this.dbDelete(row.target_id);
|
|
157
155
|
if (!existsSync(join(row.target_path, 'package.json'))) {
|
|
158
156
|
log.warn(`Skipping re-spawn for "${row.target_id}" — no package.json at "${row.target_path}"`);
|
|
@@ -217,9 +215,6 @@ export class DeploymentService {
|
|
|
217
215
|
// stdout/stderr — we don't need it because taskkill /F /T handles tree kill.
|
|
218
216
|
...(IS_WINDOWS ? { windowsHide: true } : { detached: true }),
|
|
219
217
|
stdio: ['ignore', 'pipe', 'pipe'],
|
|
220
|
-
// Prevent child shep instances (e.g. worktree dev servers) from running
|
|
221
|
-
// recoverAll() on the shared ~/.shep/data DB and killing our processes.
|
|
222
|
-
env: { ...process.env, SHEP_SKIP_RECOVERY: '1' },
|
|
223
218
|
});
|
|
224
219
|
if (!child.pid) {
|
|
225
220
|
log.error('spawn() returned no PID — process failed to start');
|
|
@@ -239,10 +234,7 @@ export class DeploymentService {
|
|
|
239
234
|
logs: new LogRingBuffer(),
|
|
240
235
|
};
|
|
241
236
|
this.deployments.set(targetId, entry);
|
|
242
|
-
|
|
243
|
-
// another shep instance sharing ~/.shep/data — its recoverAll() would
|
|
244
|
-
// find this Booting entry, see its own PID as alive, and SIGKILL itself.
|
|
245
|
-
// We persist to DB only when the state transitions to Ready (URL detected).
|
|
237
|
+
this.dbUpsert(entry);
|
|
246
238
|
// Attach stdout/stderr listeners for port detection
|
|
247
239
|
this.attachOutputListener(entry, 'stdout');
|
|
248
240
|
this.attachOutputListener(entry, 'stderr');
|
|
@@ -253,25 +245,12 @@ export class DeploymentService {
|
|
|
253
245
|
this.deployments.delete(targetId);
|
|
254
246
|
this.dbDelete(targetId);
|
|
255
247
|
});
|
|
256
|
-
//
|
|
257
|
-
|
|
258
|
-
child.on('close', (code, signal) => {
|
|
248
|
+
// Clean up on process exit
|
|
249
|
+
child.on('exit', (code, signal) => {
|
|
259
250
|
const wasBooting = entry.state === DeploymentState.Booting;
|
|
260
|
-
log.info(`Process
|
|
251
|
+
log.info(`Process exited for "${targetId}" (pid=${entry.pid}) — code=${code}, signal=${signal}, wasBooting=${wasBooting}`);
|
|
261
252
|
if (wasBooting) {
|
|
262
|
-
log.warn(
|
|
263
|
-
const allLogs = entry.logs.getAll();
|
|
264
|
-
const stdoutLines = allLogs.filter((l) => l.stream === 'stdout');
|
|
265
|
-
const stderrLines = allLogs.filter((l) => l.stream === 'stderr');
|
|
266
|
-
if (stdoutLines.length > 0) {
|
|
267
|
-
log.warn(`[${targetId}] stdout:\n${stdoutLines.map((l) => l.line).join('\n')}`);
|
|
268
|
-
}
|
|
269
|
-
if (stderrLines.length > 0) {
|
|
270
|
-
log.warn(`[${targetId}] stderr:\n${stderrLines.map((l) => l.line).join('\n')}`);
|
|
271
|
-
}
|
|
272
|
-
if (allLogs.length === 0) {
|
|
273
|
-
log.warn(`[${targetId}] No output captured from the process.`);
|
|
274
|
-
}
|
|
253
|
+
log.warn('Process exited while still in Booting state — dev server likely crashed on startup. Check stderr output above.');
|
|
275
254
|
}
|
|
276
255
|
this.deployments.delete(targetId);
|
|
277
256
|
this.dbDelete(targetId);
|
|
@@ -506,7 +485,7 @@ export class DeploymentService {
|
|
|
506
485
|
log.info(`[${entry.targetId}] Port detected — url="${url}" (from ${stream})`);
|
|
507
486
|
entry.state = DeploymentState.Ready;
|
|
508
487
|
entry.url = url;
|
|
509
|
-
this.
|
|
488
|
+
this.dbUpdateState(entry.targetId, entry.state, entry.url);
|
|
510
489
|
}
|
|
511
490
|
}
|
|
512
491
|
}
|
|
@@ -521,7 +500,7 @@ export class DeploymentService {
|
|
|
521
500
|
log.info(`[${entry.targetId}] Port detected in flushed buffer — url="${url}"`);
|
|
522
501
|
entry.state = DeploymentState.Ready;
|
|
523
502
|
entry.url = url;
|
|
524
|
-
this.
|
|
503
|
+
this.dbUpdateState(entry.targetId, entry.state, entry.url);
|
|
525
504
|
}
|
|
526
505
|
}
|
|
527
506
|
entry[bufferKey] = '';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deploy-feature.d.ts","sourceRoot":"","sources":["../../../../../../src/presentation/web/app/actions/deploy-feature.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,eAAe,EAAE,MAAM,sCAAsC,CAAC;
|
|
1
|
+
{"version":3,"file":"deploy-feature.d.ts","sourceRoot":"","sources":["../../../../../../src/presentation/web/app/actions/deploy-feature.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,eAAe,EAAE,MAAM,sCAAsC,CAAC;AAIvE,wBAAsB,aAAa,CACjC,SAAS,EAAE,MAAM,GAChB,OAAO,CAAC;IAAE,OAAO,EAAE,OAAO,CAAC;IAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IAAC,KAAK,CAAC,EAAE,eAAe,CAAA;CAAE,CAAC,CAwCxE"}
|
|
@@ -4,7 +4,6 @@ import { resolve } from '../../lib/server-container.js';
|
|
|
4
4
|
import { createDeploymentLogger } from '../../../../../packages/core/src/infrastructure/services/deployment/deployment-logger.js';
|
|
5
5
|
import { computeWorktreePath } from '../../../../../packages/core/src/infrastructure/services/ide-launchers/compute-worktree-path.js';
|
|
6
6
|
import { DeploymentState } from '../../../../../packages/core/src/domain/generated/output.js';
|
|
7
|
-
import { isSameShepInstance } from '../../lib/is-same-shep-instance.js';
|
|
8
7
|
const log = createDeploymentLogger('[deployFeature]');
|
|
9
8
|
export async function deployFeature(featureId) {
|
|
10
9
|
log.info(`called — featureId="${featureId}"`);
|
|
@@ -26,13 +25,6 @@ export async function deployFeature(featureId) {
|
|
|
26
25
|
log.warn(`worktree path does not exist on disk: "${worktreePath}"`);
|
|
27
26
|
return { success: false, error: `Worktree path does not exist: ${worktreePath}` };
|
|
28
27
|
}
|
|
29
|
-
if (isSameShepInstance(feature.repositoryPath)) {
|
|
30
|
-
log.warn('rejected — feature belongs to the running shep instance');
|
|
31
|
-
return {
|
|
32
|
-
success: false,
|
|
33
|
-
error: 'Cannot start a dev server for features of the repository Shep is running from',
|
|
34
|
-
};
|
|
35
|
-
}
|
|
36
28
|
log.info('worktree path exists, calling deploymentService.start()');
|
|
37
29
|
const deploymentService = resolve('IDeploymentService');
|
|
38
30
|
deploymentService.start(featureId, worktreePath, 'feature');
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deploy-repository.d.ts","sourceRoot":"","sources":["../../../../../../src/presentation/web/app/actions/deploy-repository.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,eAAe,EAAE,MAAM,sCAAsC,CAAC;
|
|
1
|
+
{"version":3,"file":"deploy-repository.d.ts","sourceRoot":"","sources":["../../../../../../src/presentation/web/app/actions/deploy-repository.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,eAAe,EAAE,MAAM,sCAAsC,CAAC;AAIvE,wBAAsB,gBAAgB,CACpC,cAAc,EAAE,MAAM,GACrB,OAAO,CAAC;IAAE,OAAO,EAAE,OAAO,CAAC;IAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IAAC,KAAK,CAAC,EAAE,eAAe,CAAA;CAAE,CAAC,CAyBxE"}
|
|
@@ -4,7 +4,6 @@ import { isAbsolute } from 'node:path';
|
|
|
4
4
|
import { resolve } from '../../lib/server-container.js';
|
|
5
5
|
import { createDeploymentLogger } from '../../../../../packages/core/src/infrastructure/services/deployment/deployment-logger.js';
|
|
6
6
|
import { DeploymentState } from '../../../../../packages/core/src/domain/generated/output.js';
|
|
7
|
-
import { isSameShepInstance } from '../../lib/is-same-shep-instance.js';
|
|
8
7
|
const log = createDeploymentLogger('[deployRepository]');
|
|
9
8
|
export async function deployRepository(repositoryPath) {
|
|
10
9
|
log.info(`called — repositoryPath="${repositoryPath}"`);
|
|
@@ -17,13 +16,6 @@ export async function deployRepository(repositoryPath) {
|
|
|
17
16
|
log.warn(`directory does not exist: "${repositoryPath}"`);
|
|
18
17
|
return { success: false, error: `Directory does not exist: ${repositoryPath}` };
|
|
19
18
|
}
|
|
20
|
-
if (isSameShepInstance(repositoryPath)) {
|
|
21
|
-
log.warn('rejected — target is the running shep instance');
|
|
22
|
-
return {
|
|
23
|
-
success: false,
|
|
24
|
-
error: 'Cannot start a dev server for the repository Shep is running from',
|
|
25
|
-
};
|
|
26
|
-
}
|
|
27
19
|
log.info('directory exists, calling deploymentService.start()');
|
|
28
20
|
const deploymentService = resolve('IDeploymentService');
|
|
29
21
|
deploymentService.start(repositoryPath, repositoryPath, 'repository');
|