correc bug 2
Browse files
app.py
CHANGED
|
@@ -95,7 +95,10 @@ def create_fasta_file(file_content: str, name: Optional[str] = None, seq_name: O
|
|
| 95 |
|
| 96 |
# Generate a unique file name
|
| 97 |
unique_id = hashlib.sha256(uuid4().bytes).hexdigest()[:8]
|
| 98 |
-
|
|
|
|
|
|
|
|
|
|
| 99 |
file_path = here / "inputs/fasta" / file_name
|
| 100 |
|
| 101 |
# Write the FASTA file
|
|
@@ -137,7 +140,11 @@ def create_json_config(
|
|
| 137 |
}
|
| 138 |
|
| 139 |
# Generate file name based on provided name or unique ID
|
| 140 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 141 |
file_path = here / "inputs/config" / file_name
|
| 142 |
|
| 143 |
# Write the JSON file
|
|
|
|
| 95 |
|
| 96 |
# Generate a unique file name
|
| 97 |
unique_id = hashlib.sha256(uuid4().bytes).hexdigest()[:8]
|
| 98 |
+
if name:
|
| 99 |
+
file_name = name
|
| 100 |
+
else:
|
| 101 |
+
file_name = f"chai1_{unique_id}.fasta"
|
| 102 |
file_path = here / "inputs/fasta" / file_name
|
| 103 |
|
| 104 |
# Write the FASTA file
|
|
|
|
| 140 |
}
|
| 141 |
|
| 142 |
# Generate file name based on provided name or unique ID
|
| 143 |
+
unique_id = hashlib.sha256(uuid4().bytes).hexdigest()[:8]
|
| 144 |
+
if name:
|
| 145 |
+
file_name = name
|
| 146 |
+
else:
|
| 147 |
+
file_name = f"chai1_{unique_id}.json"
|
| 148 |
file_path = here / "inputs/config" / file_name
|
| 149 |
|
| 150 |
# Write the JSON file
|