Skip to content

Collection.find_one_or_404 hides stack trace #159

Closed
@Joe-Heffer-Shef

Description

@Joe-Heffer-Shef

Hi,

When I try to retrieve a single item from a MongoDB collection and it isn't present, I want an error to be raised, which is the purpose of Collection.find_one_or_404. However, a 404 screen is shown which prevents me from seeing a stack trace (in Flask debug mode.)

Please could find_one_or_404 instead raise some kind of not-found exception, rather than using flask.abort. This way, I could see the stack trace (or handle the error appropriately using Flask error handlers.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions