code: def _get_environment_details(python_bin: str) -> list:
      
      cmd = "{} -m pipdeptree --json".format(python_bin)
      output = run_command(cmd, is_json=True).stdout
      return [_create_entry(entry) for entry in output]
docs: Get information about packages in environment where packages get installed.