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

IPv6 support #131

Closed
tambry opened this issue Mar 17, 2018 · 2 comments
Closed

IPv6 support #131

tambry opened this issue Mar 17, 2018 · 2 comments

Comments

@tambry
Copy link

tambry commented Mar 17, 2018

Encountered the problem while setting up a small IPv6-only API endpoint.

Minimal code:

from flask import Flask

app = Flask(__name__)

@app.route("/", methods=["GET"])
def hello(res):
        print("Hello world")

if __name__ == "__main__":
        import bjoern
        bjoern.run(app, "::1", 2018)

Error:

Traceback (most recent call last):
  File "vpmf.py", line 12, in <module>
    bjoern.run(app, '::1', 2018)
  File "/usr/local/lib64/python3.6/site-packages/bjoern.py", line 68, in run
    listen(*args, **kwargs)
  File "/usr/local/lib64/python3.6/site-packages/bjoern.py", line 52, in listen
    sock = bind_and_listen(host, port, reuse_port)
  File "/usr/local/lib64/python3.6/site-packages/bjoern.py", line 30, in bind_and_listen
    sock.bind((host, port))
socket.gaierror: [Errno -9] Address family for hostname not supported
@tambry
Copy link
Author

tambry commented Mar 17, 2018

Just noticed there's also a patch for it in #99.

@jonashaag
Copy link
Owner

Yes, please continue discussion/work there.

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

No branches or pull requests

2 participants