Skip to content

better handle multiple paths to parse#4

Merged
jmwoliver merged 2 commits intomainfrom
jmw/pdp-update
Oct 27, 2023
Merged

better handle multiple paths to parse#4
jmwoliver merged 2 commits intomainfrom
jmw/pdp-update

Conversation

@jmwoliver
Copy link
Collaborator

@jmwoliver jmwoliver commented Oct 27, 2023

Description

This changes Parse(string) to Parse(...string) so that it can handle both a single path, as well as a slice of paths.

This commit also:

  • Makes PackageFile exposed externally so that it is a type that can be passed around.
  • Updates the error message when a package can't be parsed to make it more clear that it might not be a valid Python package.
  • Handles case where it was double closing the tarReader for source distributions: error closing reader: close /rstudio-pm/appdirs/dist/appdirs-1.4.4.tar.gz: file already closed

This changes Parse(string) to Parse(...string) so that it can handle
both a single path, as well as a slice of paths.

This commit also:
- Makes PackageFile exposed externally so that it is a type that
  can be passed around.
- Updates the error message when a package can't be parsed to make
  it more clear that it might not be a valid Python package.
Copy link
Contributor

@shepherdjerred shepherdjerred left a comment

Choose a reason for hiding this comment

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

looks good!

@jmwoliver jmwoliver merged commit f5c6309 into main Oct 27, 2023
@jmwoliver jmwoliver deleted the jmw/pdp-update branch October 27, 2023 21:54
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

Comments