galaxyproject / galaxyproject/planemo

Default '--owner' argument for shed_init

Open
#289 1 comment 1 reaction 0 assignees View on GitHub
enhancement toolshed
Dominant language
Python
Stars
110
Forks
102
Avg merge
4d 21h
Merged PRs (30d)
13

Description

Currently the command `planemo shed_init ./` produces the error

```
Traceback (most recent call last):
File "/Users/ellrott/workspaces/SMC-Het-Challenge/venv/bin/planemo", line 11, in
sys.exit(planemo())
File "/Users/ellrott/workspaces/SMC-Het-Challenge/venv/lib/python2.7/site-packages/click/core.py", line 700, in __call__
return self.main(*args, **kwargs)
File "/Users/ellrott/workspaces/SMC-Het-Challenge/venv/lib/python2.7/site-packages/click/core.py", line 680, in main
rv = self.invoke(ctx)
File "/Users/ellrott/workspaces/SMC-Het-Challenge/venv/lib/python2.7/site-packages/click/core.py", line 1027, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/Users/ellrott/workspaces/SMC-Het-Challenge/venv/lib/python2.7/site-packages/click/core.py", line 873, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/Users/ellrott/workspaces/SMC-Het-Challenge/venv/lib/python2.7/site-packages/click/core.py", line 508, in invoke
return callback(*args, **kwargs)
File "/Users/ellrott/workspaces/SMC-Het-Challenge/venv/lib/python2.7/site-packages/click/decorators.py", line 63, in new_func
return ctx.invoke(f, obj, *args[1:], **kwargs)
File "/Users/ellrott/workspaces/SMC-Het-Challenge/venv/lib/python2.7/site-packages/click/core.py", line 508, in invoke
return callback(*args, **kwargs)
File "/Users/ellrott/workspaces/SMC-Het-Challenge/venv/lib/python2.7/site-packages/planemo/commands/cmd_shed_init.py", line 50, in cli
exit_code = shed.shed_init(ctx, path, **kwds)
File "/Users/ellrott/workspaces/SMC-Het-Challenge/venv/lib/python2.7/site-packages/planemo/shed/__init__.py", line 141, in shed_init
create_failed = _create_shed_config(ctx, shed_config_path, **kwds)
File "/Users/ellrott/workspaces/SMC-Het-Challenge/venv/lib/python2.7/site-packages/planemo/shed/__init__.py", line 678, in _create_shed_config
owner_invalid = validate_repo_owner(owner)
File "/Users/ellrott/workspaces/SMC-Het-Challenge/venv/lib/python2.7/site-packages/planemo/shed/__init__.py", line 1206, in validate_repo_owner
if len(owner) < 3:
TypeError: object of type 'NoneType' has no len()
```

It would be useful to have some default value for the '--owner' flag to avoid this error.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.