Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
Pythonとボトルを使用してサーバーを構築しています。
バイナリ ファイルの要求を処理するにはどうすればよいですか?
フラスコを使用する必要があることを読みました。フラスコを使わずにそれを行う方法はありますか?
はい、static_file関数を使用する必要があります:
static_file
from bottle import static_file @route('/download/<filename:path>') def download(filename): return static_file(filename, root='/path/to/static/files', download=filename)