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

Close wrapper program when chobby exits #1498

Open
gajop opened this issue Feb 22, 2017 · 28 comments
Open

Close wrapper program when chobby exits #1498

gajop opened this issue Feb 22, 2017 · 28 comments

Comments

@gajop
Copy link
Contributor

gajop commented Feb 22, 2017

Chobby.exe wrapper keeps running even after Spring exits, leaving all these processes dangling:

ps axu | grep chobby
gajop     4595  0.9  0.4 1715612 150940 pts/20 Sl   12:43   2:39 /usr/bin/mono-sgen /home/gajop/chobby/Chobby.exe
gajop    17785  0.8  0.3 2129792 121504 ?      Sl    2月20  23:52 /usr/bin/mono-sgen /home/gajop/chobby/Chobby.exe
gajop    20001  0.8  0.3 2461524 116992 pts/20 Sl    2月21  15:07 /usr/bin/mono-sgen /home/gajop/chobby/Chobby.exe
@Licho1
Copy link
Member

Licho1 commented Feb 22, 2017

Need to know more information, how was it started? Is there anything in logs?

@db81
Copy link
Contributor

db81 commented Feb 22, 2017

There's no console output after [SpringApp::Run] exitCode=0. It happens every time on linux (unlike windows where it seems intermittent), regardless of how you start it (through steam or manually, with steam running or not).

@Licho1
Copy link
Member

Licho1 commented Feb 22, 2017

Please in steam folder, delete files from root + cache folder and do verify local copy.
Then start again.
It works for me in ubuntu but my VM is unable to run spring so it just crashes after few seconds so i might not have the proper data.

@Licho1 Licho1 closed this as completed Feb 22, 2017
@gajop
Copy link
Contributor Author

gajop commented Feb 22, 2017

@Licho1 This happened on a machine that didn't even have Steam installed.

@Licho1 Licho1 reopened this Feb 22, 2017
@Anarchid
Copy link
Member

Happens to me too. If i start from CLI, i can then finish it by killing the process with Ctrl+C.

@Licho1
Copy link
Member

Licho1 commented Feb 23, 2017

Unable to replicate on my VM.. no idea how to fix or diagnose. Maybe it does not detect spring closes?

@db81
Copy link
Contributor

db81 commented Feb 23, 2017

Run ubuntu from a liveCD to diagnose. Also try doing safe mode and all the jazz, I've "ran" spring in VirtualBox a year or so ago (it didn't crash but rendering was very glitchy).

@Licho1
Copy link
Member

Licho1 commented Feb 24, 2017

It spits GameAnalyticsSDK.Net.Logging.GALogger Warning about "failed to send events to collector" over and

Seme background thread isn't marked as background and prevents app from exiting it seems.

@Licho1 Licho1 closed this as completed Feb 24, 2017
@Licho1
Copy link
Member

Licho1 commented Feb 24, 2017

Regarding some docs, class finalizers might be run during Environment.Exit(); so perhaps GA is preventing it?

@Licho1 Licho1 reopened this Feb 24, 2017
@Licho1
Copy link
Member

Licho1 commented Feb 26, 2017

I tried on ubuntu in VM ,with xfce, steam started from command line and it closed properly..

@Anarchid
Copy link
Member

Still happens to me, so i thought i'd deliver a log: http://pastebin.com/cAn43Vka

@Licho1
Copy link
Member

Licho1 commented Feb 26, 2017

Hmm, thats not a steam version.. retry with steam after next stable.

@Anarchid
Copy link
Member

Anarchid commented Feb 26, 2017

I was impatient so i tried steam version outright. It seems to exit nicely.

@Licho1
Copy link
Member

Licho1 commented Feb 27, 2017

Retry again now after deployments i'm closing until it resurfaces.

@Licho1 Licho1 closed this as completed Feb 27, 2017
@db81
Copy link
Contributor

db81 commented Feb 27, 2017

Looks fixed here on Ubuntu.

@Licho1
Copy link
Member

Licho1 commented Feb 27, 2017

ok great thanks! Nothing really fixed except missing native libs got deployed. So I guess the reason was missing steam libs.

@gajop
Copy link
Contributor Author

gajop commented Mar 7, 2017

This is still broken on Ubuntu 16.04 http://pastebin.com/kuhnzQL6

@Licho1 Licho1 reopened this Mar 7, 2017
@Licho1 Licho1 closed this as completed in 100f40a Mar 10, 2017
@gajop
Copy link
Contributor Author

gajop commented Apr 19, 2017

FWIW, this is still not fixed (at least when starting from command line). Chobby app is running and it shows me playing ZK on Steam, even after I've closed Chobby.

➜  chobby Chobby.exe Information: 0 : Checking for self-upgrade
Chobby.exe Information: 0 : PackageRefresh complete - packages changed
Chobby.exe Information: 0 : http://zkmenu.repo.springrts.com/packages/81a889fac450f43615830f9b168f79b9.sdp Completed - 68.71k
Chobby.exe Information: 0 : zkmenu:stable download complete - 4.62M
Chobby.exe Information: 0 : http://zk.repo.springrts.com/packages/3a30a1dd4d6ba944ad3906c6602fac22.sdp Completed - 206.01k
Chobby.exe Information: 0 : zk:stable download complete - 2.18M
Chobby.exe Information: 0 : Querying default engine
Chobby.exe Information: 0 : Downloading http://zero-k.info/engine/linux64/103.0.1-764-gae7487f.zip
Chobby.exe Information: 0 : Installing http://zero-k.info/engine/linux64/103.0.1-764-gae7487f.zip
Chobby.exe Information: 0 : Install of 103.0.1-764-gae7487f complete
Chobby.exe Information: 0 : Reseting configs and deploying AIs
Chobby.exe Information: 0 : Connecting to steam API
Setting breakpad minidump AppID = 334920
Steam_SetMinidumpSteamID:  Caching Steam ID:  76561198030304871 [API loaded no]
Chobby.exe Information: 0 : Steam online
Chobby.exe Information: 0 : Starting
Chobby.exe Information: 0 : Chobby connected to wrapper
Chobby.exe Information: 0 : Chobbyla >> SteamOnline {"AuthToken":"14000000DA8FBB75768D7B5A67B62C04010010014CFCF658180000000100000002000000A1C1D3990000000089D3E00001000000B8000000380000000400000067B62C0401001001481C0500A1C1D3990601A8C000000000473BEF58C7EA0A590100D3D700000100E8210500000000003430A862E30E184599B6932299D5568DA4372A3A00C3A05EA486147F78D6C92BED8B74DCF5EAE4BF579E8017479AE4EABFAEFF63CFE7A559A918A026A401E2A15B477F02076D6C75828688F9D9DDB0DAE37093723EF9302E3E653773DAC602DB5D5B57F9414A0B9F926A1BC927D5851FED54EB6DBB00A4FBE25E620C236EFC22","Friends":["76561197962341674","76561197986648420","76561197995941676","76561197996112180","76561198002991441","76561198004251271","76561198006545309","76561198024788385","76561198034325245","76561198036306441","76561198064290354","76561198064684016","76561198079508980","76561198091336838","76561198120754924","76561198132621338","76561198134242806","76561198191972850"],"SuggestedName":"gajop"}

Chobby.exe Information: 0 : Chobbyla >> WrapperOnline {"UserID":"486863943","DefaultServerHost":"zero-k.info","DefaultServerPort":8200}

Chobby.exe Information: 0 : Chobbyla << GaAddDesignEvent {"EventID":"lobby:started"}
Chobby.exe Information: 0 : Chobbyla << Alert {"Message":"Match found"}
Chobby.exe Information: 0 : Chobbyla << OpenUrl {"Url":"http://zero-k.info/Battles/Detail/455016?asmallcake=b378ff62-67fc-487b-80c1-dd40c4fd868c"}
Created new window in existing browser session.
[20593:20593:0419/192024.005865:ERROR:broker_posix.cc(41)] Invalid node channel message
Chobby.exe Information: 0 : Chobby closed connection

➜  chobby ps axu | grep chobby
gajop    19407  1.0  1.0 2490720 174784 pts/17 Sl   18:59   0:23 /usr/bin/mono-sgen /home/gajop/chobby/Chobby.exe
gajop    21170  0.0  0.0  15236   976 pts/17   S+   19:35   0:00 grep --color=auto --exclude-dir=.bzr --exclude-dir=CVS --exclude-dir=.git --exclude-dir=.hg --exclude-dir=.svn chobby
➜  chobby kill 19407

@Histidine91
Copy link
Member

Also having zombie wrapper.

@Histidine91 Histidine91 reopened this Feb 1, 2018
@Licho1
Copy link
Member

Licho1 commented Feb 3, 2018

should be fixed agfain

@Licho1 Licho1 closed this as completed Feb 3, 2018
@DeinFreund
Copy link
Member

DeinFreund commented Apr 23, 2018

This still seems to be an issue, bohan reported on discord that he can still find rogue Chobby.exe in his process list after closing the game window.

@DeinFreund DeinFreund reopened this Apr 23, 2018
@johan-boule
Copy link

johan-boule commented Apr 23, 2018

This happened to me with the game downloaded on April 22 (the debian package).
The game was started from bash on a terminal, via the Zero-K wrapper script which actually made up the whole debian package (huh!).
This is what the terminal shows:
S_API FAIL] SteamAPI_Init() failed; SteamAPI_IsSteamRunning() failed. [S_API FAIL] SteamAPI_Init() failed; unable to locate a running instance of Steam, or a local steamclient.so.
[S_API FAIL] SteamAPI_Init() failed; SteamAPI_IsSteamRunning() failed.
[S_API FAIL] SteamAPI_Init() failed; unable to locate a running instance of Steam, or a local steamclient.so.
Chobby.exe Information: 0 : Chobby closed connection
13:14:11 GameAnalyticsSDK.Net.Logging.GALogger Warning/GameAnalytics: Event queue: Failed to send events to collector - Retrying next time
13:14:19 GameAnalyticsSDK.Net.Logging.GALogger Warning/GameAnalytics: Event queue: Failed to send events to collector - Retrying next time
0;1R^C
bohan@plasmoid:/tmp$

Notice that 0;1R looks like a truncated terminal escape sequence. ^C is me typing Ctrl+C because the process doesn't exits when you close the window. After that i was back to the bash prompt, and sometime after, i received another purple colored line at my bash prompt :
bohan@plasmoid:/tmp$ 0:17:47 GameAnalyticsSDK.Net.Logging.GALogger Warning/GameAnalytics: Event queue: Failed to send events to collector - Retrying next time
20:17:55 GameAnalyticsSDK.Net.Logging.GALogger Warning/GameAnalytics: Event queue: Failed to send events to collector - Retrying next time

So this is when I noticed the background process still attached to my terminal.
ps afxu shows :
bohan 30853 0.4 0.8 4618968 144696 pts/4 Sl avril22 6:54 /usr/bin/mono-sgen /home/.no-ecryptfs/bohan/downloads/zero-k/Chobby.exe

I'm unable to reproduce this :-/

PS to Github: You do not allow us to be sad in your supercool newworld, so you're only proposing happy face simlies... Fascists! Also, pasting code is reaaaalllyyy painful, which is a shame of a site dedicated to ... code!

@Licho1
Copy link
Member

Licho1 commented Apr 24, 2018

I guess broken steam support made it fail like that..

@johan-boule
Copy link

Should I deactivate steam in the settings ? I don't plan on signing up anyway.

@Licho1
Copy link
Member

Licho1 commented Apr 25, 2018

This wont help its wrapper issue

@Anarchid
Copy link
Member

Seems to be happening to windows users fairly frequently now. Still 100% replicable on Linux too.
This prevents ZK from being launched from Steam after being launched and quit once ("Zero-K is already running").

Recently complaining people to interrogate:

  • zenfur
  • Ragnaman

@Histidine91
Copy link
Member

@Cat-Lady may have figured out the issue:

it tries to connect to steam api and fails if steam not present - but somehow, doesn't terminate the steam api connection attempt, even when ZK gets exit'ed
(if at later time steam is turned On, it sucessfully connects, then gets idea that zk is closed, and finishes itself)
so, when using steam, this problem doesn't exist, but without it, there is lingering process trying to connect to steam api ad infinitum, until killed

@johan-boule
Copy link

johan-boule commented Jun 21, 2019 via email

@sprunk sprunk changed the title Close wrapper program when chobby exists Close wrapper program when chobby exits Aug 10, 2021
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

7 participants