Skip to content

improve user experience by complaining when reload_dirs is given a string instead of a list #976

Closed
@max-l

Description

@max-l

Passing a string to reload_dirs as in the following, causes reload to silently not work :

    uvicorn.run(
        "dp.server:app",
        host="127.0.0.1", port=5000,
        log_level="info",
        reload=True,
        reload_dirs="/home/maxou/dev/proj",
        reload_delay=2.0
    )

Giving reload_dirs an array : ["/home/maxou/dev/proj"] fixes the problem

It's not really a bug, but complaining with an error message would improve the user experience.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions