James McCool commited on
Commit
7443266
·
1 Parent(s): a01df7b

Update lineup replacement logic in load_contest_file function

Browse files

- Modified the replacement method for position indicators in the cleaned dataframe to use regex, enhancing the accuracy of lineup processing.
- This change continues the effort to improve data handling and user experience within the application.

Files changed (1) hide show
  1. global_func/load_contest_file.py +1 -1
global_func/load_contest_file.py CHANGED
@@ -41,7 +41,7 @@ def load_contest_file(upload, sport):
41
 
42
  # Create the cleaned dataframe with just the essential columns
43
  cleaned_df = df[['BaseName', 'EntryCount', 'Lineup']]
44
- cleaned_df['Lineup'] = cleaned_df['Lineup'].replace(pos_list, ',')
45
 
46
  # Get unique entry names
47
  entry_list = list(set(df['BaseName']))
 
41
 
42
  # Create the cleaned dataframe with just the essential columns
43
  cleaned_df = df[['BaseName', 'EntryCount', 'Lineup']]
44
+ cleaned_df['Lineup'] = cleaned_df['Lineup'].replace(pos_list, value=',', regex=True)
45
 
46
  # Get unique entry names
47
  entry_list = list(set(df['BaseName']))