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

"beacon node misconfiguration" error on /eth/v1/events #14607

Open
a26nine opened this issue Nov 2, 2024 · 7 comments
Open

"beacon node misconfiguration" error on /eth/v1/events #14607

a26nine opened this issue Nov 2, 2024 · 7 comments
Labels
API Api related tasks Bug Something isn't working Need-Info Need more information from author

Comments

@a26nine
Copy link

a26nine commented Nov 2, 2024

Describe the bug

When trying to subscribe to events with Prysm v5.1.2, the node throws misconfiguration error.

Flags

prysm \
    --accept-terms-of-use \
    --datadir=/data/prysm \
    --chain-config-file=/data/prysm/config.yml \
    --genesis-state=/data/prysm/genesis.ssz \
    --chain-id=xxx \
    --network-id=xxx \
    --execution-endpoint=http://127.0.0.1:8551 \
    --jwt-secret=/data/jwtsecret \
    --http-host=0.0.0.0 \
    --http-port=3500 \
    --rpc-host=0.0.0.0 \
    --rpc-port=4000 \
    --http-cors-domain="*" \
    --http-modules=eth,prysm \
    --bootstrap-node=xxx \
    --peer=xxx \
    --min-sync-peers=1 \
    --p2p-tcp-port=13000 \
    --p2p-udp-port=12000 \
    --p2p-max-peers=50 \
    --p2p-static-id \
    --slots-per-archive-point=32 \
    --blob-retention-epochs=1000000 \
    --api-timeout=30s \
    --monitoring-host=127.0.0.1 \
    --monitoring-port=8080

Execution Client: Geth v1.14.11

The node is syncing fine and responds to other methods without any issues.

Has this worked before in a previous version?

No response

🔬 Minimal Reproduction

  1. Run Prysm v5.1.2 (with the above flags).
  2. Call curl "http://localhost:3500/eth/v1/events?topics=head" -H "Accept: text/event-stream"

Error

{"message":"beacon node misconfiguration: http stack may not support required response handling features, like flushing","code":500}

Platform(s)

Linux (x86)

What version of Prysm are you running? (Which release)

v5.1.2

Anything else relevant (validator index / public key)?

No response

@a26nine a26nine added the Bug Something isn't working label Nov 2, 2024
@james-prysm
Copy link
Contributor

Is there possibly something else with your setup that may be different? cURL should be supported here

@james-prysm james-prysm added API Api related tasks Need-Info Need more information from author labels Nov 4, 2024
@a26nine
Copy link
Author

a26nine commented Nov 5, 2024

Is there possibly something else with your setup that may be different? cURL should be supported here

I don't think or am aware of anything else that would be different here. You can see the node config in the OP. Plus, other Beacon API methods seem to work without any issues.

@james-prysm
Copy link
Contributor

Could you try using any other tool outside of curl to see if you're able to query, the flush is required for event stream endpoints

@a26nine
Copy link
Author

a26nine commented Nov 5, 2024

Could you try using any other tool outside of curl to see if you're able to query, the flush is required for event stream endpoints

websocat ws://localhost:3500/eth/v1/events?topics=head

---

websocat: WebSocketError: WebSocketError: Received unexpected status code (500 Internal Server Error)
websocat: error running
#!/usr/bin/python3
import requests
import sys

try:
    response = requests.get(
        'http://localhost:3500/eth/v1/events?topics=head',
        headers={
            'Accept': 'text/event-stream',
            'Cache-Control': 'no-cache'
        },
        stream=True,
        timeout=30
    )
    
    print(f"Status: {response.status_code}")
    print(f"Headers: {dict(response.headers)}")
    
    for line in response.iter_lines():
        if line:
            print(line.decode('utf-8'))
            sys.stdout.flush()
            
except Exception as e:
    print(f"Error: {e}")

---

Status: 500
Headers: {'Content-Length': '132', 'Content-Type': 'application/json', 'Vary': 'Origin', 'Date': 'Tue, 05 Nov 2024 17:54:16 GMT'}
{"message":"beacon node misconfiguration: http stack may not support required response handling features, like flushing","code":500}
root@vana-mainnet-archive-ora-iad-a00:~# 

@a26nine
Copy link
Author

a26nine commented Nov 5, 2024

Is there any configuration flag that may be causing or can help with this issue?

@prestonvanloon
Copy link
Member

Where does this error come from? "beacon node misconfiguration" is not a string found in our repo.

@james-prysm
Copy link
Contributor

@prestonvanloon This error was in v5.1.2, but due to recent changes from kasey it shouldn't be there anymore

msg := "beacon node misconfiguration: http stack may not support required response handling features, like flushing"

still... both of us were testing with curl and haven't run into the above error, which should be that the client is unable to call the flush function on the writer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
API Api related tasks Bug Something isn't working Need-Info Need more information from author
Projects
None yet
Development

No branches or pull requests

4 participants
@prestonvanloon @james-prysm @a26nine and others