From e5fd140d8086151f05782b00126a4b6601ee9df8 Mon Sep 17 00:00:00 2001 From: Hugation99 <34241216+Hugation99@users.noreply.github.com> Date: Tue, 9 May 2023 14:29:56 +0200 Subject: [PATCH] Update networkLib.py --- networkLib.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/networkLib.py b/networkLib.py index 51811d3..e2e098c 100644 --- a/networkLib.py +++ b/networkLib.py @@ -201,7 +201,8 @@ def sendToken(radio): if token_passed: tb.loc[index,'Token'] = 1 tb =tb.drop(index) - tb = tb._append(new_row,ignore_index=True) + tb = pd.concat([tb, pd.DataFrame(new_row, index=[0])], ignore_index=True) + break if not token_passed: for index, row in tb.iterrows(): @@ -218,7 +219,7 @@ def sendToken(radio): timed_out = (time.time() - start_time > TIMEOUT_TOKEN) if token_passed: tb =tb.drop(index) - tb = tb._append(new_row,ignore_index=True) + tb = pd.concat([tb, pd.DataFrame(new_row, index=[0])], ignore_index=True) break logging.debug('token passed:'+str(token_passed))