""" Simple Python version test """ import gradio as gr import sys import platform def get_python_info(): """Get Python version information""" info = f""" ## Python Environment Info - **Python Version**: {sys.version} - **Python Executable**: {sys.executable} - **Platform**: {platform.platform()} - **Machine**: {platform.machine()} - **Processor**: {platform.processor()} ### Python Version Check - Major: {sys.version_info.major} - Minor: {sys.version_info.minor} - Micro: {sys.version_info.micro} ### Is Python 3.11+? {"✅ YES - Python 3.11 or higher!" if sys.version_info >= (3, 11) else "❌ NO - Running Python " + str(sys.version_info.major) + "." + str(sys.version_info.minor)} """ return info # Create simple interface demo = gr.Interface( fn=get_python_info, inputs=[], outputs=gr.Markdown(label="Python Info"), title="🐍 Python Version Test", description="Click Submit to check Python version on this HF Space", allow_flagging="never" ) if __name__ == "__main__": demo.launch()