Skip to content

Install via conda #2554

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

Merged
merged 58 commits into from
Jul 27, 2016
Merged

Install via conda #2554

merged 58 commits into from
Jul 27, 2016

Conversation

mvdbeek
Copy link
Member

@mvdbeek mvdbeek commented Jun 26, 2016

This is @bwlang and my project for the gcc hackathon (also see bxlab#39).
The actual place where we're doing the install still needs to move,
we should somehow show the requirement resolution to the admin in the UI
and the API could use a little reworking.

@mvdbeek
Copy link
Member Author

mvdbeek commented Jun 26, 2016

@bwlang might be a good idea to also include/review https://github.com/galaxyproject/galaxy/pull/2538/files

@bwlang
Copy link
Contributor

bwlang commented Jun 27, 2016

I think this is now ready for some feedback.
In my hands, it installs tools via conda.

Todo: give the user some feedback about whether the installation was successful.
not sure if we should try to do that on the tool installation status page, or on a dedicated requirements page. I see advantages to both approaches.

@bwlang
Copy link
Contributor

bwlang commented Jun 29, 2016

@mvdbeek what do you think...
ready to remove the WIP tag?

</table>
</td>
</tr>
</%def>

<%def name="render_resolver_dependency_items( resolver_dependencies )">
<%def name="render_resolver_dependencies ( resolver_dependencies )">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we remove the spaces?

@mvdbeek
Copy link
Member Author

mvdbeek commented Jul 2, 2016

There are still a few things to sort out:

  • When the dependency is resolved with the versionless resolver, there should be a warning symbol (it's green right now. We should probably also differentiate between requested requriement version and resolved requirement version)
    • There is the "CondaDepenency" typo in lib/, which is carried on into the UI
    • Toolshed packages are not shown as resolved (I think that may be in the nature of the toolshed resolver, not sure a "fix" would be simple)
    • We may be breaking the (display) of other resolver modules, we should at least test that those are working
    • A set of tests would probably be a good idea.
    • Return the resolution status through the API (Install via conda #2554 (comment))

We also discussed an overview page of all requirements ("Manage tool requirements" ?) with @jmchilton , so that the admin can see all requirements of all tools, the resolver status of these and a list of tools/repositories that depend on these requirements, but I think that would be another PR.

for requirement in tool.requirements:
if requirement.type == 'package':
reqs.append(json.dumps(requirement.to_dict()))
reqs = [json.loads(req) for req in list(set(reqs))]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need to cast to list.

@mvdbeek mvdbeek force-pushed the install_via_conda branch 2 times, most recently from 90acf71 to 7db313b Compare July 21, 2016 16:19
@jmchilton
Copy link
Member

This is amazing - what is left to do? Is there some chance to get some of this into 15.07?

@mvdbeek
Copy link
Member Author

mvdbeek commented Jul 22, 2016

Just need to fix the failing tests and rebase... Other than that it's pretty complete by now.

bwlang and others added 4 commits July 22, 2016 21:55
working:
	- fetching valid tool list
	- identifying unique requirements

not working:
	File '/Users/langhorst/src/galaxy_hackathon/lib/galaxy/webapps/galaxy/controllers/admin_toolshed.py', line 1138 in prepare_for_install
  [view.manager_dependency(req) for req in uniq_reqs.values()]
TypeError: manager_dependency() takes exactly 1 argument (2 given)
@@ -81,9 +81,9 @@ def _find_possible_depenencies(self, name, version, type):
for revision in listdir(package_path):
revision_path = join(package_path, revision)
package = self._galaxy_package_dep(revision_path, version, True)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

package = self._galaxy_package_dep(revision_path, version, name, True)


# Finds all possible dependency to use
# Should be extended as required
# Returns CandidateDepenency objects with data for preference picking
# Returns CandidateDependency objects with data for preference picking
def _find_possible_depenencies(self, name, version, type):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

s/depenencies/dependencies/

@jmchilton
Copy link
Member

jmchilton commented Jul 27, 2016

I'd like to rework some of the user-facing GUI aspects of this:

Currently the wording is something like:

  • Install resolver dependencies
  • Install repository dependencies

I'd like it to be something more like:

  • When available, install externally managed dependencies (e.g. conda) _New_
  • When available, install tool shed managed dependencies
  • Is this reasonable?
  • Should we consider this beta? If so should we move the conda stuff after the shed stuff? The argument for it being considered beta is that the logging of the install process I think is a bit worse than that of the shed dependencies right?
  • I want to get the conda checkbox to show up even if there is no tool_dependencies.xml file available. I'm going to take a crack at this.

@martenson
Copy link
Member

martenson commented Jul 27, 2016

The UI does seem a bit confusing, mostly because it has been confusing before.

Is there a reasonable scenario where you want to get both Conda and TS dependency installations? I feel like a radiobutton would be a better UI choice here. I also agree with @jmchilton that we should reword the text descriptions (like the 'un-check to skip' language)

Should we consider this beta? If so should we move the conda stuff after the shed stuff?

Yes. Yes.

@jmchilton
Copy link
Member

@martenson I don't think the admin has a way of really knowing which they want - and for a large suite the answer is probably going to be both for a while.

I've been playing around with the biom stuff - where there is no tool_dependencies.xml and I do think with a small patch I have - things are more clear than they have even been.

…able.

Also reword different install options, I hope this is more clear - I do think it exposes les of the internal language to the end user.
@martenson
Copy link
Member

martenson commented Jul 27, 2016

Also this builds on the older UI for tool installations. Would be nice to have this merged into the currently Beta API installation UI - #1392

The schedule of such is a bit tricky, I guess we continue with this PR as is and hope to port the changes to the new UI in 16.10?

@nsoranzo
Copy link
Member

Thanks @mvdbeek for fixing all my nitpicking! I leave it to @martenson and @jmchilton for more review, testing and hopefully merging!

@jmchilton
Copy link
Member

Opened a PR with some of the changes @martenson and I mentioned here: bxlab#56.

@jmchilton
Copy link
Member

I'm getting an itchy merge finger ... and other important requests before this merged? I think we can make clarifications after the merge as usability bug fixes.

@blankenberg blankenberg merged commit a731ce2 into galaxyproject:dev Jul 27, 2016
@mvdbeek
Copy link
Member Author

mvdbeek commented Jul 27, 2016

Awesome, thanks everyone!

@mvdbeek
Copy link
Member Author

mvdbeek commented Jul 27, 2016

Also this builds on the older UI for tool installations. Would be nice to have this merged into the currently Beta API installation UI - #1392

This should work for new and old, we'll just have to change the wording to that of bxlab#56
screen shot 2016-07-27 at 23 08 59

dannon added a commit that referenced this pull request Jul 28, 2016
nsoranzo added a commit to nsoranzo/galaxy that referenced this pull request Jul 29, 2016
mvdbeek added a commit to mvdbeek/galaxy that referenced this pull request Nov 4, 2016
This option was introduced with galaxyproject#2554 and galaxyproject#2538, in reponse to a false
positive conda install.  This would have been caught by simply checking
the exit code, which we are doing by default now. The additional
verification is too strigent and not in line with the conda resolver.
Activating this option will report perfectly well installed conda
environments as having failed and will cause them to be uninstalled.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants