- Backend: Refactored tasks.py to directly invoke run_single_fna_pipeline.py for consistency. - Backend: Changed output format to ZIP and added auto-cleanup of intermediate files. - Backend: Fixed language parameter passing in API and tasks. - Frontend: Removed CRISPR Fusion UI elements from Submit and Monitor views. - Frontend: Implemented simulated progress bar for better UX. - Frontend: Restored One-click load button and added result file structure documentation. - Docker: Fixed critical Restarting loop by removing incorrect image directive in docker-compose.yml. - Docker: Optimized Dockerfile to correct .pixi environment path issues and prevent accidental deletion of frontend assets.
32 lines
838 B
Python
32 lines
838 B
Python
#!/usr/bin/env python3
|
|
"""
|
|
Mock BGC Detector (ZWA/Thu/TAA)
|
|
Returns random presence/absence for testing.
|
|
"""
|
|
import argparse
|
|
import json
|
|
import random
|
|
from pathlib import Path
|
|
|
|
def main():
|
|
parser = argparse.ArgumentParser()
|
|
parser.add_argument("--input", required=True, help="Input genome file")
|
|
parser.add_argument("--output", required=True, help="Output JSON file")
|
|
args = parser.parse_args()
|
|
|
|
# Mock logic: Randomly assign 0 or 1
|
|
# In real impl, this would run HMM/BLAST against specific BGC databases
|
|
results = {
|
|
"ZWA": random.choice([0, 1]),
|
|
"Thu": random.choice([0, 1]),
|
|
"TAA": random.choice([0, 1])
|
|
}
|
|
|
|
with open(args.output, "w") as f:
|
|
json.dump(results, f, indent=2)
|
|
|
|
print(f"Mock BGC results written to {args.output}")
|
|
|
|
if __name__ == "__main__":
|
|
main()
|