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

190
Vistas
How to handel "net::ERR_QUIC_PROTOCOL_ERROR 200" in a fetch?

By simulating a Lie-Fi connection I noticed that I get an (net::ERR_QUIC_PROTOCOL_ERROR) error that didn't triggered the catch part of the fetch statement. The reason that the fetch wasn't triggered is that the status code of the network request returned 200. Why is this Error OK (200)?.

But the main question is how can I detect and handle these errors?

This question gets more interesting in case the fetch is part of a fetch event handel of a serviceworker. For when the serviceworker tries to fetch something from the internet and if that isn't possible returns a result from the cache. These errors however will not be seen as an error and therefore the data from the cache will not be returned. As a user I then will not get the offline experience I would expect.

// please set Network Throttling to Lie-Fi (1kbit/s up&down)
const timeoutSimulation = () => {
  return fetch('https://thispersondoesnotexist.com/image', {mode: 'no-cors'})
    .then((response) => {
      console.log(`would not expect to see this message, due to the net error`);
      return response;
    })
    .catch((error) => {
      console.log('expect this error to be shown', error);
    })
}
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