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/flit support #270

Closed
wants to merge 11 commits into from
Closed

feat/flit support #270

wants to merge 11 commits into from

Conversation

blast-hardcheese
Copy link
Collaborator

Why

As we continue to expand into the realm of offering better Python package manager support, we're happy to add flit to upm.

What changed

  • Bump BurntSushi/toml to 1.4.0
  • Broke out python/poetry.go and python/pip.go to go along with python/flit.go
  • Fix a bug with pip requirements.txt additions where we would take a zero-byte requirements.txt and turn it into \ndep instead of dep\n
  • Adding QuirksCannotAddRemove to support flit, which does not directly support add or remove. In the future, we can or delete from pyproject.toml

Test plan

  • Import https://github.com/mwaskom/seaborn into Replit
  • Run pip install flit to get a compatible version of flit
  • Run upm install
  • Verify that dependencies are installed

@blast-hardcheese blast-hardcheese requested a review from a team as a code owner June 17, 2024 22:04
@blast-hardcheese blast-hardcheese requested review from cdmistman and removed request for a team June 17, 2024 22:04
Copy link
Contributor

Choose a reason for hiding this comment

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

🐐

@@ -267,6 +267,11 @@ func runAdd(
defer span.Finish()
b := backends.GetBackend(ctx, language)

if !b.QuirksCanAddRemove() {
fmt.Println("This backend does not suppport dependency additions")
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
fmt.Println("This backend does not suppport dependency additions")
fmt.Println("This backend does not suppport dependency addition")

nit to keep consistent with the other error message

Copy link
Contributor

@cdmistman cdmistman left a comment

Choose a reason for hiding this comment

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

integration tests please! lgtm so far though

@blast-hardcheese
Copy link
Collaborator Author

A workaround was found for flit. This work can be brought back if necessary.

@blast-hardcheese blast-hardcheese deleted the dstewart/feat/flit-support branch August 12, 2024 17:16
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