This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 17570 - Renaming a file object to an existing file object yields an IllegalArgumentException.
Summary: Renaming a file object to an existing file object yields an IllegalArgumentEx...
Status: CLOSED DUPLICATE of bug 11681
Alias: None
Product: platform
Classification: Unclassified
Component: Explorer (show other bugs)
Version: 3.x
Hardware: All All
: P1 blocker (vote)
Assignee: David Strupl
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2001-11-12 18:50 UTC by Paul Stremel
Modified: 2008-12-22 19:33 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Paul Stremel 2001-11-12 18:50:57 UTC
Renaming a file object in the explorer to an existing file object results in 
the stack trace shown below. The renaming error is reproducible.  This can be 
demonstrated for the creation/renaming of two text files: 1) Create a text file 
called “test”. 2) Try to create another text file called “test”, Template 
Wizard will not allow “test”, use “test1”.  3) Go to explorer and 
rename “test1” to “test”.  Following stack trace results.  Shouldn’t the ide 
search for a unique name and complete the rename?

Mon Nov 12 10:41:37 PST 2001: org.openide.filesystems.FSException: null
Annotation: The new name is in a bad format; cannot rename test1.
Nested annotation: Cannot rename file nbTest/test1.txt in 
D:\netBeans\netBeansFiles to nbTest/test.txt.
java.lang.IllegalArgumentException
        at org.openide.loaders.DataNode.setName(DataNode.java:124)
        at org.openide.loaders.DataNode.setName(DataNode.java:135)
        at org.openide.nodes.FilterNode.setName(FilterNode.java:219)
        at org.openide.actions.RenameAction.performAction(RenameAction.java:73)
        at org.openide.util.actions.NodeAction.performAction(NodeAction.java:92)
        at org.openide.util.actions.NodeAction.actionPerformed
(NodeAction.java:83)
        at org.netbeans.core.ModuleActions$1.run(ModuleActions.java:76)
        at org.openide.util.Task.run(Task.java:124)
[catch] at org.openide.util.RequestProcessor$ProcessorThread.run
(RequestProcessor.java:626)
 
Mon Nov 12 10:41:37 PST 2001: org.openide.filesystems.FSException:  Cannot 
rename file nbTest/test1.txt in D:\netBeans\netBeansFiles to nbTest/test.txt.
org.openide.filesystems.FSException: Cannot rename file nbTest/test1.txt in 
D:\netBeans\netBeansFiles to nbTest/test.txt.
        at org.openide.filesystems.FSException.io(FSException.java:78)
        at org.openide.filesystems.LocalFileSystem.rename
(LocalFileSystem.java:260)
        at org.openide.filesystems.LocalFileSystem$Impl.rename
(LocalFileSystem.java:587)
        at org.openide.filesystems.AbstractFileObject.rename
(AbstractFileObject.java:415)
        at org.openide.loaders.FileEntry.rename(FileEntry.java:59)
        at org.openide.loaders.MultiDataObject.handleRename
(MultiDataObject.java:382)
        at org.openide.loaders.DataObject$4.run(DataObject.java:544)
        at org.openide.filesystems.EventControl.runAtomicAction
(EventControl.java:69)
        at org.openide.filesystems.FileSystem.runAtomicAction
(FileSystem.java:366)
        at org.openide.loaders.DataObject.rename(DataObject.java:542)
        at org.openide.loaders.DataNode.setName(DataNode.java:118)
        at org.openide.loaders.DataNode.setName(DataNode.java:135)
        at org.openide.nodes.FilterNode.setName(FilterNode.java:219)
        at org.openide.actions.RenameAction.performAction(RenameAction.java:73)
        at org.openide.util.actions.NodeAction.performAction(NodeAction.java:92)
        at org.openide.util.actions.NodeAction.actionPerformed
(NodeAction.java:83)
        at org.netbeans.core.ModuleActions$1.run(ModuleActions.java:76)
        at org.openide.util.Task.run(Task.java:124)
[catch] at org.openide.util.RequestProcessor$ProcessorThread.run
(RequestProcessor.java:626)
Comment 1 Marian Mirilovic 2001-11-13 09:41:12 UTC
Platform/OS independent problem.

In [nb_dev](20011113) seems to work. If you rename file object to an
existing one, IDE inform you about impossibility renamed it. Exception
is logged only to log file .


*** This issue has been marked as a duplicate of 11681 ***
Comment 2 Quality Engineering 2003-07-01 15:51:53 UTC
Resolved for 3.4.x or earlier, no new info since then -> verified
Comment 3 Quality Engineering 2003-07-01 16:12:20 UTC
Resolved for 3.4.x or earlier, no new info since then -> closing.