Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
Update app.py
Browse files
app.py
CHANGED
@@ -622,6 +622,8 @@ async def update_hub_stats():
|
|
622 |
for index, row in global_df.iterrows():
|
623 |
# fill blank values with n/a for now? then replace if they try to verify
|
624 |
#column = global_df['hf_user_name']
|
|
|
|
|
625 |
|
626 |
#for index, user in column:
|
627 |
print(f"index: {index}")
|
@@ -647,15 +649,14 @@ async def update_hub_stats():
|
|
647 |
#updated_df.loc[index, ['likes', 'models', 'datasets', 'spaces', 'discussions', 'papers', 'upvotes']] = [likes, models, datasets, spaces, discussions, papers, upvotes]
|
648 |
print(f"likes: {likes}")
|
649 |
#global_df.loc[index, 'likes'] = likes
|
650 |
-
|
651 |
-
print(f"updated row {index} for user {user}")
|
652 |
else:
|
653 |
print(f"Failed to retrieve data for user {user}. Status code: {response.status_code}")
|
654 |
|
655 |
print(global_df)
|
656 |
|
657 |
except Exception as e:
|
658 |
-
print(f"Failed to parse data for user {user}.")
|
659 |
|
660 |
|
661 |
|
|
|
622 |
for index, row in global_df.iterrows():
|
623 |
# fill blank values with n/a for now? then replace if they try to verify
|
624 |
#column = global_df['hf_user_name']
|
625 |
+
|
626 |
+
# data type of value?
|
627 |
|
628 |
#for index, user in column:
|
629 |
print(f"index: {index}")
|
|
|
649 |
#updated_df.loc[index, ['likes', 'models', 'datasets', 'spaces', 'discussions', 'papers', 'upvotes']] = [likes, models, datasets, spaces, discussions, papers, upvotes]
|
650 |
print(f"likes: {likes}")
|
651 |
#global_df.loc[index, 'likes'] = likes
|
652 |
+
#print(f"updated row {index} for user {user}")
|
|
|
653 |
else:
|
654 |
print(f"Failed to retrieve data for user {user}. Status code: {response.status_code}")
|
655 |
|
656 |
print(global_df)
|
657 |
|
658 |
except Exception as e:
|
659 |
+
print(f"Failed to parse data for user {user}. {e}")
|
660 |
|
661 |
|
662 |
|