edkrepo_installer/EdkRepoInstaller/InstallWorker.cs | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-)
pip does not support '_' in package names and converts them to
'-' after installing the wheel. In order to uninstall affected
packages the '_' needs to be converted to a '-' when calculating
the package name.
Cc: Ashley DeSimone <ashley.e.desimone@intel.com>
Cc: Puja Pandya <puja.pandya@intel.com>
Cc: Erik Bjorge <erik.c.bjorge@intel.com>
Cc: Bret Barkelew <Bret.Barkelew@microsoft.com>
Signed-off-by: Nate DeSimone <nathaniel.l.desimone@intel.com>
---
edkrepo_installer/EdkRepoInstaller/InstallWorker.cs | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/edkrepo_installer/EdkRepoInstaller/InstallWorker.cs b/edkrepo_installer/EdkRepoInstaller/InstallWorker.cs
index 5a358f9..f9738fd 100644
--- a/edkrepo_installer/EdkRepoInstaller/InstallWorker.cs
+++ b/edkrepo_installer/EdkRepoInstaller/InstallWorker.cs
@@ -550,10 +550,16 @@ namespace TianoCore.EdkRepoInstaller
{
if (VendorCustomizer.Instance.GetPythonWheelsToUninstall != null)
{
- return VendorCustomizer.Instance.GetPythonWheelsToUninstall();
+ //
+ // pip doesn't understand the difference between '_' and '-'
+ //
+ return VendorCustomizer.Instance.GetPythonWheelsToUninstall().Select(p => p.Replace('_', '-'));
}
}
- return new string[] { InstallerStrings.EdkrepoPackageName };
+ //
+ // pip doesn't understand the difference between '_' and '-'
+ //
+ return (new string[] { InstallerStrings.EdkrepoPackageName }).Select(p => p.Replace('_', '-'));
}
public void PerformInstall(Action<bool, bool> ReportComplete, Action<int> ReportProgress, Action<bool> AllowCancel, Func<bool> CancelPending)
--
2.24.0.windows.2
-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#55901): https://edk2.groups.io/g/devel/message/55901
Mute This Topic: https://groups.io/mt/72004232/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-
Reviewed-by: Ashley DeSimone <ashley.e.desimone@intel.com>
-----Original Message-----
From: Desimone, Nathaniel L <nathaniel.l.desimone@intel.com>
Sent: Monday, March 16, 2020 10:33 AM
To: devel@edk2.groups.io
Cc: Desimone, Ashley E <ashley.e.desimone@intel.com>; Pandya, Puja <puja.pandya@intel.com>; Bjorge, Erik C <erik.c.bjorge@intel.com>; Bret Barkelew <Bret.Barkelew@microsoft.com>
Subject: [edk2-staging/EdkRepo] [PATCH] EdkRepo: Uninstaller does not uninstall packages with '_' in their name.
pip does not support '_' in package names and converts them to '-' after installing the wheel. In order to uninstall affected packages the '_' needs to be converted to a '-' when calculating the package name.
Cc: Ashley DeSimone <ashley.e.desimone@intel.com>
Cc: Puja Pandya <puja.pandya@intel.com>
Cc: Erik Bjorge <erik.c.bjorge@intel.com>
Cc: Bret Barkelew <Bret.Barkelew@microsoft.com>
Signed-off-by: Nate DeSimone <nathaniel.l.desimone@intel.com>
---
edkrepo_installer/EdkRepoInstaller/InstallWorker.cs | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/edkrepo_installer/EdkRepoInstaller/InstallWorker.cs b/edkrepo_installer/EdkRepoInstaller/InstallWorker.cs
index 5a358f9..f9738fd 100644
--- a/edkrepo_installer/EdkRepoInstaller/InstallWorker.cs
+++ b/edkrepo_installer/EdkRepoInstaller/InstallWorker.cs
@@ -550,10 +550,16 @@ namespace TianoCore.EdkRepoInstaller
{
if (VendorCustomizer.Instance.GetPythonWheelsToUninstall != null)
{
- return VendorCustomizer.Instance.GetPythonWheelsToUninstall();
+ //
+ // pip doesn't understand the difference between '_' and '-'
+ //
+ return
+ VendorCustomizer.Instance.GetPythonWheelsToUninstall().Select(p =>
+ p.Replace('_', '-'));
}
}
- return new string[] { InstallerStrings.EdkrepoPackageName };
+ //
+ // pip doesn't understand the difference between '_' and '-'
+ //
+ return (new string[] { InstallerStrings.EdkrepoPackageName
+ }).Select(p => p.Replace('_', '-'));
}
public void PerformInstall(Action<bool, bool> ReportComplete, Action<int> ReportProgress, Action<bool> AllowCancel, Func<bool> CancelPending)
--
2.24.0.windows.2
-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#55934): https://edk2.groups.io/g/devel/message/55934
Mute This Topic: https://groups.io/mt/72004232/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-
© 2016 - 2026 Red Hat, Inc.