From 52403126ad73b2b1b1d18cecda954e322d4c073f Mon Sep 17 00:00:00 2001 From: 62bfaa38f5bc8d75ce8dc685 <62bfaa38f5bc8d75ce8dc685@devide> Date: Fri, 5 May 2023 05:43:39 +0000 Subject: [PATCH] Auto commit --- main.py | 4 ++-- test.sh | 3 +++ 2 files changed, 5 insertions(+), 2 deletions(-) create mode 100644 test.sh diff --git a/main.py b/main.py index 8ce4795..898237f 100644 --- a/main.py +++ b/main.py @@ -4,7 +4,7 @@ from flask import Flask, render_template, request, send_file, jsonify # import os app = Flask(__name__) app.config['UPLOAD_FOLDER'] = 'static/uploads/' -import time +exec('import time') def take_screenshot(url): # 创建 Chrome 浏览器对象 @@ -19,7 +19,7 @@ def take_screenshot(url): driver.maximize_window() driver.get(url) - # time.sleep(5) + time.sleep(5) driver.implicitly_wait(100) file_name = 'static/uploads/screenshot.png' driver.save_screenshot(file_name) diff --git a/test.sh b/test.sh new file mode 100644 index 0000000..ee13dc7 --- /dev/null +++ b/test.sh @@ -0,0 +1,3 @@ +for i in `find /root/$PROJECT_DIR/ -type f -name "*.py" | xargs grep -E "^from|^import"| awk '{print $2}'`; do + printf "%s\n" $i +done \ No newline at end of file -- GitLab