Skip to content
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

Adding values that aren't file paths #93

Open
nsheff opened this issue Mar 31, 2020 · 1 comment
Open

Adding values that aren't file paths #93

nsheff opened this issue Mar 31, 2020 · 1 comment
Projects
Milestone

Comments

@nsheff
Copy link
Contributor

nsheff commented Mar 31, 2020

We recently removed the file checks on the seek function, which allows us to store things in refgenie that aren't file paths, like we are now doing for the bowtie2_index asset.

But it's still impossible to use add on a string that is not a filepath.

  1. the value is called path:
refgenie add x/y
usage: refgenie add [-h] [-c GENOME_CONFIG] [-g GENOME] -p PATH
                    asset-registry-paths [asset-registry-paths ...]
refgenie add: error: the following arguments are required: -p/--path

  1. It has to be a path, can't be an arbitrary string:
refgenie add x/y -p 1,500
Using 'default' as the default tag for 'x/y'
Traceback (most recent call last):
  File "/home/nsheff/.local/bin/refgenie", line 10, in <module>
    sys.exit(main())
  File "/home/nsheff/.local/lib/python3.7/site-packages/refgenie/refgenie.py", line 638, in main
    refgenie_add(rgc, asset_list[0], args.path)
  File "/home/nsheff/.local/lib/python3.7/site-packages/refgenie/refgenie.py", line 274, in refgenie_add
    format(abs_asset_path, rgc[CFG_FOLDER_KEY]))
OSError: Absolute path '/home/nsheff/code/refgenie_sandbox/x/1,500' does not exist. The provided path must be relative to: /home/nsheff/code/refgenie_sandbox

Should we change add to reflect the changes? I'd suggest:

  1. change the name of the arg from path to value.
  2. don't enforce that the path must exist or make it absolute

perhaps there could be a -p/--path flag that would flag your value as a path, and then behave as it currently does?

@nsheff nsheff mentioned this issue Mar 31, 2020
4 tasks
@nsheff
Copy link
Contributor Author

nsheff commented Mar 31, 2020

@stolarczyk stolarczyk added this to the 0.12.0 milestone Mar 11, 2021
@nsheff nsheff added this to Increased utility features in Refgenie Mar 16, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Refgenie
Improving usefulness: cloud and other...
Development

No branches or pull requests

2 participants