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

Refactor Cargo sdist generator to avoid rewriting local dependencies #1741

Merged
merged 8 commits into from Sep 1, 2023

Conversation

messense
Copy link
Member

@messense messense commented Aug 20, 2023

TODO:

  • Test on real world packages, especially the ones we had bug reports regarding sdist.
    • resvg-cli
    • polars
    • pyxel
    • ruff
    • pydantic-core
    • ast-grep
    • cryptography (cargo & git sdist generator)
    • typos-cli
    • pyoxigraph
    • geoarrow-rs

Closes #1442

@messense messense added the sdist Source distribution label Aug 20, 2023
@netlify
Copy link

netlify bot commented Aug 20, 2023

Deploy Preview for maturin-guide ready!

Name Link
🔨 Latest commit f8a38f7
🔍 Latest deploy log https://app.netlify.com/sites/maturin-guide/deploys/64f146fc773827000831036f
😎 Deploy Preview https://deploy-preview-1741--maturin-guide.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@messense messense force-pushed the refactor-sdist branch 5 times, most recently from 93b5b78 to e32493b Compare August 20, 2023 14:21
@messense

This comment was marked as outdated.

@messense

This comment was marked as outdated.

@messense

This comment was marked as outdated.

@messense messense marked this pull request as ready for review August 29, 2023 11:20
@messense messense requested a review from konstin August 29, 2023 11:22
Copy link
Member

@konstin konstin left a comment

Choose a reason for hiding this comment

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

great real world testing!

@@ -530,7 +529,7 @@ mod tests {
.skip(5)
.collect::<Vec<_>>()
.join("\n");
let expected = indoc! {r#"
let expected = expect![[r#"
Copy link
Member

Choose a reason for hiding this comment

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

what's the advantage of expect-test over assert_eq with indoc

Copy link
Member Author

Choose a reason for hiding this comment

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

expect-test can update the expected result automatically by re-run with UPDATE_EXPECT=1, it's basically an inline snapshot testing tool.

src/source_distribution.rs Outdated Show resolved Hide resolved
src/source_distribution.rs Show resolved Hide resolved
src/source_distribution.rs Show resolved Hide resolved
src/source_distribution.rs Show resolved Hide resolved
src/source_distribution.rs Show resolved Hide resolved
src/source_distribution.rs Outdated Show resolved Hide resolved
src/source_distribution.rs Outdated Show resolved Hide resolved
src/source_distribution.rs Show resolved Hide resolved
@messense messense added this pull request to the merge queue Sep 1, 2023
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Sep 1, 2023
@messense messense merged commit 4f642df into PyO3:main Sep 1, 2023
31 of 32 checks passed
@messense messense deleted the refactor-sdist branch September 1, 2023 04:20
@messense messense linked an issue Sep 5, 2023 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
sdist Source distribution
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Path dependencies doesn't work with --locked/--frozen options cargo package --list issue with relative path
2 participants