Skip to content

Conversation

@hacknus
Copy link

@hacknus hacknus commented Nov 23, 2024

This PR addresses #133399 .
This adaptation leads to Path::file_steam() no longer treating directories with dots in the name as files with extensions.

@rustbot
Copy link
Collaborator

rustbot commented Nov 23, 2024

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @joboet (or someone else) some time within the next two weeks.

Please see the contribution instructions for more information. Namely, in order to ensure the minimum review times lag, PR authors and assigned reviewers should ensure that the review label (S-waiting-on-review and S-waiting-on-author) stays updated, invoking these commands when appropriate:

  • @rustbot author: the review is finished, PR author should check the comments and take action accordingly
  • @rustbot review: the author is ready for a review, this PR will be queued again in the reviewer's queue

@rustbot
Copy link
Collaborator

rustbot commented Nov 23, 2024

⚠️ Warning ⚠️

  • Pull requests are usually filed against the master branch for this repo, but this one is against stable. Please double check that you specified the right target!

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue. labels Nov 23, 2024
@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@hacknus hacknus changed the base branch from stable to master November 23, 2024 22:43
@bors
Copy link
Collaborator

bors commented Nov 23, 2024

☔ The latest upstream changes made this pull request unmergeable. Please resolve the merge conflicts.

@hacknus hacknus force-pushed the file_stem-for-directories branch from 2d708a8 to 7134cc7 Compare November 23, 2024 22:47
@kadiwa4
Copy link
Contributor

kadiwa4 commented Nov 24, 2024

Consider adding a new separate feature with these semantics instead; you can't change the behavior of a stable library feature in a backwards-incompatible way.

There are certainly situations where it is useful to think of directories as having extensions, e.g. *.app/*.bundle/*.framework directories on macOS. So there is probably someone out there who relies on this "quirk" of the function.
Also, this function was previously thought of as a function that only acts on the path and not your filesystem. For example users can assume that it has the same behavior regardless of your current working directory. Just because there is a file/dir at the specified path doesn't mean that that's the same file/dir that the user meant.

@hacknus hacknus marked this pull request as draft November 24, 2024 12:36
@joboet
Copy link
Member

joboet commented Jan 3, 2025

As indicated above, this would be a breaking change – we can't do those (at least on this scale) in std, so I'll close this PR. Please feel free to propose a different API for this by opening an ACP.

@joboet joboet closed this Jan 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants