Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

Request Header with a "-" failing

Abierto
#49 1 comentario 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
32/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Estancado
Stack tecnológico
docker, javascript

Línea de trabajo

Reproduce the failure with the provided Docker command and config.json, then inspect how the plugin passes Lighthouse settings to Network.setExtraHTTPHeaders. Compare the hyphenated and non-hyphenated header cases; done means valid headers with hyphens are accepted or the limitation is clearly documented.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

awaiting response

I am running the following command: docker run --shm-size=1g --rm -v "$(pwd)":/sitespeed.io sitespeedio/sitespeed.io:11.9.3-plus1 --config /sitespeed.io/config.json http://www.domain.com/ with the contents of config.json being:

{
  "lighthouse": {
      "settings": {
        "extra-headers": {"X-Bot-Allow":"123"},
        "extraHeaders": {"X-Bot-Allow":"123"}
      }
    }
}

I get the following error:

[2020-03-06 22:44:31] ERROR: Lighthouse could not test http://www.domain.com/ please create an upstream issue: https://github.com/GoogleChrome/lighthouse/issues/new?template=Bug_report.md Error: Protocol error (Network.setExtraHTTPHeaders): Invalid header value, string expected
    at Function.fromProtocolMessage (/lighthouse/node_modules/lighthouse/lighthouse-core/lib/lh-error.js:132:19)
    at /lighthouse/node_modules/lighthouse/lighthouse-core/gather/connections/connection.js:123:25
    at runMicrotasks (<anonymous>)
    at processTicksAndRejections (internal/process/task_queues.js:93:5)
[2020-03-06 22:44:31] ERROR: TypeError: Cannot read property 'lhr' of undefined
    at Object.processMessage (/lighthouse/index.js:200:28)
    at runMicrotasks (<anonymous>)
    at processTicksAndRejections (internal/process/task_queues.js:93:5)

If I strip the hyphens from X-Bot-Allow, it works, but I need the hyphens as we use this header to allow our sites to not block our sitespeedio tests. Any ideas?

Lenguaje dominante
JavaScript
Estrellas
31
Forks
21
Métricas de merge de PR
Sin PR fusionados en 30 d

Guía de contribución

No hay ninguna guía de contribución indexada para este repositorio

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de sitespeedio/plugin-lighthouse

Todos los issues de sitespeedio/plugin-lighthouse

Issues similares

Más issues de JavaScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.