Security News
Supply Chain Attack Detected in Solana's web3.js Library
A supply chain attack has been detected in versions 1.95.6 and 1.95.7 of the popular @solana/web3.js library.
Download and extract Pyodide packages from Github
releases
(pyodide-build-*.tar.bz2
). The version of the release needs to match exactly the version of this package.
Then you can load Pyodide in Node.js as follows,
// hello_python.js
const { loadPyodide } = require("pyodide");
async function hello_python() {
let pyodide = await loadPyodide({
indexURL: "<pyodide artifacts folder>",
});
return pyodide.runPythonAsync("1+1");
}
hello_python().then((result) => {
console.log("Python says that 1+1 =", result);
});
$ node hello_python.js
Loading distutils
Loaded distutils
Python says that 1+1= 2
Or you can use the REPL. To start the Node.js REPL with support for top level
await, use node --experimental-repl-await
:
$ node --experimental-repl-await
Welcome to Node.js v18.5.0.
Type ".help" for more information.
> const { loadPyodide } = require("pyodide");
undefined
> let pyodide = await loadPyodide();
Loading distutils
Loaded distutils
undefined
> await pyodide.runPythonAsync("1+1");
2
The JavaScript code in this package is responsible for the following tasks:
js/pyodide
JavaScript API into sys.modules
. This is the
final runtime dependency for core/pyodide
& py/pyodide
, so after this step
the interpreter is fully up and running.FAQs
The Pyodide JavaScript package
The npm package pyodide receives a total of 57,532 weekly downloads. As such, pyodide popularity was classified as popular.
We found that pyodide demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
A supply chain attack has been detected in versions 1.95.6 and 1.95.7 of the popular @solana/web3.js library.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.