Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(MacOS) "Launch error" #129

Closed
Anhedonia7437 opened this issue Feb 23, 2024 · 6 comments
Closed

(MacOS) "Launch error" #129

Anhedonia7437 opened this issue Feb 23, 2024 · 6 comments

Comments

@Anhedonia7437
Copy link

image

After downloading and installing the application on MacOS Sonoma 14.2.1 on my M1 Macbook Pro using mac-installer.dmg, I get this message on launch.

"Launch error
Launch error
See the py2app website for debugging launch issues"

Responses are "Visit Website" and "Terminate". Visit website leads here https://py2app.readthedocs.io/en/latest/debugging.html
I got no results after following this guide. Terminate simply closes the application.

@HotaruBlaze
Copy link
Contributor

Probably the same as #127, just macos wont give the same error prompt.

The steps should work the same on macos

@Anhedonia7437
Copy link
Author

Unfortunately that didn't work. After deleting it from both the Applications and Documents folder, reinstalling it from the same installer (mac-installer.dmg) on the pre-release build, launching it, replacing the text in the settings.txt, and then attempting to log in, the program crashes. Trying to launch it again gives me the same message as earlier.

I would guess that you're right that it's the same problem that's causing it, being the update that Nintendo pushed. But it might not have the same solution

@HotaruBlaze
Copy link
Contributor

To get a more usable error, I'd recommend trying to run NSO-RPC directly in a terminal and seeing what the "Real" Error is
You should be able to with the following command: ./Applications/NSO-RPC.app/Contents/MacOS/NSO-RPC

@Anhedonia7437
Copy link
Author

Anhedonia7437 commented Feb 23, 2024

`Last login: Thu Feb 22 23:07:51 on ttys000
jeremiah@jeremiahs-mbp ~ % /Applications/NSO-RPC.app/Contents/MacOS/NSO-RPC
Version override Detected: Replacing target version 2.9.0 with 2.8.1
Successfully Connected to Discord.
Traceback (most recent call last):
File "cli.pyc", line 88, in update
File "/Applications/NSO-RPC.app/Contents/Resources/lib/python3.11/api/init.py", line 181, in getSelf
self.getFriends()
File "/Applications/NSO-RPC.app/Contents/Resources/lib/python3.11/api/init.py", line 194, in getFriends
list.populateList(self)
File "/Applications/NSO-RPC.app/Contents/Resources/lib/python3.11/api/init.py", line 359, in populateList
raise e
File "/Applications/NSO-RPC.app/Contents/Resources/lib/python3.11/api/init.py", line 356, in populateList
arr = json.loads(response.text)['result']['friends']
~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^
KeyError: 'result'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/Applications/NSO-RPC.app/Contents/Resources/lib/python3.11/api/init.py", line 170, in updateLogin
self.headers['Authorization'] = 'Bearer %s' % login.account['result'].get('webApiServerCredential').get('accessToken') # Add authorization token
~~~~~~~~~~~~~^^^^^^^^^^
KeyError: 'result'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/Applications/NSO-RPC.app/Contents/Resources/boot.py", line 170, in
_run()
File "/Applications/NSO-RPC.app/Contents/Resources/boot.py", line 84, in _run
exec(compile(source, path, "exec"), globals(), globals())
File "/Applications/NSO-RPC.app/Contents/Resources/app.py", line 841, in
window.selfService()
File "/Applications/NSO-RPC.app/Contents/Resources/app.py", line 354, in selfService
self.changeState()
File "/Applications/NSO-RPC.app/Contents/Resources/app.py", line 489, in changeState
raise e
File "/Applications/NSO-RPC.app/Contents/Resources/app.py", line 486, in changeState
client.update()
File "cli.pyc", line 94, in update
File "/Applications/NSO-RPC.app/Contents/Resources/lib/python3.11/api/init.py", line 172, in updateLogin
raise Exception('Failure with authorization: %s\nLogin returns %s' % (e, login.account))
Exception: Failure with authorization: 'result'
Login returns {'status': 9403, 'errorMessage': 'Invalid token.', 'correlationId': '263cf8c3-ab724123'}
2024-02-22 23:08:58.899 NSO-RPC[4685:567740] Launch error
2024-02-22 23:08:58.899 NSO-RPC[4685:567740] Launch error
See the py2app website for debugging launch issues`
Yeah, it looks to be the same problem. I'm just not exactly sure why #127's solution doesn't seem to work considering they're the same.

@HotaruBlaze
Copy link
Contributor

make sure the settings.txt file exists before doing the copy link step, so only delete the two files mentioned in the issue if they exist

@Anhedonia7437
Copy link
Author

Ok, it appears to be working, I made a mistake.
After launching the application and editing the settings.txt file, restarting the program would allow the changes to take effect. This is not something I was doing before.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants