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

356
Vistas
xmlhttprequest check file exists not found file when build FLASK web app with Pyinstaller

I am building web app with Flask and Pyinstaller to build a single executable and i have the following problem:

  • Run by simply running "Python app.py" everything works fine. But after building the .exe file with Pyinstaller, the javascript code in the html file that has the function to check whether the created file exists or not, can't route to that file path even though the file exists, I tried manually enter the path to the file in the URL bar but the path cannot be found error,
  • Does building the python executable with Pyinstaller not route the newly created file? And is there any solution to fix it?
    var http = new XMLHttpRequest();
    http.open('HEAD', "/static/" + name_file_rc + ".avi", false);
    http.send();
    if (http.status === 200){
       allow_download = true;
       $('#remove_download').show();
       $('#download').show();                                                      
       $('#frame_record,#second,#size_file,#title_size_file,#title_second').show();
       Flag_stop_record_by_err = false;
       clearInterval(allow_download_inter);
       clearTimeout(timeout_download);
    }
    else{
       allow_download = false;
       // console.log("Load file fail");
    }
    
  • Thank you all for viewing my problem and looking forward to your help.
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