简体   繁体   English

如何防止每次运行脚本时显示 Python 之禅?

[英]How do I prevent The Zen of Python from displaying every time I run a script?

Ever since I set pd.options.mode.chained_assignment = None The Zen of Python prints to the terminal every time I run a script!自从我设置pd.options.mode.chained_assignment = None每次我运行脚本时,Python 的禅宗都会打印到终端! This isn't good for production.这对生产不利。 I have tried switching back and it still prints.我试过切换回来,它仍然打印。 How do I disable this?如何禁用此功能?

Also, does options.mode.chained_assignment disable chained assignment or disable the warning?另外, options.mode.chained_assignment是否禁用链式分配或禁用警告?

果然我有一条线import this

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 每当我使用python在appium中运行测试时,如何防止安装app? - How to prevent app from installing every time i run an test in appium using python? 如何每天使用调度程序同时运行python脚本? - How do I run python script everyday at the same time with scheduler? 如何从 Photoshop 脚本运行 Python 脚本? - How do I run a Python script from a Photoshop script? 每次启动新项目时,如何防止PyCharm创建virtualenv? - How do I prevent PyCharm from creating a virtualenv every time I start a new project? 每次使用 Keras 开始新的训练 session 时,如何防止丢失和准确性重新开始? - How do I prevent loss and accuracy from restarting every time I start a new training session with Keras? 每次在Python中运行代码时,如何以相同的顺序随机化pandas列? - How do I randomize a pandas column in the same order every time I run the code in Python? 每次完成后,如何自动运行我的 python 脚本以再次运行? - How can I automate my python script to run again after every time it finished? 如何安排python脚本在特定时间每天运行? (Windows计划除外) - How can I Schedule python script to run every day at specific time ? (except Windows schedule) 如何使用 Python 中的参数运行 PowerShell 脚本 - How do I run a PowerShell script with parameters from Python 如何从文件中运行python脚本? (UNIX) - How do I run a python script from a file? (UNIX)
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM