Skip to content
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

fix: Correct mamba env export --json --from-history #3590

Merged
merged 4 commits into from
Nov 12, 2024

Conversation

mathbunnyru
Copy link
Contributor

@mathbunnyru mathbunnyru commented Nov 8, 2024

Fix: #3582

@jjerphan jjerphan changed the title Print valid json on mamba env export --json --from-history fix: Correct mamba env export --json --from-history Nov 12, 2024
@jjerphan jjerphan added the release::bug_fixes For PRs fixing bugs label Nov 12, 2024
Copy link
Member

@jjerphan jjerphan left a comment

Choose a reason for hiding this comment

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

Thank you for this contribution, @mathbunnyru.

Could you add a non-regression test?

micromamba/src/env.cpp Outdated Show resolved Hide resolved
output = helpers.run_env("export", "-n", export_env, "--from-history", *flags)

# json is already parsed
ret = output if json_flag else yaml.safe_load(output)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@jjerphan I added a test and checked this line fails in the current main and this tests passes in my branch

Copy link
Member

@jjerphan jjerphan left a comment

Choose a reason for hiding this comment

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

LGTM given 🟢 CI checks.

@jjerphan jjerphan merged commit 4535562 into mamba-org:main Nov 12, 2024
26 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release::bug_fixes For PRs fixing bugs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

mamba env export --json --from-history is broken in v2
2 participants