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

feat: improve error and feedback when target does not exist #1961

Merged

Conversation

tdejager
Copy link
Contributor

@tdejager tdejager commented Sep 2, 2024

Fixes issue: #1928

Even though what was happening there was intended behavior, there was an expect and just general unclearness. Although I feel the UX could be improved further, this improves the feedback at least. Now giving you the error:

pixd remove flask --platform linux-64                                                                                                                                                                                                                                                                  ─╯
  × failed to remove dependency
  ╰─▶ No target for feature `default` found on platform `linux-64`
  help: Expected target for `default`, e.g.: `[target.linux-64.dependencies]

Given this toml:

[project]
name = "bug"
channels = ["conda-forge"]
platforms = ["linux-64"]

[dependencies]
flask = ">=3.0.3,<4"

When calling the equivalent command from the issue. This should be enough to improve the situation for now I think.

Copy link
Contributor

@nichmor nichmor left a comment

Choose a reason for hiding this comment

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

super nice!

crates/pixi_manifest/src/manifest.rs Show resolved Hide resolved
src/cli/remove.rs Outdated Show resolved Hide resolved
src/cli/remove.rs Outdated Show resolved Hide resolved
@tdejager tdejager merged commit bdc7697 into prefix-dev:main Sep 6, 2024
28 checks passed
@tdejager tdejager deleted the feat/better-error-remove-from-target branch September 6, 2024 13:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants