SoUmNerd commited on
Commit
7efb37a
1 Parent(s): d24b332

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +6 -1
main.py CHANGED
@@ -1,6 +1,11 @@
1
  from fastapi import FastAPI
2
  import subprocess
3
- from tools.regex import find_imports
 
 
 
 
 
4
 
5
 
6
  app = FastAPI()
 
1
  from fastapi import FastAPI
2
  import subprocess
3
+ import re
4
+
5
+ def find_imports(code):
6
+ pattern = r'Python\.import_module\("([^"]*)"\)'
7
+ matches = re.findall(pattern, code)
8
+ return matches
9
 
10
 
11
  app = FastAPI()