pypy and mc

41 views
Skip to first unread message

Eddie Aretz

unread,
Jul 28, 2023, 9:21:43 PMJul 28
to MPF Users
Installed pypy to run on production pin, but the MC that needs to run on standard Python is not connecting to the game run on pypy. Pypy (3.9) is not running in a sandbox but I understand it runs in its own environment as I had to install pip and mpf under pypy..as per the docs. Just wondering if someone has seen similar?

Anthony van Winkle

unread,
Jul 31, 2023, 1:03:17 PMJul 31
to MPF Users
Hello Eddie-

There should be no problem connecting a pypy-run MPF with a standard python MC. The two connect via a network port on the machine (5050 by default) so neither one has knowledge of how the other runs. The place to check is the logs: does the MPF log say waiting for connection, and does the MC log say waiting for connection? They should each sit and wait for a connection before booting into the game.

I use pypy on my games too!

-Anthony

Eddie Aretz

unread,
Aug 1, 2023, 9:18:27 PMAug 1
to MPF Users
Hi Anthony, thanks for the reply. See below, they do actually connect but there is no screen text or sound coming through. The MC gets all the way to mc_reset_complete and then just hangs there. Could I ask what versions you are running? My python is 3.8 and pypy is 3.9... wondering if a python upgrade is worth a try? This is a nice to have but not critical as my pin runs fine, but you can never have too much power :)

Ed


2023-08-02 08:59:32,766 : MPF-MC BCP Server : Starting up on localhost port 5050
2023-08-02 08:59:32,767 : MPF-MC BCP Server : Waiting for a connection...
2023-08-02 08:59:32,767 : mpfmc : SlidePlayer: Play called with settings={'slides': {welcome_slide-None-None: {'priority': None, 'target': None, 'background_color': [0.0, 0.0, 0.0, 1.0], 'show': True, 'force': False, 'expire': None, 'slide': None, 'tokens': {}, 'action': 'play', 'transition': None, 'transition_out': None}}}
2023-08-02 08:59:32,768 : EventManager : Event: ======'slide_welcome_slide_created'====== Args={}
2023-08-02 08:59:32,769 : EventManager : Event: ======'slide_welcome_slide_active'====== Args={}
2023-08-02 08:59:32,770 : EventManager : Event: ======'client_disconnected'====== Args={'host': '127.0.0.1', 'port': 5050}
2023-08-02 09:00:11,467 : MPF-MC BCP Server : Received connection from: 127.0.0.1:33486
2023-08-02 09:00:11,478 : EventManager : Event: ======'client_connected'====== Args={'host': '127.0.0.1', 'port': 33486}
*****  stripped log and taken out a bunch of the machine var audits etc for readability here ****************
2023-08-02 09:02:42,300 : EventManager : Event: ======'machine_var_audits_switches_sw_rightsling_top'====== Args={'value': 0, 'prev_value': None, 'change': True}
2023-08-02 09:02:42,300 : EventManager : Event: ======'machine_var_audits_switches_sw_shooter_lane'====== Args={'value': 4, 'prev_value': None, 'change': True}
2023-08-02 09:02:42,300 : EventManager : Event: ======'machine_var_audits_switches_sw_trough_1'====== Args={'value': 1, 'prev_value': None, 'change': True}
2023-08-02 09:02:42,300 : EventManager : Event: ======'machine_var_audits_switches_sw_trough_2'====== Args={'value': 0, 'prev_value': None, 'change': True}
2023-08-02 09:02:42,300 : EventManager : Event: ======'machine_var_audits_switches_sw_trough_3'====== Args={'value': 0, 'prev_value': None, 'change': True}
2023-08-02 09:02:42,300 : EventManager : Event: ======'machine_var_audits_switches_sw_trough_jam'====== Args={'value': 0, 'prev_value': None, 'change': True}
2023-08-02 09:02:42,300 : EventManager : Event: ======'mc_reset_phase_1'====== Args={}
2023-08-02 09:02:42,301 : EventManager : Event: ======'mc_reset_phase_2'====== Args={}
2023-08-02 09:02:42,301 : EventManager : Event: ======'mc_reset_phase_3'====== Args={}
2023-08-02 09:02:42,301 : EventManager : Event: ======'mc_reset_complete'====== Args={}

Ben Tripoli

unread,
Oct 1, 2023, 10:13:24 PMOct 1
to MPF Users
Anyone happen to get this working? I have similar issue to the original post.
Reply all
Reply to author
Forward
0 new messages