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 Integration for Eclipse
  • MNGECLIPSE-1164

NullPointerException when using external maven installation with no user settings

  • Log In
  • Views
    • XML
    • Word
    • Printable

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Minor Minor
  • Resolution: Fixed
  • Affects Version/s: dev
  • Fix Version/s: 0.9.7
  • Component/s: None
  • Labels:
    None

Description

Hi,

In our company, every developer share the same maven installation with the right settings.xml configured to access our maven repository manager. So, no one should ever have any ~/.m2/settings.xml file.
To reproduce the problem:

  1. add an external "maven installation"
  2. the global settings.xml file is automatically selected
  3. set the "user settings" field to blank
  4. Click OK

Then a popup shows up, displaying "Problem Occurred" with the following message:

'Invalidating Maven settings' has encountered a problem.
An internal error occurred during: "Invalidating Maven settings".".

In the Details part of the popup, there's the following text:

An internal error occurred during: "Invalidating Maven settings".
java.lang.NullPointerException

In the .log file, there's the following stack trace:
monospaced
!ENTRY org.eclipse.core.jobs 4 2 2009-01-19 11:27:48.345
!MESSAGE An internal error occurred during: "Invalidating Maven settings".
!STACK 0
java.lang.NullPointerException
at org.eclipse.core.internal.preferences.EclipsePreferences.put(EclipsePreferences.java:758)
at org.eclipse.ui.preferences.ScopedPreferenceStore.setValue(ScopedPreferenceStore.java:789)
at org.maven.ide.eclipse.embedder.MavenRuntimeManager.setUserSettingsFile(MavenRuntimeManager.java:237)
at org.maven.ide.eclipse.ui.internal.preferences.MavenInstallationsPreferencePage$1.run(MavenInstallationsPreferencePage.java:146)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
monospaced

The workaround for this is to just copy the "global settings" field content into the "user settings" field.

Cheers.

Issue Links

is related to

Improvement - An improvement or enhancement to an existing feature or task. MNGECLIPSE-1202 M2E should not automatically replace blank user settings field with $HOME/.m2/settings.xml value

  • Trivial - Cosmetic problem like misspelt words or misaligned text.
  • Open - The issue is open and ready for the assignee to start work on it.

Activity

  • All
  • Comments
  • Work Log
  • History
  • Activity
Hide
Permalink
Eugene Kuleshov added a comment - 19/Jan/09 12:57 PM

Committed fix to trunk.
Please note that the blank user settings field does not correspond to the same value as global setting field. The default is <user home>/.m2/settings.xml and on windows it is usually is at C:\Documents and Settings\<user name>\.m2\settings.xml

Show
Eugene Kuleshov added a comment - 19/Jan/09 12:57 PM Committed fix to trunk. Please note that the blank user settings field does not correspond to the same value as global setting field. The default is <user home>/.m2/settings.xml and on windows it is usually is at C:\Documents and Settings\<user name>\.m2\settings.xml

People

  • Assignee:
    Eugene Kuleshov
    Reporter:
    Baptiste MATHUS
Vote (0)
Watch (0)

Dates

  • Created:
    19/Jan/09 4:29 AM
    Updated:
    17/Feb/09 7:11 AM
    Resolved:
    19/Jan/09 12:57 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.