-
Notifications
You must be signed in to change notification settings - Fork 1.8k
JSON-format activation #8727
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
JSON-format activation #8727
Conversation
@kalefranz Just a heads up to say this is the feature I discussed with you a while back. I believe this is one of the ideas you suggested and I definitely support this PR! |
This is very cool. We have really needed this for a long time. I'm going to spend some proper time reviewing this after I get the 4.7.1 release out. Thanks @necaris ! |
@jlstevens thanks for the ping about it! @msarahan y'all are very welcome! I'm looking forward to being able to use this functionality in my own editor integration ;-) By the way, I'm not wedded to any of the design decisions made in this PR so happy to change things up as you get time to review & comment. |
@necaris mind revisiting this? I think rebasing on master is a good start. 4.7.x is maintenance now, and this will be in the next feature release, 4.8. |
@msarahan yep, I'll have a look at it shortly! |
bcc2ee7
to
bd23d63
Compare
@msarahan could use a hand getting tests to pass -- I'm seeing a number of errors in the conda-build tests. The others all pass, and I'm not able to replicate the failures locally either. |
bd23d63
to
e4ddf47
Compare
@msarahan rebased this just now but still seeing test failures -- not sure what's causing them, could still use a hand figuring it out. |
@msarahan is this still of interest? |
Hey Rami, I'm moving back over from the enterprise side back to Conda for a while. Just starting as of yesterday, so need some time to ramp back up. Yes, this is still of interest. |
@kalefranz thanks! I'll rebase it against current master then, but will probably need a hand 8000 figuring out why some tests have continued to fail on CI (including code paths that I never touched 😉 ) |
Yeah I'm starting to dig into the tests now actually |
e4ddf47
to
5c4be6f
Compare
5c4be6f
to
d1de3ed
Compare
@kalefranz don't know if this is still on your radar, but I've just rebased it against current master, FYI, so it should be up to date. |
Hey @necaris, I'm taking a fresh look at this |
@mcg1969 thanks! I could never quite figure out what was causing the test failures -- would love a hand getting this across the line. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know several folks would like to see this merged, and it looks good to me. Will dig and see what tests need to be fixed
@kalefranz @chenghlee The test failures are all centered around failure to connect to the CodeCov service. Can we please work around those? The functional tests look good |
In the interest of keeping the blockers off the critical path for this I've reverted the restructuring in aef6861 -- I'll bring it back once I've had more of a chance to test things locally. |
Note that from what I can see, the AppVeyor tests are failing because |
Basically a copy of the XonshActivator tests, something to start from
This way activators for various shells can exist, but output things in JSON format!
aef6861
to
c0894ee
Compare
I've brought back the restructured dynamic activator class in c0894ee with a helper function, and correctly updated tests which were missing before. For good measure I've also rebased against upstream master. |
80c220c
to
90a0772
Compare
This adds a separate formatters map to allow JSON-format output to be dynamically mixed in to whichever base activator is used. With this, passing `shell.posix+json` to `conda` will get the PosixActivator base class as well as the `JSONFormatMixin`.
...none of which I had anything to do with, but that's rebasing for you.
90a0772
to
7e5191d
Compare
Looks like the codecov issued is fixed -- thanks! The only thing that's not passing is AppVeyor, for the same reason as noted above: not IMHO related to this PR at all. |
This is great. We're getting very close. Will see if I can merge without AppVeyor passage, but I don't want to step on any toes on the team. |
OK, I know the problem we're seeing in CI |
boom! thanks folks |
Hi there, thank you for your contribution to Conda! This pull request has been automatically locked since it has not had recent activity after it was closed. Please open a new issue or pull request if needed. |
This is to serve the use-case of tools (e.g. editors) that want to know about conda environments, and potentially even activate them for the user. Rather than attempt to parse a shell script, why not simply provide the necessary values directly in a machine-readable format?