intermine / intermine/bluegenes

Support broken templates

Open
#767 0 comments 0 reactions 0 assignees View on GitHub
InterMine backend Templates
Dominant language
Clojure
Stars
75
Forks
59
PR merge metrics
No merged PRs in 30d

Description

They will be included with the response from `GET /templates` web service if `includeBroken: true` is included in the request params. However, there is no way to ascertain whether a template is broken other than by validating it against the model. If we want to show broken templates in BG, the WS should be updated to include a `broken: true` flag to the broken template objects.

Once this is done, we can change `:assets/fetch-templates` to include broken, and ensure everywhere templates are shown filters to the non-broken ones. Except for the manage templates admin panel, which should show the broken templates distinctly, to allow users to export and delete them, so they can reupload after manually fixing the query XML.

This is how it's shown in the JSP webapp mymine templates page:

![image](https://user-images.githubusercontent.com/3865590/146365578-17eb6a0a-21f1-43f4-95ab-6dbb07479e90.png)

To create a broken template on Biotestmine:

```sql
userprofile-biotestmine=> insert into savedtemplatequery (id, userprofileid, templatequery) VALUES(68000010, 1000001, '');
```

Contributor guide

Open the contributing guide

Research direction

Start with the GET /templates web service response and the :assets/fetch-templates entry point. Trace where templates are displayed, including the manage templates admin panel. Done means broken templates carry a broken flag, are included for fetching, hidden from ordinary views, and remain distinct and manageable in the admin panel.

Written by the indexing model from the issue text.

Assessment

Tech stack
clojure
Domain
api, full-stack
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.