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

fix audioworklet example local server error #3347

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 5 additions & 0 deletions examples/wasm-audio-worklet/.gitignore
@@ -0,0 +1,5 @@
*.wasm
wasm_audio_worklet_bg.wasm.d.ts
wasm_audio_worklet.d.ts
wasm_audio_worklet.js
snippets/
7 changes: 5 additions & 2 deletions examples/wasm-audio-worklet/server.py
@@ -1,5 +1,5 @@
#!/usr/bin/env python3
from http.server import HTTPServer, SimpleHTTPRequestHandler, test
from http.server import HTTPServer, SimpleHTTPRequestHandler
import sys

class RequestHandler(SimpleHTTPRequestHandler):
Expand All @@ -9,4 +9,7 @@ def end_headers(self):
SimpleHTTPRequestHandler.end_headers(self)

if __name__ == '__main__':
test(RequestHandler, HTTPServer, port=int(sys.argv[1]) if len(sys.argv) > 1 else 8000)
port = int(sys.argv[1]) if len(sys.argv) > 1 else 8080
httpd = HTTPServer(('localhost', port), RequestHandler)
print("http://localhost:8080")
httpd.serve_forever()