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

Crash when the favicon does not exists #115

Open
Pierre-Sassoulas opened this issue Aug 22, 2021 · 3 comments
Open

Crash when the favicon does not exists #115

Pierre-Sassoulas opened this issue Aug 22, 2021 · 3 comments

Comments

@Pierre-Sassoulas
Copy link

Hello, thank you for creating this module, I'm going to try to make my import faster using it :)

I got the following error while monkey testing the server:

Exception happened during processing of request from ('127.0.0.1', 45132)
Traceback (most recent call last):
  File "/usr/lib/python3.8/socketserver.py", line 316, in _handle_request_noblock
    self.process_request(request, client_address)
  File "/usr/lib/python3.8/socketserver.py", line 347, in process_request
    self.finish_request(request, client_address)
  File "/usr/lib/python3.8/socketserver.py", line 360, in finish_request
    self.RequestHandlerClass(request, client_address, self)
  File "/usr/lib/python3.8/socketserver.py", line 747, in __init__
    self.handle()
  File "/usr/lib/python3.8/http/server.py", line 427, in handle
    self.handle_one_request()
  File "/usr/lib/python3.8/http/server.py", line 415, in handle_one_request
    method()
  File "/home/pierre/pylint/venv/lib/python3.8/site-packages/tuna/main.py", line 63, in do_GET
    with open(filepath, "rb") as fh:
FileNotFoundError: [Errno 2] No such file or directory: '/home/pierre/pylint/venv/lib/python3.8/site-packages/tuna/web/favicon.ico'
@nschloe
Copy link
Owner

nschloe commented Aug 22, 2021

No idea why it's looking for favicon.ico. If anything, it should be favicon256.png.

@FraserParlane
Copy link

+1 for this issue. There's also no favicon256.png in that folder. Only index.html and a static directory.

@nschloe
Copy link
Owner

nschloe commented Sep 15, 2021

I double-checked and favicon256.png is shipped. No idea what should be wrong here.

mohammad7t added a commit to mohammad7t/tuna that referenced this issue Nov 7, 2021
As explained in [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/rel), the shortcut link type is often seen before icon, but this link type is non-conforming, ignored and web authors must not use it anymore.

This PR might solve nschloe#115
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

3 participants