Skip to content

Changes to HTTP Responder for static type examples #11

@indigo-jay

Description

@indigo-jay

The method to return a static file in this plugin seems to have generated some confusion. Suggestions:

  • Update it with clear language that there are 3 ways to deliver static content:
    • Automatically via the /Resources/ directory
    • Semi-automatically by returning indigo.utils.return_static_file (handle_static_file_request shows this by delivering a custom 404 html file)
    • By streaming returning the contents of the file yourself (handle_static_file_request shows this)
  • Change the indigo.utils.FILE_EXTENSION_MIME_MAP lookup to use mimetypes.guess_type instead since that is now built-in (at least with Python 3.10).

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions