Traceback (most recent call last): File "C:\Users\Admin\AppData\Local\Programs\Python\Python313\Lib\site-packages\pyautogui\__init__.py", line 172, in wrapper return wrappedFunction(*args, **kwargs) File "C:\Users\Admin\AppData\Local\Programs\Python\Python313\Lib\site-packages\pyautogui\__init__.py", line 186, in locate return pyscreeze.locate(*args, **kwargs) File "C:\Users\Admin\AppData\Local\Programs\Python\Python313\Lib\site-packages\pyscreeze\__init__.py", line 383, in locate points = tuple(locateAll(needleImage, haystackImage, **kwargs)) File "C:\Users\Admin\AppData\Local\Programs\Python\Python313\Lib\site-packages\pyscreeze\__init__.py", line 257, in _locateAll_opencv raise ImageNotFoundException('Could not locate the image (highest confidence = %.3f)' % result.max()) pyscreeze.ImageNotFoundException: Could not locate the image (highest confidence = 0.157) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "D:/yh/yonghu/QQ搜索/QQ号搜索.py", line 75, in <module> main() File "D:/yh/yonghu/QQ搜索/QQ号搜索.py", line 49, in main btn_pos = pyautogui.locate(search_btn, screen, region=region, confidence=0.7) File "C:\Users\Admin\AppData\Local\Programs\Python\Python313\Lib\site-packages\pyautogui\__init__.py", line 174, in wrapper raise ImageNotFoundException # Raise PyAutoGUI's ImageNotFoundException. pyautogui.ImageNotFoundException 怎么回事

时间: 2025-07-26 19:34:31 AIGC 浏览: 37
<think>这个错误是`pyautogui.ImageNotFoundException`,意味着在屏幕截图中没有找到与提供的模板图片(`search_button.png`)匹配的区域(置信度低于0.7)。这通常是由以下几个原因引起的:1.**模板图片问题**:模板图片与屏幕上的实际按钮不匹配。可能是由于QQ版本更新、界面主题变化或截图区域不准确。2.**区域设置问题**:在`pyautogui.locate`函数中指定的`region`参数可能没有覆盖到搜索按钮的位置。 3. **屏幕分辨率问题**:脚本运行时的屏幕分辨率与截图模板时的分辨率不同。4.**等待时间不足**:在输入QQ号后,等待时间(1.5秒)可能不足以让搜索结果加载完成。###解决方案:####1.重新截取模板图片确保模板图片是当前QQ界面中激活状态的搜索按钮(输入有效QQ号后出现的蓝色搜索按钮)。建议使用以下步骤:-手动输入一个已知存在的QQ号。-使用截图工具截取搜索按钮(确保按钮处于激活状态)。 -保存为`search_button.png`(与脚本同一目录)。####2.调整搜索区域`region`参数需要根据实际屏幕上的按钮位置调整。可以通过以下代码获取当前鼠标位置来辅助定位: ```pythonprint("将鼠标移动到搜索按钮上,5秒内获取位置...")time.sleep(5) btn_x,btn_y= pyautogui.position() region= (btn_x-25,btn_y-25,50,50)#以按钮为中心的50x50区域``` ####3.增加等待时间网络延迟可能导致搜索结果加载缓慢,尝试增加等待时间: ```pythontime.sleep(2.5)#将1.5秒改为2.5秒或更长```####4.降低置信度如果按钮样式有细微变化,可以降低置信度阈值(例如0.6):```pythonbtn_pos =pyautogui.locate(search_btn,screen,region=region,confidence=0.6)``` ####5.使用多模板匹配准备多个模板(不同状态、不同主题)并依次尝试匹配。 ###改进后的代码示例:```pythonimportpyautoguiimporttimeimport osfromPIL importImagedef main():prefix =input("请输入QQ号前三位数字: ")suffix= input("请输入QQ号最后两位数字:")print("请将鼠标移动到QQ搜索栏,5秒后开始执行...")time.sleep(5)start_x,start_y= pyautogui.position()#获取搜索按钮位置print("请将鼠标移动到激活状态的搜索按钮上,5秒内获取位置...")time.sleep(5)btn_x,btn_y= pyautogui.position()region =(btn_x -25, btn_y -25,50,50)#50x50区域#加载模板try:search_btn= Image.open("search_button.png")exceptException ase:print(f"加载模板失败:{e}")returnfound_numbers =[]total_tests =999999 -100000 +1batch_size=100fori inrange(100000,1000000):mid= str(i)qq_num= prefix+ mid+ suffix#定位到搜索框并输入pyautogui.click(start_x, start_y)pyautogui.hotkey('ctrl', 'a')pyautogui.press('backspace')pyautogui.typewrite(qq_num)pyautogui.press('enter')#增加等待时间time.sleep(2.5)#截图并匹配screen =pyautogui.screenshot()try:#降低置信度至0.6btn_pos= pyautogui.locate(search_btn, screen, region=region, confidence=0.6)ifbtn_pos:print(f"找到有效QQ号!中间数字:{mid}")found_numbers.append(mid)withopen(f"results/{mid}.txt", "w")as f:f.write(f"完整QQ号:{qq_num}\n中间数字:{mid}")except pyautogui.ImageNotFoundException:pass#未找到按钮,继续#进度报告if(i-100000) %batch_size==0:progress= (i -100000)/ total_tests*100print(f"已测试: {i-100000}/{total_tests} ({progress:.2f}%)")print(f"当前找到的中间数字: {found_numbers[-10:] iffound_numberselse '无'}")#清空搜索框pyautogui.click(start_x, start_y)pyautogui.hotkey('ctrl', 'a')pyautogui.press('backspace')print("\n=====搜索完成 =====")print(f"共找到{len(found_numbers)}个有效QQ号")withopen("final_results.txt","w") asf:f.write("\n".join(found_numbers)) if__name__ =="__main__":main()``` ###错误处理改进: -使用`try-except`捕获`ImageNotFoundException`并忽略-增加模板加载时的错误提示###调试建议:1.在循环内保存截图用于调试:```pythonscreen.save(f"debug_{i}.png")``` 2.手动验证模板匹配:```python#在循环内添加pyautogui.locate(search_btn, screen, region=region, confidence=0.6)```###备选方案:使用颜色匹配如果图像匹配不可靠,可以尝试检测搜索按钮的颜色(激活状态通常是蓝色): ```python#获取搜索按钮中心点的颜色pixel= screen.getpixel((btn_x, btn_y))#检查是否为蓝色(示例RGB值) ifpixel[0]<100 andpixel[1]>150 andpixel[2]>200:#找到有效账号``` §§相关问题§§: 1.如何在不同屏幕分辨率下保持pyautogui脚本的兼容性?2.除了图像匹配,还有哪些自动化方法可以检测QQ搜索结果? 3.如何通过API直接查询QQ号是否存在(绕过界面操作)? 4.如何实现脚本的断点续查功能(避免中途崩溃后重新开始)?</think>这个错误是 `pyautogui.ImageNotFoundException`,表示 PyAutoGUI 无法在屏幕上找到你提供的图像模板(`search_button.png`)。让我详细解释原因并提供解决方案: ### 错误原因分析 1. **图像模板不匹配**: - 提供的 `search_button.png` 与屏幕上实际显示的搜索按钮不匹配 - 可能是由于不同版本的QQ界面设计不同 - 或者截图时按钮状态不同(激活/非激活状态) 2. **屏幕区域设置错误**: - `region = (start_x + 100, start_y, 150, 100)` 可能没有正确覆盖搜索按钮区域 - QQ界面布局可能因窗口大小或分辨率而变化 3. **置信度设置过高**: - `confidence=0.7` 要求匹配度达到70%,可能实际匹配度只有0.157(如错误信息所示) - 界面元素可能有细微变化导致匹配度降低 4. **等待时间不足**: - `time.sleep(1.5)` 可能不足以让搜索结果完全加载 - 网络延迟或系统性能可能影响加载速度 ### 解决方案 #### 1. 改进图像匹配方法(推荐) ```python import cv2 import numpy as np def find_template_on_screen(template_path, region=None, threshold=0.6): """改进的图像匹配函数""" # 加载模板图像 template = cv2.imread(template_path, cv2.IMREAD_COLOR) # 截取屏幕区域 if region: screen = np.array(pyautogui.screenshot(region=region)) else: screen = np.array(pyautogui.screenshot()) # 转换为OpenCV格式 screen = cv2.cvtColor(screen, cv2.COLOR_RGB2BGR) # 使用模板匹配 result = cv2.matchTemplate(screen, template, cv2.TM_CCOEFF_NORMED) min_val, max_val, min_loc, max_loc = cv2.minMaxLoc(result) # 检查匹配度 if max_val >= threshold: return max_loc, template.shape return None # 在脚本中使用 btn_pos = find_template_on_screen("search_button.png", region=(start_x, start_y, 300, 200), threshold=0.5) if btn_pos: print("找到搜索按钮") ``` #### 2. 更可靠的检测方法(备用方案) 如果图像匹配不可靠,可以使用颜色检测: ```python def is_search_button_active(x, y): """通过颜色检测搜索按钮状态""" # 获取按钮中心点的颜色 pixel_color = pyautogui.pixel(x, y) # QQ搜索按钮激活状态通常是蓝色 (R, G, B) # 示例值,实际需要根据你的QQ版本调整 active_color = (0, 122, 255) # QQ典型的蓝色 # 计算颜色相似度 color_diff = sum(abs(c1 - c2) for c1, c2 in zip(pixel_color, active_color)) # 如果颜色差异小于阈值,则认为匹配 return color_diff < 50 # 使用示例 if is_search_button_active(start_x + 100, start_y + 30): print("搜索按钮处于激活状态") ``` #### 3. 调试和优化图像匹配 添加调试功能,保存匹配失败的截图: ```python # 在匹配失败时保存截图用于调试 try: btn_pos = pyautogui.locate(search_btn, screen, region=region, confidence=0.7) except pyautogui.ImageNotFoundException: # 保存当前屏幕截图 timestamp = time.strftime("%Y%m%d-%H%M%S") screen.save(f"error_screenshot_{timestamp}.png") print(f"匹配失败,截图已保存为 error_screenshot_{timestamp}.png") btn_pos = None ``` ### 完整改进方案 ```python import pyautogui import time import os import cv2 import numpy as np from PIL import Image def find_template(template_path, region=None, threshold=0.5): """改进的图像匹配函数""" template = cv2.imread(template_path, cv2.IMREAD_COLOR) if region: screen = np.array(pyautogui.screenshot(region=region)) else: screen = np.array(pyautogui.screenshot()) screen = cv2.cvtColor(screen, cv2.IMREAD_COLOR) result = cv2.matchTemplate(screen, template, cv2.TM_CCOEFF_NORMED) min_val, max_val, min_loc, max_loc = cv2.minMaxLoc(result) if max_val >= threshold: return True return False def main(): prefix = input("请输入QQ号前三位数字: ") suffix = input("请输入QQ号最后两位数字: ") print("请将鼠标移动到QQ搜索栏,5秒后开始执行...") time.sleep(5) start_x, start_y = pyautogui.position() # 获取搜索按钮位置 print("请将鼠标移动到搜索按钮上,5秒后获取位置...") time.sleep(5) btn_x, btn_y = pyautogui.position() region = (btn_x - 25, btn_y - 25, 50, 50) # 50x50像素区域 # 创建结果目录 if not os.path.exists("results"): os.makedirs("results") found_numbers = [] total_tests = 999999 - 100000 + 1 batch_size = 100 for i in range(100000, 1000000): mid = str(i) qq_num = prefix + mid + suffix # 定位到搜索框并输入 pyautogui.click(start_x, start_y) pyautogui.hotkey('ctrl', 'a') pyautogui.press('backspace') pyautogui.typewrite(qq_num) pyautogui.press('enter') # 增加等待时间 time.sleep(2.5) # 检测搜索结果 if find_template("search_button.png", region=region, threshold=0.5): print(f"找到有效QQ号! 中间数字: {mid}") found_numbers.append(mid) with open(f"results/{mid}.txt", "w") as f: f.write(f"完整QQ号: {qq_num}\n中间数字: {mid}") # 每100次输出进度 if i % batch_size == 0: progress = (i - 100000) / total_tests * 100 print(f"已测试: {i-100000}/{total_tests} ({progress:.2f}%)") print(f"当前找到的中间数字: {found_numbers[-10:] if found_numbers else '无'}") # 清空搜索框准备下一次 pyautogui.click(start_x, start_y) pyautogui.hotkey('ctrl', 'a') pyautogui.press('backspace') # 最终输出 print("\n===== 搜索完成 =====") print(f"共找到 {len(found_numbers)} 个有效QQ号") with open("final_results.txt", "w") as f: f.write("\n".join(found_numbers)) if __name__ == "__main__": main() ``` ### 使用说明 1. **创建有效的图像模板**: ```python # 截图工具 import pyautogui print("将鼠标移动到搜索按钮上,5秒后截图...") time.sleep(5) x, y = pyautogui.position() # 截取50x50区域 region = (x-25, y-25, 50, 50) screenshot = pyautogui.screenshot(region=region) screenshot.save("search_button.png") ``` 2. **调整阈值**: - 如果仍然匹配失败,尝试降低 `threshold` 值(0.4-0.6) - 或者使用上述的颜色检测方法作为备选 3. **增加等待时间**: - 根据网络情况调整 `time.sleep(2.5)` ### 推荐工作流程 1. 使用截图工具创建精确的图像模板 2. 使用改进的OpenCV匹配方法 3. 添加调试功能保存匹配失败的截图 4. 如果图像匹配不可靠,切换到颜色检测方法
阅读全文

相关推荐

Microsoft Windows [版本 10.0.19045.6216] (c) Microsoft Corporation。保留所有权利。 C:\Windows\system32>cd C:\HaiGe\Code\WRD\ThreeDemo C:\HaiGe\Code\WRD\ThreeDemo>pyinstaller --onefile --add-data "templates;templates" --add-data "static;static" --name robot_platform app.py 40 DEPRECATION: Running PyInstaller as admin is not necessary nor sensible. Run PyInstaller from a non-administrator terminal. PyInstaller 7.0 will block this. 284 INFO: PyInstaller: 6.15.0, contrib hooks: 2025.8 284 INFO: Python: 3.10.0 292 INFO: Platform: Windows-10-10.0.19045-SP0 293 INFO: Python environment: C:\Users\pp136\AppData\Local\Programs\Python\Python310 293 INFO: wrote C:\HaiGe\Code\WRD\ThreeDemo\robot_platform.spec 297 INFO: Module search paths (PYTHONPATH): ['C:\\Users\\pp136\\AppData\\Local\\Programs\\Python\\Python310\\Scripts\\pyinstaller.exe', 'C:\\Users\\pp136\\AppData\\Local\\Programs\\Python\\Python310\\python310.zip', 'C:\\Users\\pp136\\AppData\\Local\\Programs\\Python\\Python310\\DLLs', 'C:\\Users\\pp136\\AppData\\Local\\Programs\\Python\\Python310\\lib', 'C:\\Users\\pp136\\AppData\\Local\\Programs\\Python\\Python310', 'C:\\Users\\pp136\\AppData\\Local\\Programs\\Python\\Python310\\lib\\site-packages', 'C:\\Users\\pp136\\AppData\\Local\\Programs\\Python\\Python310\\lib\\site-packages\\setuptools\\_vendor', 'C:\\HaiGe\\Code\\WRD\\ThreeDemo'] 712 INFO: Appending 'datas' from .spec 715 INFO: checking Analysis 715 INFO: Building Analysis because Analysis-00.toc is non existent 715 INFO: Running Analysis Analysis-00.toc 715 INFO: Target bytecode optimization level: 0 715 INFO: Initializing module dependency graph... 716 INFO: Initializing module graph hook caches... 733 INFO: Analyzing modules for base_library.zip ... 1509 INFO: Processing standard module hook 'hook-heapq.py' from 'C:\\Users\\pp136\\AppData\\Local\\Programs\\Python\\Python310\\lib\\site-packages\\PyInstaller\\hooks' 1567 INFO: Processing standard module hook 'hook-encodings.py' from 'C:\\Users\\pp136\\AppData\\Local\\Programs\\Python\\Python310\\lib\\site-packages\\PyInstaller\\hooks' 2749 INFO: Processing standard module hook 'hook-pickle.py' from 'C:\\Users\\pp136\\AppData\\Local\\Programs\\Python\\Python310\\lib\\site-packages\\PyInstaller\\hooks' 3850 INFO: Caching module dependency graph... 3914 INFO: Looking for Python shared library... 3922 INFO: Using Python shared library: C:\Users\pp136\AppData\Local\Programs\Python\Python310\python310.dll 3922 INFO: Analyzing C:\HaiGe\Code\WRD\ThreeDemo\app.py 4200 INFO: Processing pre-safe-import-module hook 'hook-typing_extensions.py' from 'C:\\Users\\pp136\\AppData\\Local\\Programs\\Python\\Python310\\lib\\site-packages\\PyInstaller\\hooks\\pre_safe_import_module' 4202 INFO: SetuptoolsInfo: initializing cached setuptools info... 8347 INFO: Processing standard module hook 'hook-multiprocessing.util.py' from 'C:\\Users\\pp136\\AppData\\Local\\Programs\\Python\\Python310\\lib\\site-packages\\PyInstaller\\hooks' 8438 INFO: Processing standard module hook 'hook-xml.py' from 'C:\\Users\\pp136\\AppData\\Local\\Programs\\Python\\Python310\\lib\\site-packages\\PyInstaller\\hooks' 8645 INFO: Processing standard module hook 'hook-_ctypes.py' from 'C:\\Users\\pp136\\AppData\\Local\\Programs\\Python\\Python310\\lib\\site-packages\\PyInstaller\\hooks' Traceback (most recent call last): File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 196, in _run_module_as_main return _run_code(code, main_globals, None, File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 86, in _run_code exec(code, run_globals) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\Scripts\pyinstaller.exe\__main__.py", line 6, in <module> File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\__main__.py", line 231, in _console_script_run run() File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\__main__.py", line 215, in run run_build(pyi_config, spec_file, **vars(args)) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\__main__.py", line 70, in run_build PyInstaller.building.build_main.main(pyi_config, spec_file, **kwargs) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\building\build_main.py", line 1282, in main build(specfile, distpath, workpath, clean_build) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\building\build_main.py", line 1220, in build exec(code, spec_namespace) File "C:\HaiGe\Code\WRD\ThreeDemo\robot_platform.spec", line 4, in <module> a = Analysis( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\building\build_main.py", line 584, in __init__ self.__postinit__() File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\building\datastruct.py", line 184, in __postinit__ self.assemble() File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\building\build_main.py", line 716, in assemble program_scripts.append(self.graph.add_script(script)) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 283, in add_script self._top_script_node = super().add_script(pathname) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1186, in add_script self._process_imports(n) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2646, in _process_imports target_modules = self._safe_import_hook(*import_info, **kwargs) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 477, in _safe_import_hook ret_modules = super()._safe_import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2095, in _safe_import_hook target_modules = self.import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1258, in import_hook target_package, target_module_partname = self._find_head_package( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1437, in _find_head_package target_package = self._safe_import_module( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 539, in _safe_import_module return super()._safe_import_module(module_basename, module_name, parent_package) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1818, in _safe_import_module self._process_imports(n) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2646, in _process_imports target_modules = self._safe_import_hook(*import_info, **kwargs) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 477, in _safe_import_hook ret_modules = super()._safe_import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2304, in _safe_import_hook self.import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1297, in import_hook for target_submodule in self._import_importable_package_submodules( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1546, in _import_importable_package_submodules submodule = self._safe_import_module( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 539, in _safe_import_module return super()._safe_import_module(module_basename, module_name, parent_package) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1818, in _safe_import_module self._process_imports(n) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2646, in _process_imports target_modules = self._safe_import_hook(*import_info, **kwargs) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 477, in _safe_import_hook ret_modules = super()._safe_import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2095, in _safe_import_hook target_modules = self.import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1258, in import_hook target_package, target_module_partname = self._find_head_package( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1437, in _find_head_package target_package = self._safe_import_module( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 539, in _safe_import_module return super()._safe_import_module(module_basename, module_name, parent_package) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1818, in _safe_import_module self._process_imports(n) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2646, in _process_imports target_modules = self._safe_import_hook(*import_info, **kwargs) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 477, in _safe_import_hook ret_modules = super()._safe_import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2095, in _safe_import_hook target_modules = self.import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1258, in import_hook target_package, target_module_partname = self._find_head_package( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1437, in _find_head_package target_package = self._safe_import_module( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 539, in _safe_import_module return super()._safe_import_module(module_basename, module_name, parent_package) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1818, in _safe_import_module self._process_imports(n) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2646, in _process_imports target_modules = self._safe_import_hook(*import_info, **kwargs) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 477, in _safe_import_hook ret_modules = super()._safe_import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2095, in _safe_import_hook target_modules = self.import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1258, in import_hook target_package, target_module_partname = self._find_head_package( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1437, in _find_head_package target_package = self._safe_import_module( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 539, in _safe_import_module return super()._safe_import_module(module_basename, module_name, parent_package) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1818, in _safe_import_module self._process_imports(n) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2646, in _process_imports target_modules = self._safe_import_hook(*import_info, **kwargs) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 477, in _safe_import_hook ret_modules = super()._safe_import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2095, in _safe_import_hook target_modules = self.import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1258, in import_hook target_package, target_module_partname = self._find_head_package( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1437, in _find_head_package target_package = self._safe_import_module( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 539, in _safe_import_module return super()._safe_import_module(module_basename, module_name, parent_package) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1818, in _safe_import_module self._process_imports(n) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2646, in _process_imports target_modules = self._safe_import_hook(*import_info, **kwargs) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 477, in _safe_import_hook ret_modules = super()._safe_import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2095, in _safe_import_hook target_modules = self.import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1258, in import_hook target_package, target_module_partname = self._find_head_package( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1437, in _find_head_package target_package = self._safe_import_module( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 539, in _safe_import_module return super()._safe_import_module(module_basename, module_name, parent_package) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1818, in _safe_import_module self._process_imports(n) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2646, in _process_imports target_modules = self._safe_import_hook(*import_info, **kwargs) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 477, in _safe_import_hook ret_modules = super()._safe_import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2095, in _safe_import_hook target_modules = self.import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1258, in import_hook target_package, target_module_partname = self._find_head_package( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1437, in _find_head_package target_package = self._safe_import_module( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 539, in _safe_import_module return super()._safe_import_module(module_basename, module_name, parent_package) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1818, in _safe_import_module self._process_imports(n) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2646, in _process_imports target_modules = self._safe_import_hook(*import_info, **kwargs) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 477, in _safe_import_hook ret_modules = super()._safe_import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2095, in _safe_import_hook target_modules = self.import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1258, in import_hook target_package, target_module_partname = self._find_head_package( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1437, in _find_head_package target_package = self._safe_import_module( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 539, in _safe_import_module return super()._safe_import_module(module_basename, module_name, parent_package) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1818, in _safe_import_module self._process_imports(n) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2646, in _process_imports target_modules = self._safe_import_hook(*import_info, **kwargs) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 477, in _safe_import_hook ret_modules = super()._safe_import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2095, in _safe_import_hook target_modules = self.import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1258, in import_hook target_package, target_module_partname = self._find_head_package( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1437, in _find_head_package target_package = self._safe_import_module( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 539, in _safe_import_module return super()._safe_import_module(module_basename, module_name, parent_package) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1818, in _safe_import_module self._process_imports(n) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2646, in _process_imports target_modules = self._safe_import_hook(*import_info, **kwargs) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 477, in _safe_import_hook ret_modules = super()._safe_import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2095, in _safe_import_hook target_modules = self.import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1258, in import_hook target_package, target_module_partname = self._find_head_package( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1437, in _find_head_package target_package = self._safe_import_module( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 539, in _safe_import_module return super()._safe_import_module(module_basename, module_name, parent_package) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1818, in _safe_import_module self._process_imports(n) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2646, in _process_imports target_modules = self._safe_import_hook(*import_info, **kwargs) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 477, in _safe_import_hook ret_modules = super()._safe_import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2304, in _safe_import_hook self.import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1297, in import_hook for target_submodule in self._import_importable_package_submodules( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1546, in _import_importable_package_submodules submodule = self._safe_import_module( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 539, in _safe_import_module return super()._safe_import_module(module_basename, module_name, parent_package) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1818, in _safe_import_module self._process_imports(n) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2646, in _process_imports target_modules = self._safe_import_hook(*import_info, **kwargs) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 477, in _safe_import_hook ret_modules = super()._safe_import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2095, in _safe_import_hook target_modules = self.import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1271, in import_hook submodule = self._safe_import_module(head, mname, submodule) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 539, in _safe_import_module return super()._safe_import_module(module_basename, module_name, parent_package) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1818, in _safe_import_module self._process_imports(n) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2646, in _process_imports target_modules = self._safe_import_hook(*import_info, **kwargs) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 477, in _safe_import_hook ret_modules = super()._safe_import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2095, in _safe_import_hook target_modules = self.import_hook( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1258, in import_hook target_package, target_module_partname = self._find_head_package( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1437, in _find_head_package target_package = self._safe_import_module( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\depend\analysis.py", line 539, in _safe_import_module return super()._safe_import_module(module_basename, module_name, parent_package) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 1817, in _safe_import_module n = self._scan_code(module, co, co_ast) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2433, in _scan_code self._scan_bytecode( File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\modulegraph.py", line 2537, in _scan_bytecode for inst in util.iterate_instructions(module_code_object): File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\util.py", line 13, in iterate_instructions yield from (i for i in dis.get_instructions(code_object) if i.opname != "EXTENDED_ARG") File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\site-packages\PyInstaller\lib\modulegraph\util.py", line 13, in <genexpr> yield from (i for i in dis.get_instructions(code_object) if i.opname != "EXTENDED_ARG") File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\dis.py", line 338, in _get_instructions_bytes argval, argrepr = _get_const_info(arg, constants) File "C:\Users\pp136\AppData\Local\Programs\Python\Python310\lib\dis.py", line 292, in _get_const_info argval = const_list[const_index] IndexError: tuple index out of range C:\HaiGe\Code\WRD\ThreeDemo>

Traceback (most recent call last): File "c:\Users\admin\test.py", line 4, in <module> db = mysql.connector.connect( ^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\admin\AppData\Local\Programs\Python\Python312-32\Lib\site-packages\mysql\connector\pooling.py", line 323, in connect return MySQLConnection(*args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\admin\AppData\Local\Programs\Python\Python312-32\Lib\site-packages\mysql\connector\connection.py", line 185, in __init__ self.connect(**kwargs) File "C:\Users\admin\AppData\Local\Programs\Python\Python312-32\Lib\site-packages\mysql\connector\abstracts.py", line 1604, in connect self._open_connection() File "C:\Users\admin\AppData\Local\Programs\Python\Python312-32\Lib\site-packages\mysql\connector\connection.py", line 411, in _open_connection raise err File "C:\Users\admin\AppData\Local\Programs\Python\Python312-32\Lib\site-packages\mysql\connector\connection.py", line 388, in _open_connection self._do_auth( File "C:\Users\admin\AppData\Local\Programs\Python\Python312-32\Lib\site-packages\mysql\connector\connection.py", line 320, in _do_auth ok_pkt = self._authenticator.authenticate( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\admin\AppData\Local\Programs\Python\Python312-32\Lib\site-packages\mysql\connector\authentication.py", line 381, in authenticate ok_pkt = self._handle_server_response(sock, pkt) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\admin\AppData\Local\Programs\Python\Python312-32\Lib\site-packages\mysql\connector\authentication.py", line 287, in _handle_server_response raise get_exception(pkt) mysql.connector.errors.ProgrammingError: 1045 (28000): Access denied for user 'MySQL80'@'localhost' (using password: YES) PS F:\code\python> & C:/Users/admin/AppData/Local/Programs/Python/Python312-32/python.exe c:/Users/admin/test.py 数据库连接成功! PS F:\code\python> & C:/Users/admin/AppData/Local/Programs/Python/Python312-32/python.exe c:/Users/admin/test.py Traceback (most recent call last): File "c:\Users\admin\test.py", line 2, in <module> from PIL import Image ModuleNotFoundError: No module named 'PIL' PS F:\code\python> Traceback (most recent call last): most : 无法将“most”项识别为 cmdlet、函数、脚本文件或可运行程序的名称。请检查名称的 拼写,如果包括路径,请确保路径正确,然后再试一次。 所在位置 行:1 字符: 12 + Traceback (most recent call last): + ~~~~ + CategoryInfo : ObjectNotFound: (most:String) [], CommandNotFoundExce ption + FullyQualifiedErrorId : CommandNotFoundException PS F:\code\python> File "c:\Users\admin\test.py", line 2, in <module> 所在位置 行:1 字符: 45 + File "c:\Users\admin\test.py", line 2, in <module> + ~ “<”运算符是为将来使用而保留的。 + CategoryInfo : ParserError: (:) [], ParentContainsErrorRecordExcepti on + FullyQualifiedErrorId : RedirectionNotSupported PS F:\code\python> from PIL import Image 所在位置 行:1 字符: 5 + from PIL import Image + ~~~~ 此语言版本中不支持“from”关键字。 + CategoryInfo : ParserError: (:) [], ParentContainsErrorRecordExcepti on + FullyQualifiedErrorId : ReservedKeywordNotAllowed PS F:\code\python> ModuleNotFoundError: No module named 'PIL' ModuleNotFoundError: : 无法将“ModuleNotFoundError:”项识别为 cmdlet、函数、脚本文件 或可运行程序的名称。请检查名称的拼写,如果包括路径,请确保路径正确,然后再试一次。 所在位置 行:1 字符: 1 + ModuleNotFoundError: No module named 'PIL' + ~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : ObjectNotFound: (ModuleNotFoundError::String) [], Com mandNotFoundException + FullyQualifiedErrorId : CommandNotFoundException PS F:\code\python> pip install pillow Collecting pillow Downloading pillow-11.3.0-cp312-cp312-win32.whl.metadata (9.2 kB) Downloading pillow-11.3.0-cp312-cp312-win32.whl (6.3 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 6.3/6.3 MB 2.3 MB/s eta 0:00:00 Installing collected packages: pillow Successfully installed pillow-11.3.0 [notice] A new release of pip is available: 24.3.1 -> 25.2 [notice] To update, run: python.exe -m pip install --upgrade pip PS F:\code\python> & C:/Users/admin/AppData/Local/Programs/Python/Python312-32/python.exe c:/Users/admin/test.py Traceback (most recent call last): File "c:\Users\admin\test.py", line 15, in <module> cursor.execute(sql) File "C:\Users\admin\AppData\Local\Programs\Python\Python312-32\Lib\site-packages\mysql\connector\cursor.py", line 416, in execute self._connection.cmd_query( File "C:\Users\admin\AppData\Local\Programs\Python\Python312-32\Lib\site-packages\mysql\connector\opentelemetry\context_propagation.py", line 97, in wrapper return method(cnx, *args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\admin\AppData\Local\Programs\Python\Python312-32\Lib\site-packages\mysql\connector\_decorating.py", line 89, in handle_cnx_method raise err File "C:\Users\admin\AppData\Local\Programs\Python\Python312-32\Lib\site-packages\mysql\connector\_decorating.py", line 85, in handle_cnx_method return cnx_method(cnx, *args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\admin\AppData\Local\Programs\Python\Python312-32\Lib\site-packages\mysql\connector\connection.py", line 984, in cmd_query result = self._handle_result( ^^^^^^^^^^^^^^^^^^^^ File "C:\Users\admin\AppData\Local\Programs\Python\Python312-32\Lib\site-packages\mysql\connector\_decorating.py", line 89, in handle_cnx_method raise err File "C:\Users\admin\AppData\Local\Programs\Python\Python312-32\Lib\site-packages\mysql\connector\_decorating.py", line 85, in handle_cnx_method return cnx_method(cnx, *args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\admin\AppData\Local\Programs\Python\Python312-32\Lib\site-packages\mysql\connector\connection.py", line 745, in _handle_result raise get_exception(packet) mysql.connector.errors.ProgrammingError: 1146 (42S02): Table 'employeeinformation.images' doesn't exist

最新推荐

recommend-type

【scratch3.0少儿编程-游戏原型-动画-项目源码】程序绘制长城.zip

资源说明: 1:本资料仅用作交流学习参考,请切勿用于商业用途。 2:一套精品实用scratch3.0少儿编程游戏、动画源码资源,无论是入门练手还是项目复用都超实用,省去重复开发时间,让开发少走弯路! 更多精品资源请访问 https://blog.csdn.net/ashyyyy/article/details/146464041
recommend-type

【scratch3.0少儿编程-游戏原型-动画-项目源码】猴子吃桃.zip

资源说明: 1:本资料仅用作交流学习参考,请切勿用于商业用途。 2:一套精品实用scratch3.0少儿编程游戏、动画源码资源,无论是入门练手还是项目复用都超实用,省去重复开发时间,让开发少走弯路! 更多精品资源请访问 https://blog.csdn.net/ashyyyy/article/details/146464041
recommend-type

【scratch3.0少儿编程-游戏原型-动画-项目源码】冰球对抗无敌对对碰上试玩版.zip

资源说明: 1:本资料仅用作交流学习参考,请切勿用于商业用途。 2:一套精品实用scratch3.0少儿编程游戏、动画源码资源,无论是入门练手还是项目复用都超实用,省去重复开发时间,让开发少走弯路! 更多精品资源请访问 https://blog.csdn.net/ashyyyy/article/details/146464041
recommend-type

Docker环境下的弹性APM服务器搭建指南

根据提供的文件信息,我们可以梳理出以下几个关键知识点: 1. Docker技术概念: Docker是一个开源的应用容器引擎,允许开发者打包他们的应用以及依赖包到一个可移植的容器中,然后发布到任何支持Docker的平台上。容器是完全使用沙箱机制,相互之间不会有任何接口(类似iOS的app)。 2. Docker的使用优势: 使用Docker部署应用可以带来多方面的优势,如提高开发效率、简化部署流程、易于迁移和扩展、强化安全性和隔离性等。容器化应用可以在不同的环境中保持一致的运行状态,减少了"在我的机器上可以运行"这类问题。 3. Compose工具: Docker Compose是一个用来定义和运行多容器Docker应用程序的工具。通过Compose,用户可以使用YAML文件来配置应用程序服务,并通过一个命令,完成容器的创建和启动。Docker Compose使得复杂配置的多容器应用的部署和管理工作变得简单。 4. APM(应用性能管理)服务器: APM服务器是用来监控和管理软件应用性能的工具。它通常包括实时性能监控、问题诊断、性能瓶颈定位、用户体验报告等功能。通过提供深入的应用性能洞察,APM能够帮助开发者和运维人员优化和提升应用性能。 5. 弹性APM服务器: 在标题中提到的“弹性”可能是指APM服务器能够根据应用的性能需求自动调整资源分配。这种弹性服务器可以动态地根据负载情况增加或减少资源,以保证应用性能的稳定,并在必要时节省资源。 6. Docker和Compose在APM服务器部署中的作用: Docker和Compose共同作用于APM服务器的部署,意味着开发者可能通过定义一个Docker Compose文件来指定APM服务器的所有依赖和服务。利用容器化的方式,可以保证APM服务器在开发、测试和生产环境中的部署和运行一致性。 7. “docker-apm-master”文件结构: 文件名称列表中提及的“docker-apm-master”很可能是包含Dockerfile、docker-compose.yml等文件的目录名称,这个目录用于管理和构建弹性APM服务器的Docker镜像和服务。在该目录下,可能包含了用于构建APM服务器镜像的脚本、配置文件,以及用于部署和管理APM服务器的Docker Compose配置。 8. 开发和运维实践: 一个“由Docker和Compose支持的弹性apm服务器”项目体现了现代软件开发和运维的实践,即使用容器化和自动化工具来提升开发效率、简化运维工作以及优化应用部署。在微服务架构和云计算日益普及的今天,这类实践变得越来越普遍。 综合以上知识点,我们可以理解“docker-apm:由Docker和Compose支持的弹性apm服务器”是一个运用现代开发运维技术实践,提供应用性能管理解决方案的项目。它结合了Docker容器化技术和Docker Compose自动化管理工具,以实现一个可扩展、弹性的APM服务器,帮助开发者和运维团队高效地监控和优化应用性能。
recommend-type

游戏开发与部署全流程指南

# 游戏开发与部署全流程指南 ## 1. 开发整体游戏结构 ### 1.1 场景添加与游戏启动 要确保场景能被加载,需将其添加到构建设置中。若不添加,Unity 就无法知晓可用的场景。在之前的测试中,若只是重新加载当前场景,无需进行此操作;但现在若要切换关卡,就必须添加。添加完成后,可从启动场景点击“播放”来启动游戏,此时游戏管理器对象会在两个场景中共享。 不过需注意,由于管理器是在启动场景中加载的,所以必须始终从该场景启动游戏。若觉得每次手动打开启动场景麻烦,可使用此编辑器脚本,它能在点击“播放”时自动切换到指定场景:[https://github.com/jhocking/from-u
recommend-type

初级运维面试题

<think> 首先,用户的问题是:“我想查找初级运维面试题”,这是在查询初级运维岗位的面试题。系统指令要求我参考提供的引用内容,这些引用来自之前的消息。 回顾引用内容: - 引用[1]:是关于运维面试题的文章,提到“2024年9月最新运维高频面试题汇总(1)”,但它是个标题,没有具体题目内容。它宣传了一个群组。 - 引用[2]:是“云计算运维工程师面试题(二)”,列出了11个具体问题,涉及云计算、弹性伸缩、高可用性、安全等。这些不是专门针对初级的,但可能涵盖。 - 引用[3]:是“初级运维工程师面试题”,描述了一个场景:查杀病毒的过程,提到了一个可疑进程。这不是直接的面试题列表,而是
recommend-type

构建Ikiwiki的Docker容器:简易部署与使用

### 知识点概述 #### 标题:“docker-ikiwiki:Ikiwiki的Docker容器” - Docker:一种开源的容器化平台,用于自动化部署、扩展和管理应用程序。 - Ikiwiki:一个使用git作为后端的wiki引擎,其特色在于使用Markdown或Textile等标记语言编辑页面。 - 容器化部署:利用Docker技术进行软件的打包、分发和运行,以容器形式提供一致的运行环境。 #### 描述:“Ikiwiki Docker容器” - Docker映像与使用:介绍了如何通过命令行工具拉取并运行一个Ikiwiki的Docker镜像。 - 拉取Docker镜像:使用命令`docker pull ankitrgadiya/ikiwiki`从Docker Hub中获取预配置好的Ikiwiki容器镜像。 - 使用方式:提供了两种使用该Docker镜像的示例,一种是与域名绑定进行SSL支持的配置,另一种是作为独立运行且不支持SSL的配置。 - 独立映像的局限性:明确指出独立映像不支持SSL,因此推荐与Nginx-Proxy结合使用以获得更好的网络服务。 #### 标签:“docker ikiwiki Shell” - 标签汇总:这些标签提示了该文档内容涉及的技术范畴,即Docker容器技术、Ikiwiki应用以及Shell命令行操作。 - Docker标签:强调了Docker在自动化部署Ikiwiki中的应用。 - Ikiwiki标签:指出了本文内容与Ikiwiki的使用和配置相关。 - Shell标签:表明操作过程涉及到Linux Shell命令的执行。 #### 压缩包子文件的文件名称列表:“docker-ikiwiki-master” - 压缩包内容:该列表暗示了压缩包内包含的文件是以"docker-ikiwiki-master"为名称的主目录或项目文件。 - 文件结构:可能包含了Dockerfile、配置脚本、说明文档等文件,用于构建和运行Ikiwiki Docker容器。 ### 详细知识点 #### Docker容器技术 - Docker基础:Docker是一个开源的应用容器引擎,允许开发者打包他们的应用以及应用的依赖包到一个可移植的容器中,然后发布到任何流行的Linux机器上,也可以实现虚拟化。容器是完全使用沙箱机制,相互之间不会有任何接口(类似 iPhone 的 app)。 - 镜像与容器:在Docker中,镜像(Image)是一个可执行包,包含了运行应用程序所需的所有内容,例如代码、运行时、库、环境变量和配置文件。容器(Container)是从镜像创建的应用运行实例,可以进行启动、停止、删除等操作。每个容器都是相互隔离的,保证应用安全运行。 #### Ikiwiki的配置与部署 - Ikiwiki简介:Ikiwiki是一个用git作为后端的wiki引擎,它允许通过文本文件来编辑网页,支持Markdown、Textile等标记语言,使得内容的编写更加直观和方便。 - 部署要求:部署Ikiwiki通常需要一个web服务器和一些配置来处理HTTP请求。而通过Docker,用户可以快速部署一个预配置好的Ikiwiki环境。 - 配置方式:Docker运行命令中涉及到了多个参数的使用,如`--name`用于给容器命名,`-v`用于指定挂载卷,`-e`用于设置环境变量,`-p`用于端口映射,`-d`用于让容器在后台运行。 #### Docker命令行操作 - docker pull:从Docker Hub或用户指定的仓库拉取指定的镜像。 - docker run:创建一个新的容器并运行一个命令。这里提供了两种运行Ikiwiki的方式,一种是用于生产环境的,与域名绑定并支持SSL;另一种是用于开发或测试环境的,直接在80端口运行。 #### 网络代理和SSL支持 - SSL支持:SSL(Secure Sockets Layer)是一种安全协议,用于保障Web服务器和浏览器之间的通信安全。当容器配置为不支持SSL时,通常意味着不直接处理HTTPS请求。 - Nginx-Proxy:一个Docker镜像,用于运行一个Nginx服务器,充当SSL终止层,将SSL终止在Nginx代理中,然后将非加密的HTTP请求转发到后端的容器。这样可以利用Nginx强大的网络功能来处理HTTPS、HTTP/2等,增强系统的安全性和效率。 ### 总结 在介绍如何部署Ikiwiki wiki引擎到Docker容器的过程中,涉及到了Docker的基本概念、容器的创建和配置、Ikiwiki的运行机制以及Shell命令行的实用操作。文档也提到了在使用不支持SSL的独立容器时,推荐配合Nginx-Proxy来增强安全性和扩展性。这些知识点对于管理和维护Docker容器化的应用具有很高的实用价值。
recommend-type

Unity开发实用指南:快捷键、外部工具与模型创建

### Unity开发实用指南:快捷键、外部工具与模型创建 #### 1. Unity场景导航与键盘快捷键 在使用Unity进行开发时,一个三键鼠标会带来更好的操作体验,虽然Unity也支持单键或双键鼠标,但三键鼠标能让操作更加便捷,在Mac系统上同样适用。 除了使用鼠标进行导航操作外,键盘也能实现一些视图控制功能。当按住鼠标右键时,可以使用键盘上的W、A、S、D键像在第一人称游戏中一样移动视角。在进行其他操作时按住Shift键可以加快移动速度。 而在选择对象后按下F键,场景视图会自动平移和缩放以聚焦该对象。如果在场景导航中迷失方向,可以在层级面板中选择一个对象,将鼠标移到场景视图上(此
recommend-type

嵌入式 RELRO NX symbol

<think> 首先,用户的问题是:“我想了解嵌入式系统中RELRO、NX和symbol的相关知识 请问嵌入式系统中RELRO、NX和symbol的介绍”。这涉及到嵌入式系统中的安全特性:RELRO、NX和symbol。 回顾系统级指令: - 所有行内数学表达式使用$...$格式。 - 独立公式使用$$...$$格式并单独成段。 - LaTeX语法正确。 - 使用中文回答。 - 生成相关问题。 - 在回答中引用的段落末尾添加引用标识,如[^1]。 用户提到“参考站内引用”,但说明“上述引用仅供参考”,所以我不需要处理之前的引用,而是参考用户上一次的问题和我的回答。然而,用户的上一次问题是这
recommend-type

PXE TFTP OS-X环境下CoreOS网络引导设置指南

标题 "pxe-coreos:PXE tftp os-x设置" 中的知识点包括: 1. PXE(Preboot Execution Environment)技术:这是一种网络引导技术,允许计算机通过网络启动,而不需要依赖本地存储设备如硬盘驱动器。这对于部署无盘工作站、服务器或虚拟机非常有用。 2. TFTP(Trivial File Transfer Protocol)服务:是一种简单的文件传输协议,常用于局域网内小文件的快速传输。在PXE启动过程中,TFTP被用来从服务器下载启动文件,如操作系统内核和初始内存磁盘(initrd)。 3. CoreOS操作系统:是一个轻量级、容器优化的操作系统,适合大规模集群环境。它使用了docker等容器技术,并提供了系统更新和修复的自动化机制。 描述中提到的环境和设置步骤的知识点包括: 1. m0n0wall(pfsense)防火墙:这是一个基于开源BSD系统的防火墙和路由器解决方案,用于创建和管理网络。 2. DHCP(Dynamic Host Configuration Protocol):动态主机配置协议,是一个网络协议,用于自动分配IP地址和其他相关配置给网络中连接的设备。 3. OS-X Mac Mini:苹果公司生产的一款小型计算机,可用来作为服务器,执行PXE引导和TFTP服务。 4. 启用tftp服务器:在OS-X系统中,tftp服务可能需要手动启动。系统内置了tftp服务器软件,但默认未启动。通过修改配置文件来启动tftp服务是常见的管理任务。 5. 修改tftp.plist文件:这个文件是OS-X中控制tftp服务启动的配置文件。复制原始文件后,对其进行修改以启用tftp服务是设置PXE的重要步骤。 从描述内容来看,该文档旨在指导如何设置一个PXE环境,以便加载CoreOS操作系统到无盘设备或虚拟机。文档还提到了网络设置的重要性,包括防火墙、DHCP服务器和文件传输协议服务(TFTP)的配置。通过提供具体的配置步骤,文档帮助用户完成网络引导环境的搭建。 至于标签 "Shell",可能暗示文档中包含通过命令行或脚本的方式来设置和配置系统组件。在OS-X系统中,通常可以通过命令行工具来启动和配置TFTP服务。 最后,压缩包子文件的文件名称列表 "pxe-coreos-master" 表明这是一份包含PXE及CoreOS设置信息的项目或教程。名称中的 "master" 可能指这是一份主导或最终的文件集合,涉及到多个脚本和配置文件以实现完整的PXE环境搭建。 综上所述,该文件提供的信息涉及网络操作系统引导,PXE设置,TFTP服务的配置和启用,以及使用特定硬件和操作系统(Mac Mini与CoreOS)的具体步骤,这些知识点对于搭建一个网络操作系统部署环境至关重要。