Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hammerhead crashes upon loading any attachment. this.session.handleAttachment is not a function #2708

Closed
luphoria opened this issue Oct 31, 2021 · 2 comments · Fixed by #2709

Comments

@luphoria
Copy link

What is your Scenario?

I tried to get hammerhead working (i have done this previously with similar configurations) again using a simple config (in my case, just playground). I have done these exact steps before so it must be something recent within the past few months causing this issue?

What is the Current behavior?

Everything compiles correctly and you can visit the page, and even attempt to go to some URL. however, it completely crashes when you request https://google.com (which is just the domain i use to check if everything is up and running!).

What is the Expected behavior?

What is your public web site URL?

Gonna skip over the "app code" and "complete URL" as i have tried this in both production and on just localhost with zero changes to the demo.. the issue is persistent.

Screenshots:
Server listens on port 1400
[20:37:46] 'http-playground-server' errored after 19 s
[20:37:46] TypeError: this.session.handleAttachment is not a function
    at RequestPipelineContext.buildContentInfo (/home/trent/testcafe-hammerhead/lib/request-pipeline/context.js:204:26)
    at DestinationRequest.<anonymous> (/home/trent/testcafe-hammerhead/lib/request-pipeline/utils.js:47:17)
    at DestinationRequest.emit (events.js:400:28)
    at DestinationRequest.emit (domain.js:537:15)
    at DestinationRequest._emitOnResponse (/home/trent/testcafe-hammerhead/lib/request-pipeline/destination-request/index.js:137:14)
    at DestinationRequest._onResponse (/home/trent/testcafe-hammerhead/lib/request-pipeline/destination-request/index.js:133:18)
    at ClientHttp2Stream.<anonymous> (/home/trent/testcafe-hammerhead/lib/request-pipeline/destination-request/index.js:63:18)
    at ClientHttp2Stream.emit (events.js:400:28)
    at ClientHttp2Stream.emit (domain.js:537:15)
    at emit (internal/http2/core.js:308:8)
    at processTicksAndRejections (internal/process/task_queues.js:85:22)
[20:37:46] 'http-playground' errored after 48 s

Steps to Reproduce:

git clone https://github.com/DevExpress/testcafe-hammerhead.git
cd testcafe/hammerhead
npm i
node node_modules/gulp/bin/gulp http-playground

visit localhost:1400
type https://google.com
press Proxy!

Your Environment details:

  • node.js version: v14.18.1
  • browser name and version: Firefox 93.0
  • platform and version: Ubuntu 21.04 x64 (and 20.04)
@luphoria
Copy link
Author

..i have a sneaking suspicion this issue is related to this commit.. lol. 8e616df

@luphoria luphoria changed the title Crashes. this.session.handleAttachment is not a function? Hammerhead crashes upon loading any attachment. this.session.handleAttachment is not a function Oct 31, 2021
@Farfurix
Copy link
Contributor

Farfurix commented Nov 1, 2021

@luphoria

Hello,

Thank you, I reproduced this issue. We'll update this thread once we have any news.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants