CondaInterface/CondaInfoDialog.py

branch
conda
changeset 6730
35576138c927
parent 6724
ca89c7d94c94
child 6737
26a4738dd206
equal deleted inserted replaced
6729:fea66bcabb33 6730:35576138c927
41 self.condaVersionLabel.setText( 41 self.condaVersionLabel.setText(
42 infoDict["conda_version"]) 42 infoDict["conda_version"])
43 if "conda_build_version" in infoDict: 43 if "conda_build_version" in infoDict:
44 self.condaBuildVersionLabel.setText( 44 self.condaBuildVersionLabel.setText(
45 infoDict["conda_build_version"]) 45 infoDict["conda_build_version"])
46 # TODO: add 'conda_env_version
46 if "python_version" in infoDict: 47 if "python_version" in infoDict:
47 self.pythonVersionLabel.setText( 48 self.pythonVersionLabel.setText(
48 infoDict["python_version"]) 49 infoDict["python_version"])
49 if "active_prefix" in infoDict and "active_prefix_name" in infoDict: 50 if "active_prefix" in infoDict and "active_prefix_name" in infoDict:
50 if infoDict["active_prefix_name"] and infoDict["active_prefix"]: 51 if infoDict["active_prefix_name"] and infoDict["active_prefix"]:
58 self.activeEnvironmentEdit.setText( 59 self.activeEnvironmentEdit.setText(
59 infoDict["active_prefix_name"]) 60 infoDict["active_prefix_name"])
60 else: 61 else:
61 self.activeEnvironmentEdit.setText( 62 self.activeEnvironmentEdit.setText(
62 self.tr("None")) 63 self.tr("None"))
64 else:
65 self.activeEnvironmentEdit.setText(
66 self.tr("Unknown"))
63 if "rc_path" in infoDict: 67 if "rc_path" in infoDict:
64 self.userConfigEdit.setText( 68 self.userConfigEdit.setText(
65 infoDict["rc_path"]) 69 infoDict["rc_path"])
66 if "user_rc_path" in infoDict: 70 if "user_rc_path" in infoDict:
67 # overwrite with more specific info 71 # overwrite with more specific info
90 self.envDirsEdit.setPlainText( 94 self.envDirsEdit.setPlainText(
91 "\n".join(infoDict["envs_dirs"])) 95 "\n".join(infoDict["envs_dirs"]))
92 if "platform" in infoDict: 96 if "platform" in infoDict:
93 self.platformLabel.setText( 97 self.platformLabel.setText(
94 infoDict["platform"]) 98 infoDict["platform"])
99 # TODO: suppress user_agent, UID/GID and netrc_file if not present
95 if "user_agent" in infoDict: 100 if "user_agent" in infoDict:
96 self.useragentEdit.setText( 101 self.useragentEdit.setText(
97 infoDict["user_agent"]) 102 infoDict["user_agent"])
98 if "UID" in infoDict and "GID" in infoDict: 103 if "UID" in infoDict and "GID" in infoDict:
99 self.uidGidLabel.setText( 104 self.uidGidLabel.setText(
106 self.netrcEdit.setText( 111 self.netrcEdit.setText(
107 self.tr("None")) 112 self.tr("None"))
108 if "offline" in infoDict: 113 if "offline" in infoDict:
109 self.offlineCheckBox.setChecked( 114 self.offlineCheckBox.setChecked(
110 infoDict["offline"]) 115 infoDict["offline"])
116
117 msh = self.minimumSizeHint()
118 self.resize(max(self.width(), msh.width()), msh.height())

eric ide

mercurial