diff --git a/package-lock.json b/package-lock.json index f15b487da..091d32ce7 100644 --- a/package-lock.json +++ b/package-lock.json @@ -2133,7 +2133,7 @@ "link": true }, "node_modules/@dbos-inc/dbos-sdk": { - "resolved": ".", + "resolved": "", "link": true }, "node_modules/@dbos-inc/dbos-sqs": { @@ -4173,6 +4173,7 @@ }, "node_modules/@types/accepts": { "version": "1.3.7", + "dev": true, "license": "MIT", "dependencies": { "@types/node": "*" @@ -4252,6 +4253,7 @@ }, "node_modules/@types/content-disposition": { "version": "0.5.8", + "dev": true, "license": "MIT" }, "node_modules/@types/cookiejar": { @@ -4261,6 +4263,7 @@ }, "node_modules/@types/cookies": { "version": "0.9.0", + "dev": true, "license": "MIT", "dependencies": { "@types/connect": "*", @@ -4309,6 +4312,7 @@ }, "node_modules/@types/http-assert": { "version": "1.5.5", + "dev": true, "license": "MIT" }, "node_modules/@types/http-cache-semantics": { @@ -4362,10 +4366,12 @@ }, "node_modules/@types/keygrip": { "version": "1.0.6", + "dev": true, "license": "MIT" }, "node_modules/@types/koa": { "version": "2.15.0", + "dev": true, "license": "MIT", "dependencies": { "@types/accepts": "*", @@ -4396,6 +4402,7 @@ }, "node_modules/@types/koa-compose": { "version": "3.2.8", + "dev": true, "license": "MIT", "dependencies": { "@types/koa": "*" @@ -6794,10 +6801,11 @@ } }, "node_modules/express": { - "version": "4.21.1", - "resolved": "https://registry.npmjs.org/express/-/express-4.21.1.tgz", - "integrity": "sha512-YSFlK1Ee0/GC8QaO91tHcDxJiE/X4FbpAyQWkxAvG6AXCuR65YzK8ua6D9hvi/TzUfZMpc+BwuM1IPw8fmQBiQ==", + "version": "4.21.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.21.2.tgz", + "integrity": "sha512-28HqgMZAmih1Czt9ny7qr6ek2qddF4FclbMzwhCREB6OFfH+rXAnuNCwo1/wFvrtbgsQDb4kSbX9de9lFbrXnA==", "dev": true, + "license": "MIT", "dependencies": { "accepts": "~1.3.8", "array-flatten": "1.1.1", @@ -6818,7 +6826,7 @@ "methods": "~1.1.2", "on-finished": "2.4.1", "parseurl": "~1.3.3", - "path-to-regexp": "0.1.10", + "path-to-regexp": "0.1.12", "proxy-addr": "~2.0.7", "qs": "6.13.0", "range-parser": "~1.2.1", @@ -6833,6 +6841,10 @@ }, "engines": { "node": ">= 0.10.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" } }, "node_modules/express/node_modules/cookie": { @@ -6869,10 +6881,11 @@ "dev": true }, "node_modules/express/node_modules/path-to-regexp": { - "version": "0.1.10", - "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.10.tgz", - "integrity": "sha512-7lf7qcQidTku0Gu3YDPc8DJ1q7OOucfa/BSsIwjuh56VU7katFvuM8hULfkwB3Fns/rsVF7PwPKVw1sl5KQS9w==", - "dev": true + "version": "0.1.12", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.12.tgz", + "integrity": "sha512-RA1GjUVMnvYFxuqovrEqZoxxW5NUZqbwKtYz/Tt7nXerk0LbLblQmrsgdeOxV5SFHf0UDggjS/bSeOZwt1pmEQ==", + "dev": true, + "license": "MIT" }, "node_modules/external-editor": { "version": "3.1.0", @@ -9405,7 +9418,9 @@ } }, "node_modules/nanoid": { - "version": "3.3.7", + "version": "3.3.8", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.8.tgz", + "integrity": "sha512-WNLf5Sd8oZxOm+TzppcYk8gVOgP+l58xNy58D0nbUnOxOWRWvlcCV4kUF7ltmI6PsrLl/BgKEyS4mqsGChFN0w==", "dev": true, "funding": [ { diff --git a/packages/dbos-cloud/applications/deploy-app-code.ts b/packages/dbos-cloud/applications/deploy-app-code.ts index 5ad0bb487..177a419ad 100644 --- a/packages/dbos-cloud/applications/deploy-app-code.ts +++ b/packages/dbos-cloud/applications/deploy-app-code.ts @@ -135,13 +135,21 @@ export async function deployAppCode( } } else if (appLanguage === AppLanguages.Python as string) { logger.debug("Checking for requirements.txt..."); - const requirementsTxtExists = existsSync(path.join(process.cwd(), "requirements.txt")); + const requirementsPath = path.join(process.cwd(), "requirements.txt") + const requirementsTxtExists = existsSync(requirementsPath); logger.debug(` ... requirements.txt found: ${requirementsTxtExists}`); if (!requirementsTxtExists) { logger.error("No requirements.txt found. Please create one before deploying."); return 1; } + + const content = fs.readFileSync(requirementsPath, 'utf8'); + if (!content.includes("dbos")) { + logger.error("Your requirements.txt does not include 'dbos'. Please make sure you include all your dependencies."); + return 1; + } + } else { logger.error(`dbos-config.yaml contains invalid language ${appLanguage}`) return 1;