-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make web UI dependencies optional #119
Conversation
Honestly, I saw this coming years ago. At the time I felt strongly that Gilda should have a default, built in REST API that can be run locally without any extra dependencies. The issue with problematic additional dependencies is why I didn't want to mix that up with UI elements. So the solution I'd ideally be looking for is the combination is a (1) non-optional programmatic REST API and (2) optional UI elements. Is that possible using either two different modules for web services (that might still reuse some code) or some kind of blueprint-based setup? |
See e.g., #41 (comment) |
@bgyori I think this is doable |
@bgyori I managed to make the UI optional. If it's flagged to not use the UI or the UI dependencies aren't available, then the home page will automatically redirect to api docs page. |
23aa2fe
to
7f774f3
Compare
There are several situations in which installing the web dependencies for Gilda by default is inconvenient. The largest are due to conflicts in versions of werkzeug (which is pinned in gilda) and conflicts between flask-bootstrap (the one gilda uses, but it's abandoned) and bootstrap-flask (fork other former and is currently maintained) As it is, it's not possible to easily have gilda simultaneously installed with biomappings, and this is a concrete issue for Jeremy T who wants to contribute some curations (without him doing some more manual dependency management) This PR simply makes the web dependencies optional. It updates the dockerfile and tests to make sure these are still installed where necessary, and updates relevant documentation accordingly
52e2686
to
946c8fa
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Works great, thanks!
Update text
This PR makes the UI for the gilda web app optional. This means you don't have to install the
flask-bootstrap
orflask-wtf
dependencies by default. If these aren't available, the home page just redirects to the apidocs.These changes were made after the original PR (see text below) due to comment in #119 (comment).
Original Text
There are several situations in which installing the web dependencies for Gilda by default is inconvenient. The largest are due to conflicts in versions of werkzeug (which is pinned in gilda) and conflicts between flask-bootstrap (the one gilda uses, but it's abandoned) and bootstrap-flask (fork other former and is currently maintained)
As it is, it's not possible to easily have gilda simultaneously installed with biomappings, and this is a concrete issue for someone who might want to contribute some curations (without doing some more manual dependency management)
This PR simply makes the web dependencies optional. It updates the dockerfile and tests to make sure these are still installed where necessary, and updates relevant documentation accordingly