Skip to content

Commit 2913980

Browse files
committed
Include openssl and test in the pyodide-lock.json
1 parent 83276a2 commit 2913980

File tree

2 files changed

+4
-7
lines changed

2 files changed

+4
-7
lines changed

.github/workflows/gh-pages.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,6 @@ jobs:
8787
- name: Extract the PyPa simple repository API
8888
run: python tools/pypa-simple.py pypa/simple ../../../static/pyodide/
8989
- name: Extract the PyPi-enabled pyodide-lock.json
90-
continue-on-error: ${{ github.event_name != 'release' }}
9190
run: |
9291
python tools/pypa-simple.py pyodide/pypa/simple ../../../dist
9392
cp files/requirements.txt pyodide/my-requirements.txt

tools/makelock.mjs

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,9 @@ const [_node_path, _script_path, requirements_path, new_lockfile_path] = argv;
77

88
const requirements = readFileSync(requirements_path, { encoding: 'utf8' });
99

10-
const py = await loadPyodide({ fullStdLib: true, packages: ["micropip"] });
10+
const py = await loadPyodide({ fullStdLib: true, packages: [
11+
"micropip", "openssl", "test",
12+
] });
1113

1214
await py.runPythonAsync(`
1315
import importlib.metadata
@@ -85,11 +87,7 @@ lock = json.loads(
8587

8688
for package in lock["packages"].values():
8789
package["depends"] = sorted(package["depends"])
88-
89-
try:
90-
package["imports"] = sorted(get_imports_for_package(package["name"]))
91-
except importlib.metadata.PackageNotFoundError:
92-
print(f"Package {package['name']} has not been installed")
90+
package["imports"] = sorted(get_imports_for_package(package["name"]))
9391

9492
with open("/pyodide-lock.json", "w") as f:
9593
json.dump(lock, f, sort_keys=True)

0 commit comments

Comments
 (0)