qiime2 / q2cli

Command line interface for QIIME 2
BSD 3-Clause "New" or "Revised" License
19 stars 24 forks source link

De-Facto keyed collections do not like paths starting with ~ #308

Closed Oddant1 closed 10 months ago

Oddant1 commented 1 year ago

Bug Description When creating a de-facto keyed collection of inputs on the command-line paths that start with ~ do not work. It does not find the artifact then errors out on the key as if it were a bad cache. We need to expand the ~ to be the home directory if it is at the head of the path. Click does this on its own if it just receives a path like ~/foo, but if it gets a key:path like bar:~/foo it obviously doesn't understand that it needs to expand that ~.

Steps to reproduce the behavior

  1. Pick an action that takes a Collection of inputs
  2. Give the collection a keyed member with a path starting with ~
  3. See it get confused

Expected behavior It should actually find the artifact.

Screenshots You can see that it found the foo keyed artifact, so the artifact does exist, but for the bar keyed one the path starting with ~ confused it into not finding the artifact.


image


Computation Environment