gpt-engineer icon indicating copy to clipboard operation
gpt-engineer copied to clipboard

Enhance `--sysinfo` with version data and environment variable insights

Open Vikranth3140 opened this issue 6 months ago • 6 comments

This PR addresses #1194 by enhancing the --sysinfo command-line argument in the GPT-Engineer CLI tool. The --sysinfo argument now provides detailed system information, including the version of gpt-engineer and environment variables with sensitive data masked for security.

Changes Include:

  • New Functionality:
    • Added functions get_gpt_engineer_version and get_env_variables to retrieve version data and environment variables.
    • Updated get_system_info to include version and environment variable insights.
  • File Modifications:
    • Updated main.py to include the --sysinfo option and corresponding logic for gathering and displaying the additional information.

Usage:

To use the enhanced --sysinfo feature, run the following command:

python main.py --sysinfo

This will display the following information:

  • gpt-engineer Version
  • Operating System and Version
  • System Architecture
  • Python Version
  • Installed Python Packages and their Versions
  • Environment Variables (with sensitive data masked)

Example Output:

gpt_engineer_version: 0.1.0
os: Linux
os_version: #1 SMP Wed Dec 15 10:30:14 UTC 2021
architecture: x86_64
python_version: 3.10.2 (default, Jan 14 2022, 00:00:00) [GCC 7.5.0]
packages: {"typer": "0.4.0", "openai": "0.10.1", ...}
env_variables: {"OPENAI_API_KEY": "*****", "OTHER_VAR": "value"}

Notes:

  • This enhancement aims to help users and developers quickly gather essential system information, facilitating easier debugging and support.
  • Masking sensitive data in environment variables ensures security and compliance with best practices.

Please review the changes and provide feedback. Thank you!

Vikranth3140 avatar Jul 26 '24 14:07 Vikranth3140