FAQ
Cover
\
Build
\
Source
\
Bugs
\
Reference
\
Libraries
\
Tools
The bugs database has moved
here
.
Bug 1102 : Saving the project with the same name as an existing tab may delete code
Last modified: 2009-10-18 11:22
P
roject:
processing
trash
Version:
unspecified
Co
m
ponent:
android
book
core
libraries
pde
reference
tools
web
Status:
RESOLVED
Resolution:
FIXED -
Pr
i
ority:
P2
Severity:
normal
Platform
All
O
S:
All
Windows
Mac OS
Linux
Other
Reporter:
pyramind
Assigned To:
fry
Attachment
Type
Created
Size
Actions
Description
: Opened: 2008-12-13 19:57
I started to write a processing sketch. The first thing I did was opening a new tab with the
name "Magnetic" and then I wrote a class definition. At this time I had 2 tabs laid out, one
was an empty sketch_blabla tab which was created by default, and it was empty. The second
tab was the one with the name Magnetic and I wrote a class definition in it.
Then I wanted to save my project by selecting save from file menu and mistakenly gave the
name "magnetic" (with lowercase m) for the project. IDE should have warned me about a
duplicate name (you can't save with the name Magnetic because a tab with the same name
already exists) but it didn't, instead it created a folder with the name "magnetic" and did put
"Magnetic.pde" in it, then threw an error (java.lang.ArrayIndexOutOfBoundsException: 1),
deleted the sketch_blabla tab so I was left with the "Magnetic" tab with no content in it.
So it seems that the project name/tab duplicate name checker does not check for case
differences, and fails. This is Mac Os X 10.5.2 on intel, processing 1.0.1
Steps to reproduce:
* Launch processing IDE.
* Create a new tab with the name Processing (case is important)
* Write something into the new tab (not really necessary, but demonstrates how I've lost my
code :) )
* Save the project with the name processing (again case is important)
You should be left with an empty tab with the name Processing, and the saved project file
contains no data.
Additional Comment
#1 From fry 2009-10-18 11:22
Fixed for 1.0.8. The problem was that it wasn't paying attention to
changing upper and lowercase.