Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

65
Vistas
Pyodide languagePluginLoader is not defined

I have been using Pyodide to run some python in my website. It has been working up until recently, however now has begin giving this error,

Uncaught ReferenceError: languagePluginLoader is not defined
at 2347:162

Some searching has revealed that this method is deprecated in pyodide anyway

https://pyodide.org/en/stable/usage/api/js-api.html#globalThis.loadPyodide

and Insteasd of using languagePluginUrl I should use loadPyodide.

I have no idea how to do this, I know nothing of js, only python,

My code is...

<script type="text/javascript">
    languagePluginLoader.then(() => {
    pyodide.loadPackage(['numpy']).then(() => {
        pyodide.runPython(`   


    # My python code here


      `);
  });});

</script>

This used to work fine, so I think I just need to use the new method. Any help converting it to the new method appreciated - Thanks.

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

You're probably using a newer version of pyodide. Since 0.18.0, you should use loadPyodide with the pyodide base url instead, which gives the pyodide object in the callback:

const PYODIDE_BASE_URL = "https://cdn.jsdelivr.net/pyodide/v0.18.0/full"

loadPyodide({ indexURL: PYODIDE_BASE_URL }).then((pyodide) => {
  globalThis.pyodide = pyodide      // you might also want to store pyodide globally so 
                                    // so you can access anywhere in the scope
  pyodide.loadPackage(['numpy']).then(() => {
    pyodide.runPython(`   
    # My python code here
  `);
});});
about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda