Skip to content

httl cli seems to malfunction in node18 #10

@PeterGrace

Description

@PeterGrace

test file

  $   cat test.httl
@base: http://localhost:3003/api/v1

Authorization: ApiKey 641bbc8eed048b3aab6a51bed3eb8b37

#post /workflows {
#    name: "my workflow"
#}
post /actions {
    name: "my workflow"
}

node 18

 $   nvm use v18.20.4
Now using node v18.20.4 (npm v10.7.0)

 $   npm install httl-cli -g

changed 19 packages in 249ms

17 packages are looking for funding
  run `npm fund` for details

 $   httl test.httl
⢎   Loading...[
  {
    "error": "connect ECONNREFUSED ::1:3003",
    "token": {
      "start": 140,
      "end": 181,
      "text": "post /actions{name:\"my workflow\"}"
    },
    "severity": 1
  }
]

node 20

  $   nvm use lts/iron
Now using node v20.18.3 (npm v10.8.2)

  $   npm install httl-cli -g

changed 19 packages in 215ms

17 packages are looking for funding
  run `npm fund` for details

  $   httl test.httl
 HTTP/1.1 200 OK
access-control-allow-origin: *
content-length: 14
content-type: text/plain; charset=utf-8
date: Fri, 21 Feb 2025 01:07:32 GMT
set-cookie: id=YUVoekqyOCSdGL3VlM2DtA; HttpOnly; SameSite=Strict; Path=/; Max-Age=86400
vary: origin, access-control-request-method, access-control-request-headers

Action created

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions