Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[Finder] Prevent unintentional file locks in Windows#33402

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
nicolas-grekas merged 1 commit intosymfony:3.4fromjspringe:4.3
Sep 1, 2019
Merged

[Finder] Prevent unintentional file locks in Windows#33402

nicolas-grekas merged 1 commit intosymfony:3.4fromjspringe:4.3
Sep 1, 2019

Conversation

@jspringe
Copy link
Contributor

@jspringejspringe commentedAug 30, 2019
edited
Loading

QA
Branch?4.3 for bug fixes
Bug fix?yes
New feature?no
BC breaks?no
Deprecations?no
Tests pass?yes
Fixed tickets#33400
LicenseMIT
Doc PR

This replaces the constructor behavior forSortableIterator. Instead of storing the sort strategy as a property, causing the object to hold references to the files being sorted and thus locking them in Windows, it uses a method to determine the sort strategy when callinggetIterator.

Change stored$sort closure to a static closure. This removes the instance context that causes the file lock. This doesn't change any intended behavior.

I, unfortunately, did not provided tests for 2 reasons. The first being that I've never written tests for the Symfony framework so I do not know the nuances.The second is that in order for the test to actually fail it would need to be run in the Windows OS. AppVeyor tests with a Windows instance, but it appears theFinder tests get skipped.

@jspringe
Copy link
ContributorAuthor

Need to rework this before submitting. My apologizes.

@jspringejspringe reopened thisAug 31, 2019
@jspringejspringe changed the titleIssue 33400: Change sort strategy to a method from a property.[Finder] [SortIterator] Issue #33400: Prevent unintentional file locks in WindowsAug 31, 2019
@jspringejspringe changed the title[Finder] [SortIterator] Issue #33400: Prevent unintentional file locks in Windows[Finder] [SortableIterator] Issue #33400: Prevent unintentional file locks in WindowsAug 31, 2019
@jspringejspringe changed the title[Finder] [SortableIterator] Issue #33400: Prevent unintentional file locks in Windows[Finder] [Iterator] [SortableIterator] Issue #33400: Prevent unintentional file locks in WindowsAug 31, 2019
@jspringe
Copy link
ContributorAuthor

AppVeyor self-cancelled.

@jspringe
Copy link
ContributorAuthor

Didn't mean to close.

@jspringejspringe reopened thisAug 31, 2019
@nicolas-grekasnicolas-grekas changed the title[Finder] [Iterator] [SortableIterator] Issue #33400: Prevent unintentional file locks in Windows[Finder] Prevent unintentional file locks in WindowsSep 1, 2019
@nicolas-grekasnicolas-grekas changed the base branch from4.3 to3.4September 1, 2019 21:32
@nicolas-grekas
Copy link
Member

Thank you@jspringe.

nicolas-grekas added a commit that referenced this pull requestSep 1, 2019
…inge)This PR was submitted for the 4.3 branch but it was squashed and merged into the 3.4 branch instead (closes#33402).Discussion----------[Finder] Prevent unintentional file locks in Windows| Q             | A| ------------- | ---| Branch?       | 4.3 for bug fixes <!-- see below -->| Bug fix?      | yes| New feature?  | no <!-- please update src/**/CHANGELOG.md files -->| BC breaks?    | no     <!-- seehttps://symfony.com/bc -->| Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->| Tests pass?   | yes <!-- please add some, will be required by reviewers -->| Fixed tickets |#33400   <!-- #-prefixed issue number(s), if any -->| License       | MIT| Doc PR        |~~This replaces the constructor behavior for `SortableIterator`. Instead of storing the sort strategy as a property, causing the object to hold references to the files being sorted and thus locking them in Windows, it uses a method to determine the sort strategy when calling `getIterator`.~~Change stored `$sort` closure to a static closure. This removes the instance context that causes the file lock. This doesn't change any intended behavior.I, unfortunately, did not provided tests for 2 reasons. The first being that I've never written tests for the Symfony framework so I do not know the nuances. ~~The second is that in order for the test to actually fail it would need to be run in the Windows OS.~~ AppVeyor tests with a Windows instance, but it appears the `Finder` tests get skipped.Commits-------997cc5c [Finder] Prevent unintentional file locks in Windows
@nicolas-grekasnicolas-grekas merged commit997cc5c intosymfony:3.4Sep 1, 2019
@nicolas-grekasnicolas-grekas added this to the3.4 milestoneSep 1, 2019
@jspringe
Copy link
ContributorAuthor

jspringe commentedSep 1, 2019
edited
Loading

Thanks for the merge! Just curious, as I am not familiar, how long does it usually take to see this change in the framework/components? Only asking because I have another issue contingent upon this change.

@nicolas-grekas
Copy link
Member

nicolas-grekas commentedSep 1, 2019 via email

We release bug fix versions at least one a month, at the end of the month.

@jspringejspringe deleted the 4.3 branchSeptember 3, 2019 13:48
This was referencedOct 7, 2019
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Projects

None yet

Milestone

3.4

Development

Successfully merging this pull request may close these issues.

3 participants

@jspringe@nicolas-grekas@carsonbot

[8]ページ先頭

©2009-2025 Movatter.jp