PocketSkye commited on
Commit
5643085
·
1 Parent(s): 33f25c6

Initial deployment

Browse files
Files changed (1) hide show
  1. main.py +6 -3
main.py CHANGED
@@ -1,9 +1,12 @@
1
  import asyncio
2
 
3
  # Required for Playwright on Windows
4
- asyncio.set_event_loop_policy(
5
- asyncio.WindowsProactorEventLoopPolicy()
6
- )
 
 
 
7
 
8
  from fastapi import FastAPI
9
 
 
1
  import asyncio
2
 
3
  # Required for Playwright on Windows
4
+ import platform
5
+
6
+ if platform.system() == "Windows":
7
+ asyncio.set_event_loop_policy(
8
+ asyncio.WindowsProactorEventLoopPolicy()
9
+ )
10
 
11
  from fastapi import FastAPI
12