Skip to content

Commit

Permalink
Merge pull request #12 from mvdbeek/fixes_for_deployment
Browse files Browse the repository at this point in the history
Fixes for deployment
  • Loading branch information
jmchilton authored Oct 10, 2023
2 parents 7f54913 + b79637d commit 6f5b4df
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 4 deletions.
3 changes: 2 additions & 1 deletion gx_tool_db/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
TEST_URL: 'test',
USEGALAXY_EU_URL: 'eu',
USEGALAXY_AU_URL: 'au',
"https://clipseq.usegalaxy.eu/": "cliqseq_eu",
"https://clipseq.usegalaxy.eu/": "clipseq_eu",
"https://humancellatlas.usegalaxy.eu/": "humancellatlas_eu",
"https://metabolomics.usegalaxy.eu/": "metabolomics_eu",
"https://ml.usegalaxy.eu/": "ml_eu",
Expand Down Expand Up @@ -74,6 +74,7 @@ def label(self):

class ViewDefintion(FilterArguments):
id: str
name: Optional[str] = None
output: Optional[str] = None
view_type: str = DEFAULT_PANEL_VIEW_TYPE
description: Optional[str] = None
Expand Down
7 changes: 6 additions & 1 deletion gx_tool_db/db.py
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,11 @@ def panel_view_dict(self, server_label: str, view_def: ViewDefintion):
filter_criteria.require_labels = view_def.require_labels
filter_criteria.exclude_labels = view_def.exclude_labels

rval: Dict[str, Any] = {"id": view_def.id, "type": view_def.view_type}
rval: Dict[str, Any] = {
"id": view_def.id,
"type": view_def.view_type,
"name": view_def.name or view_def.id,
}
if view_def.description:
rval["description"] = view_def.description

Expand Down Expand Up @@ -229,6 +233,7 @@ def panel_view_dict(self, server_label: str, view_def: ViewDefintion):
section = {
"id": panel_skeleton_item_id,
"name": name,
"type": "section",
}
# If we're requiring a label need to specify the elements, otherwise we can just
# count on a global exclude of the tools in the map.
Expand Down
2 changes: 2 additions & 0 deletions gx_tool_db/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -586,6 +586,7 @@ def arg_parser():
parser_export_view.add_argument('--output', type=str, help="Output YAML (defaults to <id>.yml", default=None)
HELP_ARG_VIEW_TYPE = "Panel view type (generic, activity, publication, training, ...)"
parser_export_view.add_argument('--view-type', type=str, help=HELP_ARG_VIEW_TYPE, default=DEFAULT_PANEL_VIEW_TYPE)
parser_export_view.add_argument('--name', type=str, help="Name of panel view.")
parser_export_view.add_argument('--description', type=str, help="End user description of panel view.")
add_common_filters(parser_export_view)

Expand Down Expand Up @@ -666,6 +667,7 @@ def main(argv=None):
view_def.output = args.output
view_def.view_type = args.view_type
view_def.description = args.description
view_def.name = args.name
view_def.require_labels = args.require_labels
view_def.exclude_labels = args.exclude_labels
export_panel_view(config, args.server, view_def)
Expand Down
4 changes: 2 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ google-auth-oauthlib
gspread
gxformat2
packaging
pydantic
pydantic<2
requests
pyyaml
typing-extensions
urllib3
urllib3

0 comments on commit 6f5b4df

Please sign in to comment.