not add random chracters
Browse files
app.py
CHANGED
@@ -41,7 +41,7 @@ def return_operation_results(from_model, to_model):
|
|
41 |
will_write['config']['model_args'] = will_write['config']['model_args'].replace(from_model, to_model)
|
42 |
will_write['model_name_sanitized'] = to_model.replace("/", "__", 1)
|
43 |
|
44 |
-
will_write = json.dumps(will_write, indent=2)
|
45 |
|
46 |
liste.extend([CommitOperationAdd(path_in_repo="/".join(remove_from(path_for, from_model, to_model).split("/")[3:]), path_or_fileobj=will_write.encode()),
|
47 |
CommitOperationDelete(path_in_repo="/".join(path_for.split("/")[3:]))])
|
|
|
41 |
will_write['config']['model_args'] = will_write['config']['model_args'].replace(from_model, to_model)
|
42 |
will_write['model_name_sanitized'] = to_model.replace("/", "__", 1)
|
43 |
|
44 |
+
will_write = json.dumps(will_write, indent=2, ensure_ascii=False).encode('utf8').decode()
|
45 |
|
46 |
liste.extend([CommitOperationAdd(path_in_repo="/".join(remove_from(path_for, from_model, to_model).split("/")[3:]), path_or_fileobj=will_write.encode()),
|
47 |
CommitOperationDelete(path_in_repo="/".join(path_for.split("/")[3:]))])
|