Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[debug]Windows二进制运行报错 #391

Open
RookieTerry opened this issue Mar 12, 2023 · 0 comments
Open

[debug]Windows二进制运行报错 #391

RookieTerry opened this issue Mar 12, 2023 · 0 comments
Labels

Comments

@RookieTerry
Copy link

RookieTerry commented Mar 12, 2023

描述问题 (Describe the bug)

如题

版本信息 (version info)

  • DDNS Version: 2.11.5
  • OS Version: Win10工作站专业版
  • Type(运行方式): Binary
  • related issues (相关问题): 无法读取相同目录下自定义配置文件

复现步骤 (To Reproduce)

电脑没有安装Python环境,在cmd命令行下运行:"C:\Users\xxx\AppData\Local\ddns.exe" -c "C:\Users\xxx\AppData\Local\config.json",其中配置文件和ddns.exe在同一目录下。

配置文件 (config file)

{
  "$schema": "https://ddns.newfuture.cc/schema/v2.8.json",
  "debug": false,
  "dns": "cloudflare",
  "index4": "url:https://myip4.ipip.net/",
  "index6": "url:https://myip6.ipip.net/",
  "ipv4": [
    "myurl"
  ],
  "ipv6": [
    "myurl",
  ],
  "proxy": null,
  "token": "mytoken",
  "ttl": null
}

调试输出 (debug output)

ERROR:root: Config file `config.json` does not exist!
Traceback (most recent call last):
  File "util\config.py", line 74, in __load_config
FileNotFoundError: [Errno 2] No such file or directory: 'config.json'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "run.py", line 159, in <module>
  File "run.py", line 120, in main
  File "util\config.py", line 64, in init_config
  File "util\config.py", line 82, in __load_config
PermissionError: [Errno 13] Permission denied: 'config.json'
[10576] Failed to execute script 'run' due to unhandled exception!
Traceback (most recent call last):
  File "<string>", line 1, in <module>
Traceback (most recent call last):
ValueError: underlying buffer has been detached
  File "<string>", line 1, in <module>
ValueError: underlying buffer has been detached
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant