We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
1.0b4.dev1
Windows 10
Intel(R) Core(TM) i7-7700HQ CPU @ 2.80GHz
我希望实现的功能是:将某个待处理文件拖拽至exe上进行处理。当文件被拖拽到exe上时,可通过sys.argv[1]获取待处理文件路径,将该路径输入到我的业务代码中。
当我在python环境中执行:python main.py path\to\my\file时,此时的sys.argv[1]为path\\to\\my\\file,代码执行正常。
当我在cmd中执行:Debug.exe path\to\my\file时,提示转义符的问题: SyntaxError: (unicode error) 'unicodeescape' codec can't decode bytes in position 4-5: truncated \UXXXXXXXX escape
将路径改为/或者\\之后,可以正常执行,但是这样无法实现前面说的将文件拖拽到exe上执行的方案。
The text was updated successfully, but these errors were encountered:
之前测试的时候没考虑过拖动的这个情况,加入ToDo后续修复
Sorry, something went wrong.
最新版本1.0b7已经适配,预计11.28日前同步各大pip镜像源,感谢支持。
GT-ZhangAcer
No branches or pull requests
QPT版本
1.0b4.dev1
操作系统版本
Windows 10
CPU型号
Intel(R) Core(TM) i7-7700HQ CPU @ 2.80GHz
核心信息填写
我希望实现的功能是:将某个待处理文件拖拽至exe上进行处理。当文件被拖拽到exe上时,可通过sys.argv[1]获取待处理文件路径,将该路径输入到我的业务代码中。
当我在python环境中执行:python main.py path\to\my\file时,此时的sys.argv[1]为path\\to\\my\\file,代码执行正常。
当我在cmd中执行:Debug.exe path\to\my\file时,提示转义符的问题:
SyntaxError: (unicode error) 'unicodeescape' codec can't decode bytes in position 4-5: truncated \UXXXXXXXX escape
将路径改为/或者\\之后,可以正常执行,但是这样无法实现前面说的将文件拖拽到exe上执行的方案。
The text was updated successfully, but these errors were encountered: