determine build root?

0 views
Skip to first unread message

Alex Samuel

unread,
Dec 28, 2016, 7:40:06 PM12/28/16
to conda - Public
Hi,

Is there a way to ask conda its build root? I don't see it in the output of "conda info" and there's no mention of it in conda-api. I can fish it out of conda.base.context.context.local_build_root, but I think that's not a public API, and besides it's only available in a root environment, not in any other environment.

Anywhere else I should look? Or does this belong in "conda info"? (Or perhaps "conda info --json"?)

Thanks,
Alex


Michael Sarahan

unread,
Dec 28, 2016, 7:49:12 PM12/28/16
to Alex Samuel, conda - Public
I think this is really a conda build property.  In conda build's API, you can create a Config() instance and get its croot attribute.

import conda_build.api as api 
api.Config().croot

--
You received this message because you are subscribed to the Google Groups "conda - Public" group.
To unsubscribe from this group and stop receiving emails from it, send an email to conda+un...@continuum.io.
To post to this group, send email to co...@continuum.io.
Visit this group at https://groups.google.com/a/continuum.io/group/conda/.
To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/conda/CA%2Bx6cyBUkrXhf6Fo7F7h%2By5fJO9-xdB%3DqGaR7PT3Q6PZYC%3DejA%40mail.gmail.com.
For more options, visit https://groups.google.com/a/continuum.io/d/optout.

Alex Samuel

unread,
Dec 29, 2016, 11:17:24 AM12/29/16
to Michael Sarahan, conda - Public
Ah, thanks, that's nicer.

I still have the problem that this is not available in non-root environments, though; "conda build" works, because the root's bin/ directory is still in the $PATH after I activate. This seems inconsistent to me? If I can "conda build", shouldn't there be a way to get the build root?


Reply all
Reply to author
Forward
0 new messages