PyPokerGUI icon indicating copy to clipboard operation
PyPokerGUI copied to clipboard

PyPokerGUI not work with Python 3

Open hgenru opened this issue 7 years ago • 4 comments

First error is:

  File "round_state_html.generated.py", line 53, in _tt_execute
    for idx, player in zip(range(len(round_state['seats']))[:len(round_state['seats'])/2], round_state['seats']):  # round_state.html:22

But all code not prepared to work with Python 3

hgenru avatar Sep 01 '17 10:09 hgenru

This fixed it for me:

first fix in round_state.html

<div id="seats-upper" class="row row-center"> {% for idx, player in zip(range(len(round_state['seats']))[:int(len(round_state['seats'])/2)], round_state['seats']) %}

second fix

<div id="seats-lower" class="row row-center"> {% for idx, player in zip(range(len(round_state['seats']))[int(len(round_state['seats'])/2):], round_state['seats'][int(len(round_state['seats'])/2):]) %}

Ns85 avatar Sep 03 '17 02:09 Ns85

https://github.com/ishikota/PyPokerGUI/pull/7 should be good to go. Thanks again @Ns85

chrisking avatar Sep 18 '17 20:09 chrisking

fixed following @Ns85 . Thanks.

miguelvb avatar Oct 30 '19 11:10 miguelvb

Thanks, @Ns85 . Working.

For those who were confused, put the @Ns85 edits in C:\Users\lordg52\AppData\Local\Programs\Python\Python310\Lib\site-packages\pypokergui\server\templates\round_state.html

Lordg52 avatar Nov 08 '22 01:11 Lordg52