Skip to content

Make flasgger optional? #26

Open
Open
@AdamWill

Description

@AdamWill

Hi! I'm a packager for Fedora. We've run into a bit of a roadblock trying to update Fedora's httpbin package: https://bugzilla.redhat.com/show_bug.cgi?id=2233128#c9

since the last version we packaged, httpbin grew a hard dependency on flasgger. flasgger is not packaged for Fedora and is a bit tricky to package because it contains several bundled, pre-minified javascript libraries, which is against Fedora's packaging guidelines. (They are also, I'll note, ancient - upstream hasn't updated the bundled libraries for ui2 or ui3 since it added them, six and five years ago respectively.)

We can probably work around this if necessary (perhaps by only packaging ui3, the one httpbin uses, which is simpler as it only bundles jquery 2.x), but another option is to look at having httpbin not use flasgger. It doesn't seem, strictly speaking, to be necessary - all it does (AIUI) is provide API docs in the web UI, which is neat but not critical. Especially not since the main reason we package httpbin in Fedora is as a dependency of requests' test suite - no human is looking at API docs in a web UI there.

Would it be acceptable to send a patch to make the flasgger dependency optional, and just skip all the flasgger setup stuff in httpbin/core.py if it's not present?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions