Skip to content

Development conda environment taking >45 minutes to solve #24012

Closed
@datapythonista

Description

@datapythonista

When creating a new environment from our environment.yml, it takes more than 45 minutes to solve (one of the steps of the environment creation). This happens both locally, and in the CI of #22854, which uses that file for one of the builds.

2018-11-30T03:02:59.3313236Z [create env]
2018-11-30T03:49:30.3527900Z Solving environment: ...working... done

The number of dependencies in this environment is slightly higher than in the travis jobs (it has the packages for linting and building the docs), but there are not many more.

The environment with those dependencies was creating in a reasonable time until recently (like one week ago). We just added to it couple of small changes, that if undone, don't solve the problem. I also tried to downgrade conda, to see if a new release was doing something different, but the creation of the environment also takes the same with old versions.

I did a bit of research inside conda, and seems like the time is spent in Resolve.solve, in the step of maximizing the timestamps: https://github.com/conda/conda/blob/master/conda/resolve.py#L1031

This receives all the packages candidates as a parameter if I'm not wrong, so I assume the problem comes from a release in one of our dependencies, that makes this optimization very slow. I tried to remove packages from the dependencies file to see if there is a single package that when removed fixes the problem, but after many tests I couldn't identify one, I think it's a combination of packages that causes the issue.

When running the process, one of the cores stay at 100%, confirming (I think) that it's the optimization itself what is taking long (and not a network access or other IO).

@TomAugspurger do you know what the problem can be? And what's the best way to report this to conda? I guess an issue in the conda GitHub, but not sure if there is a better way.

Metadata

Metadata

Assignees

No one assigned

    Labels

    DependenciesRequired and optional dependencies

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions