Skip to content

Hangs resolving external references with NodeJS >= 12.17.0 #422

Open
@mgabeler-lee-6rs

Description

Detailed description

When running with NodeJS 12.17.0 or higher, speccy (esp. speccy lint) hangs when attempting to resolve external resources that come over HTTP/2.

Context

This renders speccy unusable by my team in our efforts to track NodeJS LTS releases.

I believe this is caused by hisco/http2-client#26 (comment) -- not strictly speccy's fault, but speccy is dramatically affected.

Possible implementation

Not sure if speccy folks could help fix this issue in the underlying libraries, or adjust to a different HTTP/2 client library

Your environment

  • Node Version: 12.x (via nodenv)
  • Operating system and version: Linux (Debian) and macOS (various recent releases)

Demo file: note that the fact that the referenced URL is a 404 doesn't matter, because the nature of this bug is such that speccy and its dependencies never see the response anyways. It does matter that example.com serves HTTP/2.

openapi: 3.0.2
components:
  x:
    $ref: 'https://example.com/invalid.yaml'

Install node 12.17.0 or higher and just run npx speccy lint --verbose demo.yaml, or to see the full trace details, NODE_OPTIONS=--trace-tls NODE_DEBUG='*' npx speccy lint --verbose demo.yaml

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions