Modify

Opened 7 months ago

Closed 7 months ago

#23766 closed defect (duplicate)

Cannot enter OAuth access token

Reported by: im@… Owned by: team
Priority: normal Milestone:
Component: Core Version:
Keywords: template_report Cc:

Description

What steps will reproduce the problem?

  1. "OSM Server URL" is "https://opengeofiction.net/api"
  2. Fill out advanced OAuth parameters, namely client ID and secret; the rest is similar to the default values (n.b. JOSM doesn't seem to save it, as "Authorize now (Fully automatic)" does not become enabled; if I try to close settings, it does get enabled but an empty client ID will be sent)
  3. "Authorize now (Manual)"
  4. Paste an access token that I have manually obtained from the same application

What is the expected result?

Allow me to test access token

What happens instead?

Following error

Please provide any additional information below. Attach a screenshot if possible.

Revision:19096
Build-Date:2024-06-04 11:25:36

Identification: JOSM/1.5 (19096 en) Mac OS X 14.5
OS Build number: macOS 14.5 (23F79)
Memory Usage: 369 MB / 2048 MB (163 MB allocated, but free)
Java version: 21.0.3+9-LTS, Azul Systems, Inc., OpenJDK 64-Bit Server VM
Look and Feel: com.apple.laf.AquaLookAndFeel
Screen: Display 1 1470×956 (scaling 2.00×2.00)
Maximum Screen Size: 1470×956
Best cursor sizes: 16×16→16×16, 32×32→32×32
System property file.encoding: UTF-8
System property sun.jnu.encoding: UTF-8
Locale info: en_CA
Numbers with default locale: 1234567890 -> 1234567890
VM arguments: [-Djpackage.app-version=19096, --add-modules=java.scripting,java.sql,javafx.controls,javafx.media,javafx.swing,javafx.web, --add-exports=java.base/sun.security.action=ALL-UNNAMED, --add-exports=java.desktop/com.apple.eawt=ALL-UNNAMED, --add-exports=java.desktop/com.sun.imageio.plugins.jpeg=ALL-UNNAMED, --add-exports=java.desktop/com.sun.imageio.spi=ALL-UNNAMED, --add-opens=java.base/java.lang=ALL-UNNAMED, --add-opens=java.base/java.nio=ALL-UNNAMED, --add-opens=java.base/jdk.internal.loader=ALL-UNNAMED, --add-opens=java.base/jdk.internal.ref=ALL-UNNAMED, --add-opens=java.desktop/javax.imageio.spi=ALL-UNNAMED, --add-opens=java.desktop/javax.swing.text.html=ALL-UNNAMED, --add-opens=java.prefs/java.util.prefs=ALL-UNNAMED, -Djpackage.app-path=/Applications/JOSM.app/Contents/MacOS/JOSM]

Last errors/warnings:
- 00062.753 E: Handled by bug report queue: jakarta.json.stream.JsonParsingException: Unexpected char 84 at (line no=1, column no=39, offset=38)

OSM API: https://opengeofiction.net/api


=== REPORTED CRASH DATA ===
BugReportExceptionHandler#handleException:
No data collected.

Warning issued by: BugReportExceptionHandler#handleException

=== STACK TRACE ===
Thread: AWT-EventQueue-0 (37) of main
jakarta.json.stream.JsonParsingException: Unexpected char 84 at (line no=1, column no=39, offset=38)
	at org.eclipse.parsson.JsonTokenizer.unexpectedChar(JsonTokenizer.java:593)
	at org.eclipse.parsson.JsonTokenizer.nextToken(JsonTokenizer.java:395)
	at org.eclipse.parsson.JsonParserImpl$ObjectContext.getNextEvent(JsonParserImpl.java:517)
	at org.eclipse.parsson.JsonParserImpl.next(JsonParserImpl.java:360)
	at org.eclipse.parsson.JsonParserImpl.getObject(JsonParserImpl.java:324)
	at org.eclipse.parsson.JsonParserImpl.getObject(JsonParserImpl.java:146)
	at org.eclipse.parsson.JsonReaderImpl.read(JsonReaderImpl.java:67)
	at org.openstreetmap.josm.data.oauth.OAuth20Token.<init>(OAuth20Token.java:57)
	at org.openstreetmap.josm.data.oauth.OAuth20Token.<init>(OAuth20Token.java:51)
	at org.openstreetmap.josm.gui.oauth.ManualAuthorizationUI$AccessTokenBuilder.build(ManualAuthorizationUI.java:196)
	at org.openstreetmap.josm.gui.oauth.ManualAuthorizationUI$AccessTokenBuilder.insertUpdate(ManualAuthorizationUI.java:210)
	at java.desktop/javax.swing.text.AbstractDocument.fireInsertUpdate(Unknown Source)
	at java.desktop/javax.swing.text.AbstractDocument.handleInsertString(Unknown Source)
	at java.desktop/javax.swing.text.AbstractDocument.insertString(Unknown Source)
	at java.desktop/javax.swing.text.PlainDocument.insertString(Unknown Source)
	at java.desktop/javax.swing.text.AbstractDocument.replace(Unknown Source)
	at java.desktop/javax.swing.text.JTextComponent.replaceSelection(Unknown Source)
	at java.desktop/javax.swing.plaf.basic.BasicTextUI$TextTransferHandler.handleReaderImport(Unknown Source)
	at java.desktop/javax.swing.plaf.basic.BasicTextUI$TextTransferHandler.importData(Unknown Source)
	at java.desktop/javax.swing.TransferHandler.importData(Unknown Source)
	at java.desktop/javax.swing.plaf.basic.BasicTextUI$TextTransferHandler.importData(Unknown Source)
	at java.desktop/javax.swing.TransferHandler$TransferAction.actionPerformedImpl(Unknown Source)
	at java.desktop/javax.swing.TransferHandler$TransferAction$1.run(Unknown Source)
	at java.desktop/javax.swing.TransferHandler$TransferAction$1.run(Unknown Source)
	at java.base/java.security.AccessController.doPrivileged(Unknown Source)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.desktop/javax.swing.TransferHandler$TransferAction$2.run(Unknown Source)
	at java.desktop/javax.swing.TransferHandler$TransferAction$2.run(Unknown Source)
	at java.base/java.security.AccessController.doPrivileged(Unknown Source)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.desktop/javax.swing.TransferHandler$TransferAction.actionPerformed(Unknown Source)
	at org.openstreetmap.josm.gui.widgets.JosmPasswordField$1.actionPerformed(JosmPasswordField.java:130)
	at java.desktop/javax.swing.text.JTextComponent.invokeAction(Unknown Source)
	at java.desktop/javax.swing.text.JTextComponent.paste(Unknown Source)
	at java.desktop/javax.swing.text.DefaultEditorKit$PasteAction.actionPerformed(Unknown Source)
	at java.desktop/javax.swing.SwingUtilities.notifyAction(Unknown Source)
	at java.desktop/javax.swing.JComponent.processKeyBinding(Unknown Source)
	at java.desktop/javax.swing.JComponent.processKeyBindings(Unknown Source)
	at java.desktop/javax.swing.JComponent.processKeyEvent(Unknown Source)
	at java.desktop/java.awt.Component.processEvent(Unknown Source)
	at java.desktop/java.awt.Container.processEvent(Unknown Source)
	at java.desktop/java.awt.Component.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.Component.dispatchEvent(Unknown Source)
	at java.desktop/java.awt.KeyboardFocusManager.redispatchEvent(Unknown Source)
	at java.desktop/java.awt.DefaultKeyboardFocusManager.dispatchKeyEvent(Unknown Source)
	at java.desktop/java.awt.DefaultKeyboardFocusManager.preDispatchKeyEvent(Unknown Source)
	at java.desktop/java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(Unknown Source)
	at java.desktop/java.awt.DefaultKeyboardFocusManager.dispatchEvent(Unknown Source)
	at java.desktop/java.awt.Component.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.Window.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.Component.dispatchEvent(Unknown Source)
	at java.desktop/java.awt.EventQueue.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.EventQueue$4.run(Unknown Source)
	at java.desktop/java.awt.EventQueue$4.run(Unknown Source)
	at java.base/java.security.AccessController.doPrivileged(Unknown Source)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.desktop/java.awt.EventQueue$5.run(Unknown Source)
	at java.desktop/java.awt.EventQueue$5.run(Unknown Source)
	at java.base/java.security.AccessController.doPrivileged(Unknown Source)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.desktop/java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.desktop/java.awt.WaitDispatchSupport$2.run(Unknown Source)
	at java.desktop/java.awt.WaitDispatchSupport$4.run(Unknown Source)
	at java.desktop/java.awt.WaitDispatchSupport$4.run(Unknown Source)
	at java.base/java.security.AccessController.doPrivileged(Unknown Source)
	at java.desktop/java.awt.WaitDispatchSupport.enter(Unknown Source)
	at java.desktop/java.awt.Dialog.show(Unknown Source)
	at java.desktop/java.awt.Component.show(Unknown Source)
	at java.desktop/java.awt.Component.setVisible(Unknown Source)
	at java.desktop/java.awt.Window.setVisible(Unknown Source)
	at java.desktop/java.awt.Dialog.setVisible(Unknown Source)
	at org.openstreetmap.josm.gui.oauth.OAuthAuthorizationWizard.setVisible(OAuthAuthorizationWizard.java:353)
	at org.openstreetmap.josm.gui.oauth.OAuthAuthorizationWizard.showDialog(OAuthAuthorizationWizard.java:89)
	at org.openstreetmap.josm.gui.preferences.server.OAuthAuthenticationPreferencesPanel$AuthoriseNowAction.actionPerformed(OAuthAuthenticationPreferencesPanel.java:353)
	at java.desktop/javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
	at java.desktop/javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
	at java.desktop/javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
	at java.desktop/javax.swing.DefaultButtonModel.setPressed(Unknown Source)
	at java.desktop/javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
	at java.desktop/java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
	at java.desktop/java.awt.Component.processMouseEvent(Unknown Source)
	at java.desktop/javax.swing.JComponent.processMouseEvent(Unknown Source)
	at java.desktop/java.awt.Component.processEvent(Unknown Source)
	at java.desktop/java.awt.Container.processEvent(Unknown Source)
	at java.desktop/java.awt.Component.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.Component.dispatchEvent(Unknown Source)
	at java.desktop/java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
	at java.desktop/java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
	at java.desktop/java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
	at java.desktop/java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.Window.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.Component.dispatchEvent(Unknown Source)
	at java.desktop/java.awt.EventQueue.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.EventQueue$4.run(Unknown Source)
	at java.desktop/java.awt.EventQueue$4.run(Unknown Source)
	at java.base/java.security.AccessController.doPrivileged(Unknown Source)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.desktop/java.awt.EventQueue$5.run(Unknown Source)
	at java.desktop/java.awt.EventQueue$5.run(Unknown Source)
	at java.base/java.security.AccessController.doPrivileged(Unknown Source)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.desktop/java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.desktop/java.awt.WaitDispatchSupport$2.run(Unknown Source)
	at java.desktop/java.awt.WaitDispatchSupport$4.run(Unknown Source)
	at java.desktop/java.awt.WaitDispatchSupport$4.run(Unknown Source)
	at java.base/java.security.AccessController.doPrivileged(Unknown Source)
	at java.desktop/java.awt.WaitDispatchSupport.enter(Unknown Source)
	at java.desktop/java.awt.Dialog.show(Unknown Source)
	at java.desktop/java.awt.Component.show(Unknown Source)
	at java.desktop/java.awt.Component.setVisible(Unknown Source)
	at java.desktop/java.awt.Window.setVisible(Unknown Source)
	at java.desktop/java.awt.Dialog.setVisible(Unknown Source)
	at org.openstreetmap.josm.gui.preferences.PreferenceDialog.setVisible(PreferenceDialog.java:145)
	at org.openstreetmap.josm.actions.PreferencesAction.run(PreferencesAction.java:119)
	at org.openstreetmap.josm.actions.PreferencesAction.actionPerformed(PreferencesAction.java:104)
	at org.openstreetmap.josm.gui.MainApplication$DefaultNativeOsCallback.handlePreferences(MainApplication.java:1594)
	at org.openstreetmap.josm.tools.PlatformHookOsx.invoke(PlatformHookOsx.java:223)
	at jdk.proxy1/jdk.proxy1.$Proxy0.handlePreferences(Unknown Source)
	at java.desktop/com.apple.eawt._AppEventHandler$_PreferencesDispatcher.performUsing(Unknown Source)
	at java.desktop/com.apple.eawt._AppEventHandler$_PreferencesDispatcher.performUsing(Unknown Source)
	at java.desktop/com.apple.eawt._AppEventHandler$_AppEventDispatcher$1.run(Unknown Source)
	at java.desktop/java.awt.event.InvocationEvent.dispatch(Unknown Source)
	at java.desktop/java.awt.EventQueue.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.EventQueue$4.run(Unknown Source)
	at java.desktop/java.awt.EventQueue$4.run(Unknown Source)
	at java.base/java.security.AccessController.doPrivileged(Unknown Source)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.desktop/java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.run(Unknown Source)

Attachments (0)

Change History (5)

comment:1 by mmd, 7 months ago

Probably a duplicate of #23717. Your JOSM version is too old, this was fixed in https://josm.openstreetmap.de/changeset/19099/josm

comment:2 by im@…, 7 months ago

Resolution: fixed
Status: newclosed

I guess latest stable is somehow "too old"...

Should I make a new bug report regarding inability to use automated authorize flow using custom info?

comment:3 by skyper, 7 months ago

Resolution: fixed
Status: closedreopened

in reply to:  2 comment:4 by skyper, 7 months ago

Replying to im@…:

I guess latest stable is somehow "too old"...

We have nightly builds aka josm-latest, see Download. The bug was fixed some weeks ago and the next stable release (probably released this week) will include the fix.

Should I make a new bug report regarding inability to use automated authorize flow using custom info?

Yes, please.

comment:5 by skyper, 7 months ago

Resolution: duplicate
Status: reopenedclosed

Closed as duplicate of #23717.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain team.
as The resolution will be set.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.