jira.codehaus.org

  • Log In Access more options
    • Online Help
    • Keyboard Shortcuts
    • About JIRA
    • JIRA Credits
    • What?s New
  • Dashboards Access more options (Alt+d)
  • Projects Access more options (Alt+p)
  • Issues Access more options (Alt+i)
  • Maven 2.x Release Plugin
  • MRELEASE-221

XML header missing in modified POM after release:prepare

  • Log In
  • Views
    • XML
    • Word
    • Printable

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 2.0-beta-5
  • Fix Version/s: 2.0-beta-8
  • Component/s: None
  • Labels:
    None
  • Environment:
    Windows XP, CVSNT, Eclipse

Description

When release plugin modifies the POM to prepare a new release,
the new file does not containt the XML header
<?xml version="1.0" encoding="ISO-8859-1"?>

it cause problems with XML editors who ignore the encoding and breaks all unusual characters.
some XML tools also don't accept XML files without headers...

Issue Links

is duplicated by

Bug - A problem which impairs or prevents the functions of the product. MRELEASE-351 xml declaration removed on release

  • Major - Major loss of function.
  • Closed - The issue is considered finished, the resolution is correct. Issues which are not closed can be reopened.
relates to

Bug - A problem which impairs or prevents the functions of the product. MRELEASE-223 Generated pom.xml has invalid chars (does not correctly handle xml entities)

  • Major - Major loss of function.
  • Closed - The issue is considered finished, the resolution is correct. Issues which are not closed can be reopened.

Bug - A problem which impairs or prevents the functions of the product. MRELEASE-255 during a release several elements are removed from the pom.xml (which should be left there)

  • Major - Major loss of function.
  • Closed - The issue is considered finished, the resolution is correct. Issues which are not closed can be reopened.

Activity

Ascending order - Click to sort in descending order
  • All
  • Comments
  • Work Log
  • History
  • Activity
Hide
Permalink
Emmanuel Venisse added a comment - 26/Apr/07 4:25 AM

The xml header is in the POM

Show
Emmanuel Venisse added a comment - 26/Apr/07 4:25 AM The xml header is in the POM
Hide
Permalink
Alain Coetmeur added a comment - 26/Apr/07 12:43 PM

Hum...
I've checked (latest snapshot) , I can repeat the problem
pom.xml starts with:
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>

maybe is it related to another problems,

my release:prepare is interupted after the compilation of the project
( completedPhase=run-preparation-goals )

with a message before the checkin :An error is occurred in the checkin process: C:\Developpement\MavenWork\FWK DEI Module Trace Manager\pom.xml was not contained in C:\Developpement\MavenWork\FWK DEI Maven All

this is because I use sibling module instead of sub directories... (another problem)...
anyway it seems to happens at a moment the plugin wand to commit all.

I use JDK1.6.0-b2, and maybe is it an XML problem...

message at the end of the prepare ...

[INFO] BUILD SUCCESSFUL
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1 minute 23 seconds
[INFO] Finished at: Thu Apr 26 19:16:06 CEST 2007
[INFO] Final Memory: 19M/61M
[INFO] ------------------------------------------------------------------------
[INFO] Checking in modified POMs...
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] An error is occurred in the checkin process: C:\Developpement\MavenWork\FWK DEI Module Trace Manager\pom.xml was not contained in C:\Developpement\MavenWork\FWK DEI Maven All

Show
Alain Coetmeur added a comment - 26/Apr/07 12:43 PM Hum... I've checked (latest snapshot) , I can repeat the problem pom.xml starts with: <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> <modelVersion>4.0.0</modelVersion> maybe is it related to another problems, my release:prepare is interupted after the compilation of the project ( completedPhase=run-preparation-goals ) with a message before the checkin :An error is occurred in the checkin process: C:\Developpement\MavenWork\FWK DEI Module Trace Manager\pom.xml was not contained in C:\Developpement\MavenWork\FWK DEI Maven All this is because I use sibling module instead of sub directories... (another problem)... anyway it seems to happens at a moment the plugin wand to commit all. I use JDK1.6.0-b2, and maybe is it an XML problem... message at the end of the prepare ... [INFO] BUILD SUCCESSFUL [INFO] ------------------------------------------------------------------------ [INFO] Total time: 1 minute 23 seconds [INFO] Finished at: Thu Apr 26 19:16:06 CEST 2007 [INFO] Final Memory: 19M/61M [INFO] ------------------------------------------------------------------------ [INFO] Checking in modified POMs... [INFO] ------------------------------------------------------------------------ [ERROR] BUILD ERROR [INFO] ------------------------------------------------------------------------ [INFO] An error is occurred in the checkin process: C:\Developpement\MavenWork\FWK DEI Module Trace Manager\pom.xml was not contained in C:\Developpement\MavenWork\FWK DEI Maven All
Hide
Permalink
ol added a comment - 07/Sep/07 4:06 AM - edited

This issue is not resolved.
Please reopen it.

The XML header was present before the release:prepare and is missing in the release version and in the next development version.

Show
ol added a comment - 07/Sep/07 4:06 AM - edited This issue is not resolved. Please reopen it. The XML header was present before the release:prepare and is missing in the release version and in the next development version.
Hide
Permalink
Benjamin Bentmann added a comment - 23/May/08 7:06 AM

This was indeed reproducible: MRELEASE-254.

The problem is that the XML declaration and anything else outside of the root element depend on a fragile detection algo using indexOf() on the serialized DOM. If this detection fails, the stuff is simply dropped from the resulting POM.

Show
Benjamin Bentmann added a comment - 23/May/08 7:06 AM This was indeed reproducible: MRELEASE-254. The problem is that the XML declaration and anything else outside of the root element depend on a fragile detection algo using indexOf() on the serialized DOM. If this detection fails, the stuff is simply dropped from the resulting POM.
Hide
Permalink
Benjamin Bentmann added a comment - 23/May/08 12:38 PM

Fixed in r659603.

Show
Benjamin Bentmann added a comment - 23/May/08 12:38 PM Fixed in r659603.
Hide
Permalink
Benjamin Bentmann added a comment - 09/Aug/08 6:00 AM

Fixed initial solution in r684220, snapshot deployed.

Show
Benjamin Bentmann added a comment - 09/Aug/08 6:00 AM Fixed initial solution in r684220, snapshot deployed.

People

  • Assignee:
    Benjamin Bentmann
    Reporter:
    Alain Coetmeur
Vote (0)
Watch (1)

Dates

  • Created:
    25/Apr/07 12:15 PM
    Updated:
    09/Aug/08 6:00 AM
    Resolved:
    23/May/08 12:38 PM
  • Atlassian JIRA (v5.0.4#731-sha1:3aa7374)
  • Report a problem
  • Powered by a free Atlassian JIRA open source license for Codehaus. Try JIRA - bug tracking software for your team.