Spaces:
Running
Running
Update database.py
Browse files- database.py +1 -1
database.py
CHANGED
@@ -261,7 +261,7 @@ def save_chromadb_to_hf(dataset_name=HF_DATASET_NAME, token=os.getenv("HF_KEY"))
|
|
261 |
logger.info(f"Created Hugging Face Dataset with {len(data['code'])} entries")
|
262 |
|
263 |
# Push to Hugging Face Hub, overwriting existing dataset
|
264 |
-
dataset.push_to_hub(dataset_name, token=token,
|
265 |
logger.info(f"Dataset pushed to Hugging Face Hub as {dataset_name}, overwriting existing dataset")
|
266 |
# Verify push (optional, could check dataset on Hub)
|
267 |
logger.info(f"Verified Hugging Face dataset push with {len(dataset)} entries")
|
|
|
261 |
logger.info(f"Created Hugging Face Dataset with {len(data['code'])} entries")
|
262 |
|
263 |
# Push to Hugging Face Hub, overwriting existing dataset
|
264 |
+
dataset.push_to_hub(dataset_name, token=token, exists_ok=True)
|
265 |
logger.info(f"Dataset pushed to Hugging Face Hub as {dataset_name}, overwriting existing dataset")
|
266 |
# Verify push (optional, could check dataset on Hub)
|
267 |
logger.info(f"Verified Hugging Face dataset push with {len(dataset)} entries")
|