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

考虑移除 sys.dont_write_bytecode #27

Open
2 tasks
ZhaoQi99 opened this issue Aug 4, 2023 · 0 comments
Open
2 tasks

考虑移除 sys.dont_write_bytecode #27

ZhaoQi99 opened this issue Aug 4, 2023 · 0 comments
Labels

Comments

@ZhaoQi99
Copy link
Owner

ZhaoQi99 commented Aug 4, 2023

sys.dont_write_bytecode = True

依据cpython/Lib/importlib/_bootstrap_external.py ,生成.pyc文件的行为是Python原生的loader控制的...
所以使用自定义的loader时本身不会生成.pyc文件

  • 移除后是否有其他副作用,是否存在其他方式能拿到源码
  • 现有逻辑并不严谨,不移除的话,在decrypt时需要校验dont_write_bytecode的值
@ZhaoQi99 ZhaoQi99 added the TODO label Aug 4, 2023
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