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
8227257: javax/swing/JFileChooser/4847375/bug4847375.java fails with AssertionError #11789
Conversation
👋 Welcome back serb! A progress list of the required criteria for merging this PR into |
Webrevs
|
So, to reproduce this issue, one has to put a shortcut ( Is my understanding correct? |
The user should actually open that 'place in Control Panel" first so the link will have appeared in the "recent files" folder, the exception occurs when the JFC tries to build a "files tree". This is how I get the lnk file for the test. |
What do people mean by Control Panel ? Do you mean Windows (File) Explorer ? |
I mean the classical Control Panel that's launched in Windows Explorer as opposed to the modern Settings app. A shortcut, From the linked email, I infer there's If I understand @mrserb's scenario where he reproduced the problem, one of the folders (Recent) contained a shortcut which has the same or similar properties: the File Explorer can navigate to the object to which the shortcut points, yet JFileChooser can't because it shows and navigates file system objects object. A |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indeed, this resolves the problem. And I reproduced the original issue with AssertionError
by running bug4847375.java
with enabled assertions.
You're right, the Recent folder contains a handful of link files which point to the new Setting app which use ms-settings:
protocol, File Explorer displays the target location as "The Internet"
.
@mrserb This change now passes all automated pre-integration checks. ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details. After integration, the commit message for the final commit will be:
You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed. At the time when this comment was updated there had been 133 new commits pushed to the
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details. ➡️ To integrate this PR with the above commit message to the |
By the way, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks Good to me.
/integrate |
Going to push as commit 78b1686.
Your commit was automatically rebased without conflicts. |
This assertion happens when we try to build the path linked by the shortcut file when part of that path is not accessible. For example, if the ".lnk" file is pointed to the "windows-update. settings" inside the "Internet.settings".
After the change, we will skip the target of the link if any part of the path to the target is not a folder and is not traversable in JFileChooser.
Progress
Issue
Reviewers
Reviewing
Using
git
Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk pull/11789/head:pull/11789
$ git checkout pull/11789
Update a local copy of the PR:
$ git checkout pull/11789
$ git pull https://git.openjdk.org/jdk pull/11789/head
Using Skara CLI tools
Checkout this PR locally:
$ git pr checkout 11789
View PR using the GUI difftool:
$ git pr show -t 11789
Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/11789.diff