Hi,
I have recently upgraded Galaxy from a version I had last year. In my tool
xml file I could state:
${ __app__.model.User.get( $__user_id__ ).api_keys[0].key }
in the command section to get the user's API. However, after updating to the
current version of Galaxy I get the following
Hmm...
The following should work for the last at least three releases I
think: ${__user__.api_keys[0].key}. Not sure why get/find are
unavailable on the User model class in the cheetah template now. I
think this version is a little better. Is this okay? If not I can
create a Trello card to
The method John suggests is definitely a better way to get the user's API
key.
That said, the 'get' change is due to sqlalchemy version changes that
happened quite a while back. You can no longer 'get' directly from the
model, you must use a query object. So, for example, this line: