@vercel/python 6.4.1 → 6.4.2

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.
Files changed (2) hide show
  1. package/dist/index.js +12 -5
  2. package/package.json +3 -3
package/dist/index.js CHANGED
@@ -3501,9 +3501,11 @@ async function detectInstallSource({
3501
3501
  async function createPyprojectToml({
3502
3502
  projectName,
3503
3503
  pyprojectPath,
3504
- dependencies
3504
+ dependencies,
3505
+ pythonVersion
3505
3506
  }) {
3506
- const requiresPython = `~=${DEFAULT_PYTHON_VERSION}.0`;
3507
+ const version2 = pythonVersion ?? DEFAULT_PYTHON_VERSION;
3508
+ const requiresPython = `~=${version2}.0`;
3507
3509
  const depsToml = dependencies.length > 0 ? [
3508
3510
  "dependencies = [",
3509
3511
  ...dependencies.map((dep) => ` "${dep}",`),
@@ -3562,6 +3564,7 @@ async function ensureUvProject({
3562
3564
  repoRootPath,
3563
3565
  pythonPath,
3564
3566
  pipPath,
3567
+ pythonVersion,
3565
3568
  uv,
3566
3569
  venvPath,
3567
3570
  meta,
@@ -3625,7 +3628,8 @@ async function ensureUvProject({
3625
3628
  await createPyprojectToml({
3626
3629
  projectName: "app",
3627
3630
  pyprojectPath,
3628
- dependencies: []
3631
+ dependencies: [],
3632
+ pythonVersion
3629
3633
  });
3630
3634
  }
3631
3635
  await uv.addFromFile({
@@ -3648,7 +3652,8 @@ async function ensureUvProject({
3648
3652
  await createPyprojectToml({
3649
3653
  projectName: "app",
3650
3654
  pyprojectPath,
3651
- dependencies: []
3655
+ dependencies: [],
3656
+ pythonVersion
3652
3657
  });
3653
3658
  }
3654
3659
  await uv.addFromFile({
@@ -3665,7 +3670,8 @@ async function ensureUvProject({
3665
3670
  await createPyprojectToml({
3666
3671
  projectName: "app",
3667
3672
  pyprojectPath,
3668
- dependencies: []
3673
+ dependencies: [],
3674
+ pythonVersion
3669
3675
  });
3670
3676
  await uv.lock(projectDir);
3671
3677
  }
@@ -4561,6 +4567,7 @@ var build = async ({
4561
4567
  repoRootPath,
4562
4568
  pythonPath: pythonVersion.pythonPath,
4563
4569
  pipPath: pythonVersion.pipPath,
4570
+ pythonVersion: pythonVersion.version,
4564
4571
  uv,
4565
4572
  venvPath,
4566
4573
  meta,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vercel/python",
3
- "version": "6.4.1",
3
+ "version": "6.4.2",
4
4
  "main": "./dist/index.js",
5
5
  "license": "Apache-2.0",
6
6
  "homepage": "https://vercel.com/docs/runtimes#official-runtimes/python",
@@ -30,8 +30,8 @@
30
30
  "pip-requirements-js": "1.0.2",
31
31
  "smol-toml": "1.5.2",
32
32
  "which": "3.0.0",
33
- "@vercel/error-utils": "2.0.3",
34
- "@vercel/build-utils": "13.2.16"
33
+ "@vercel/build-utils": "13.2.16",
34
+ "@vercel/error-utils": "2.0.3"
35
35
  },
36
36
  "scripts": {
37
37
  "build": "node ../../utils/build-builder.mjs",