会员可以在此提问,百战程序员老师有问必答
对大家有帮助的问答会被标记为“推荐”
看完课程过来浏览一下别人提的问题,会帮你学得更全面
截止目前,同学们一共提了 132655个问题

Installing requirements for CodeFormer

Traceback (most recent call last):

  File "E:\stable-diffusion-webui\launch.py", line 48, in <module>

    main()

  File "E:\stable-diffusion-webui\launch.py", line 39, in main

    prepare_environment()

  File "E:\stable-diffusion-webui\modules\launch_utils.py", line 389, in prepare_environment

    run_pip(f"install -r \"{os.path.join(repo_dir('CodeFormer'), 'requirements.txt')}\"", "requirements for CodeFormer")

  File "E:\stable-diffusion-webui\modules\launch_utils.py", line 138, in run_pip

    return run(f'"{python}" -m pip {command} --prefer-binary{index_url_line}', desc=f"Installing {desc}", errdesc=f"Couldn't install {desc}", live=live)

  File "E:\stable-diffusion-webui\modules\launch_utils.py", line 115, in run

    raise RuntimeError("\n".join(error_bits))

RuntimeError: Couldn't install requirements for CodeFormer.

Command: "E:\stable-diffusion-webui\venv\Scripts\python.exe" -m pip install -r "E:\stable-diffusion-webui\repositories\CodeFormer\requirements.txt" --prefer-binary

Error code: 1

stdout: Looking in indexes: http://mirrors.aliyun.com/pypi/simple/


stderr: WARNING: The repository located at mirrors.aliyun.com is not a trusted or secure host and is being ignored. If this repository is available via HTTPS we recommend you use HTTPS instead, otherwise you may silence this warning and allow it anyway with '--trusted-host mirrors.aliyun.com'.

ERROR: Could not find a version that satisfies the requirement addict (from versions: none)

ERROR: No matching distribution found for addict


[notice] A new release of pip available: 22.2.1 -> 23.3.1

[notice] To update, run: E:\stable-diffusion-webui\venv\Scripts\python.exe -m pip install --upgrade pip


请按任意键继续. . .


AIGC人工智能工具全能班 /第五阶段:Stable Diffusion(自选模型)AI绘图/Stable Diffusion本地安装 2896楼
WEB前端全系列/第二阶段:JavaScript编程模块/运算符_数据类型和流程循环语句 2897楼
Python 全系列/第一阶段:Python入门/Python入门(动画版) 2898楼
Python 全系列/第六阶段:生产环境部署与协同开发/Git 2899楼
Python 全系列/第六阶段:生产环境部署与协同开发/Git 2901楼
Python 全系列/第一阶段:Python入门/编程基本概念 2902楼
Python 全系列/第六阶段:生产环境部署与协同开发/Linux系统概述与安装 2903楼

#客户端
#coding-utf-8
from  socket import *
from  threading import Thread
def recv_data():
    while True:
        recv_date = s.recvfrom(1024)  # 1024表示本次接收的最大字节数
        recv_content = recv_date[0].decode('gbk')
        print(f"收到远程信息:{recv_content},from {recv_date[1]}")
        if recv_content == "88":
            print("聊天结束")
            break

def send_data():
    addr = ("127.0.0.1", 8989)
    while True:
        data = input("请输入:")
        s.sendto(data.encode("gbk"), addr)
        if data == '88':
            print('聊天结束!')
            break
    s.close()

if __name__ =='__main__':
    s= socket(AF_INET,SOCK_DGRAM) #创建UDP类型的套接字
    s.bind(('127.0.0.1',8080)) #绑定接口,ip可以不写
    #创建两个线程
    t1=Thread(target=recv_data)
    t2=Thread(target=send_data)
    t1.start()
    t2.start()
    t1.join()
    t2.join()



#服务端
#coding-utf-8
from  socket import *
from  threading import Thread
def recv_data():
    while True:
        recv_date = s.recvfrom(1024)  # 1024表示本次接收的最大字节数
        recv_content = recv_date[0].decode('gbk')
        print(f"收到远程信息:{recv_content},from {recv_date[1]}")
        if recv_content == "88":
            print("聊天结束")
            break

def send_data():
    addr = ("127.0.0.1", 8080)
    while True:
        data = input("请输入:")
        s.sendto(data.encode("gbk"), addr)
        if data == '88':
            print('聊天结束!')
            break
    s.close()

if __name__ =='__main__':
    s= socket(AF_INET,SOCK_DGRAM) #创建UDP类型的套接字
    s.bind(('127.0.0.1',8989)) #绑定接口,ip可以不写
    #创建两个线程
    t1=Thread(target=recv_data)
    t2=Thread(target=send_data)
    t1.start()
    t2.start()
    t1.join()
    t2.join()




#报错
C:\Users\LS\PycharmProjects\mypro001\venv\Scripts\python.exe C:\Users\LS\PycharmProjects\mypro001\mypro05.py 
请输入:1234
请输入:Exception in thread Thread-1 (recv_data):
Traceback (most recent call last):
  File "C:\Users\LS\AppData\Local\Programs\Python\Python312\Lib\threading.py", line 1052, in _bootstrap_inner
    self.run()
  File "C:\Users\LS\AppData\Local\Programs\Python\Python312\Lib\threading.py", line 989, in run
    self._target(*self._args, **self._kwargs)
  File "C:\Users\LS\PycharmProjects\mypro001\mypro05.py", line 6, in recv_data
    recv_date = s.recvfrom(1024)  # 1024表示本次接收的最大字节数
                ^^^^^^^^^^^^^^^^
ConnectionResetError: [WinError 10054] 远程主机强迫关闭了一个现有的连接。
Exception in thread Thread-2 (send_data):
Traceback (most recent call last):
  File "C:\Users\LS\AppData\Local\Programs\Python\Python312\Lib\threading.py", line 1052, in _bootstrap_inner
    self.run()
  File "C:\Users\LS\AppData\Local\Programs\Python\Python312\Lib\threading.py", line 989, in run
    self._target(*self._args, **self._kwargs)
  File "C:\Users\LS\PycharmProjects\mypro001\mypro05.py", line 16, in send_data
    data = input("请输入:")
           ^^^^^^^^^^^^^
  File "<frozen codecs>", line 322, in decode
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xff in position 0: invalid start byte
Traceback (most recent call last):
  File "C:\Users\LS\PycharmProjects\mypro001\mypro05.py", line 32, in <module>
    t2.join()
  File "C:\Users\LS\AppData\Local\Programs\Python\Python312\Lib\threading.py", line 1126, in join
    self._wait_for_tstate_lock()
  File "C:\Users\LS\AppData\Local\Programs\Python\Python312\Lib\threading.py", line 1146, in _wait_for_tstate_lock
    if lock.acquire(block, timeout):
       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
KeyboardInterrupt

Process finished with exit code -1073741510 (0xC000013A: interrupted by Ctrl+C)


#提示[WinError 10054] 远程主机强迫关闭了一个现有的连接。


Python 全系列/第三阶段:Python 网络与并发编程/网络通信 2906楼
Python 全系列/第二阶段:Python 深入与提高/文件处理 2908楼

{90C0BF63-E79C-475D-9516-F6C6739A85DD}.png.jpg

WEB前端全系列/第十阶段:Nodejs编程模块/Node.js基础 2909楼
WEB前端全系列/第十阶段:Nodejs编程模块/Node.js基础 2910楼

课程分类

百战程序员微信公众号

百战程序员微信小程序

©2014-2025百战汇智(北京)科技有限公司 All Rights Reserved 北京亦庄经济开发区科创十四街 赛蒂国际工业园
网站维护:百战汇智(北京)科技有限公司
京公网安备 11011402011233号    京ICP备18060230号-3    营业执照    经营许可证:京B2-20212637