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

215
Vistas
Requests-HTML - Page rendering of Java script not working

I'm trying to load the price history of Nestle through Requests-HTML. The script I'm using is:

import asyncio
import requests            
import requests_html

# Jupyter Notebooks related imports
import nest_asyncio        
nest_asyncio.apply()
from requests_html import AsyncHTMLSession
test_url= 'https://www.finanzen.ch/kurse/historisch/nestle/swx/1.1.2022_3.7.2022'
asession = AsyncHTMLSession()
rq = await asession.get(test_url)
rq.html.arender()
with open(Path ('HTML_Req_rendered.html'), 'wb') as f:
    test_txt= f.write(rq.html.raw_html)  

The file [HTML_Req_rendered.html](https://drive.google.com/file/d/1JWSxtM6RVR5I1VgIH-K6ZxQ66e1pbWKz/view?usp=sharing #GoogleDriveLink) is generated correctly but does not contain the price history loaded by javaScript. Please see the link top webpage.

Can anyone help? What am I doing wrong? How can I get a rendered HTML?

Any help is kindly appreciate. Thx. Stefano

about 4 years ago · Juan Pablo Isaza
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