IML file changes for no reason

Hello-

I have a project which I develop on two separate machines- let's call them A & B. When I check-in the changes from A (to CVS), the iml file might contain a section like this:

Note that this already seems a bit wierd because the <url> element is duplicated.

Now, when I update the source on machine B, then run IDEA, it changes the IML file to this:

Note that this is semantically the same content, but the order of the tags has changed. These needless changes make the CVS experience decidedly annoying :)

I found http://intellij.net/tracker/idea/viewSCR?publicId=28380, which seems to describe this bug perfectly, but this issue is marked as "FIXED in 1141". I am using the latest released build (2250), and it's still occurring.

Any ideas, Jetbrainers?

Best Regards,

Danny

14 comments
Comment actions Permalink

Couldn't the order be fixed?


Daniel Burkes wrote:

Hello-

I have a project which I develop on two separate machines- let's call them A & B. When I check-in the changes from A (to CVS), the iml file might contain a section like this:
<containerElement type="library" level="module"> > <url>jar://$MODULE_DIR$/../../lib/commons-collections.jar!/</url> > <attribute name="method" value="1" /> > <attribute name="URI" value="/WEB-INF/lib/commons-collections.jar" /> > <url>jar://$MODULE_DIR$/../../lib/commons-collections.jar!/</url> > </containerElement> > ]]>
Note that this already seems a bit wierd because the &lt;url&gt; element is duplicated.

Now, when I update the source on machine B, then run IDEA, it changes the IML file to this:
<containerElement type="library" level="module"> > <attribute name="method" value="1" /> > <attribute name="URI" value="/WEB-INF/lib/commons-collections.jar" /> > <url>jar://$MODULE_DIR$/../../lib/commons-collections.jar!/</url> > <url>jar://$MODULE_DIR$/../../lib/commons-collections.jar!/</url> > </containerElement> > ]]>
Note that this is semantically the same content, but the order of the tags has changed. These needless changes make the CVS experience decidedly annoying :)

I found http://intellij.net/tracker/idea/viewSCR?publicId=28380, which seems to describe this bug perfectly, but this issue is marked as "FIXED in 1141". I am using the latest released build (2250), and it's still occurring.

Any ideas, Jetbrainers?

Best Regards,

Danny



--
Maxim Shafirov
JetBrains Inc.
http://www.jetbrains.com
"Develop with pleasure!"

0
Comment actions Permalink

I'm not sure that I know what you mean...fixed by whom? IDEA is rearranging the entries programatically- I'm not doing it manually.

0
Comment actions Permalink

Daniel Burkes wrote:

I'm not sure that I know what you mean...fixed by whom? IDEA is rearranging the entries programatically- I'm not doing it manually.

Sorry, that was intended to send to a developer who should fix this :)

--
Maxim Shafirov
JetBrains Inc.
http://www.jetbrains.com
"Develop with pleasure!"

0
Comment actions Permalink

I noticed that, as a side-effect of these needless changes, my web modules also sporadically lose the deployment packaging method for dependent libraries. That is, if I have a jarfile that is pulled in from a dependency, and I set that jarfile to "Copy files to", then, sometimes, after IDEA makes these needless changes to an .iml file, these jarfiles are reset to "Do not package". I think this must be related to http://www.intellij.net/tracker/idea/viewSCR?publicId=37669. By the way, I am using build 2250 and I see this happening every day. I have recreated my web modules from scratch, and the behavior still occurs.

This seems like a quite serious bug- for sure, it is driving me nuts! It's hard to believe that, if other people are experiencing this, they aren't crying bloody murder.

What say you, oh JetBrains Gods?

- Danny

0
Comment actions Permalink

Daniel, could you please remember what changes lead to the IML file
corruption ?
If you can reproduce this, it will be great.

--
regards,
Alexey Kudravtsev
Software Developer
JetBrains, Inc
http://www.jetbrains.com
"Develop with pleasure!"


"Daniel Burkes" <no_mail@jetbrains.com> wrote in message
news:17216160.1102115594504.JavaMail.itn@is.intellij.net...
>I noticed that, as a side-effect of these needless changes, my web modules
>also sporadically lose the deployment packaging method for dependent
>libraries. That is, if I have a jarfile that is pulled in from a
>dependency, and I set that jarfile to "Copy files to", then, sometimes,
>after IDEA makes these needless changes to an .iml file, these jarfiles are
>reset to "Do not package". I think this must be related to
>http://www.intellij.net/tracker/idea/viewSCR?publicId=37669. By the way, I
>am using build 2250 and I see this happening every day. I have recreated
>my web modules from scratch, and the behavior still occurs.
>

This seems like a quite serious bug- for sure, it is driving me nuts!
It's hard to believe that, if other people are experiencing this, they
aren't crying bloody murder.

>

What say you, oh JetBrains Gods?

>

- Danny



0
Comment actions Permalink

Hello Alexi-

Attached please find 2 files- ws.iml and ws.iml.new. The act of loading a project that references ws.iml will transform it into ws.iml.new - that is, IDEA makes some structural changes to the iml file without me changing any user settings.

The first undesirable effect caused by this is that CVS thinks the file has changed, and this produces needless, wasteful CVS (and Local VCS) revisions.

The second, and more serious, undesirable effect is that sometimes (but not every time), after the file has been changed by IDEA, the module looses its memory of the deployment packaging method for dependent libraries (see the message above for details).

Please let me know if I can provide any additional information to help you fix this bug- it is quite serious and definitely very annoying!

Best Regards,

Danny



Attachment(s):
ws.iml
ws.iml.orig
0
Comment actions Permalink

Sorry- I attached the wrong files (or, rather, I gave them the wrong names). Please use the files attached this this message instead.

Regards,

Danny



Attachment(s):
ws.iml
ws.iml.new
0
Comment actions Permalink

Daniel, could you please send me your whole project (or small sample project where it can be reproduced) ?
Thank you.

0
Comment actions Permalink

Attached is a zipfile with the .ipr and all associated .iml files.

Thanks-

Danny



Attachment(s):
pretrieve.zip
0
Comment actions Permalink

Many thanks, its fixed

0
Comment actions Permalink

Great! What release is it fixed in? How do I get the fix?

0
Comment actions Permalink

Next IDEA 4.5x bug fix release or Irida build 3129

0
Comment actions Permalink

Thank you- do you have any estimated release date for the next 4.5.x bug fix release?

Regards,

Danny

0
Comment actions Permalink

Do you have any estimated release date for the next 4.5.x bug fix release? This bug means that I have to manually reset the deployment methods on all my web modules every day! I can tell you, that is highly annoying!

- Danny

0

Please sign in to leave a comment.