CDR Tickets

Issue Number 5372
Summary Remove corrupted gen_py directory
Created 2025-03-05 17:05:40
Issue Type Improvement
Submitted By Kline, Robert (NIH/NCI) [C]
Assigned To Kline, Robert (NIH/NCI) [C]
Status Open
Resolved
Resolution
Path /home/bkline/backups/jira/ocecdr/issue.497157
Description

Sometimes the gen_py directory, which registers Python as a Windows scripting language, gets corrupted. Unfortunately, when that happens it is not sufficient to run the package's script to installs that directory, because that script doesn't do anything in that situation: it sees that the directory is already installed, but it doesn't detect the corruption. This ticket needs to do three things:

  • modify install-python.cmd adding a step to detect and remove gen_py

  • create a new script to just remove and recreate that directory

  • modify the instructions to explain this problem and its solution

Comment entered 2025-03-05 17:26:51 by Kline, Robert (NIH/NCI) [C]
Comment entered 2025-04-16 13:45:31 by Englisch, Volker (NIH/NCI) [C]

It appears that Robin's laptop is infected by this gen_py bug now.  

Do you already have a script available that we could test on her machine, ?

Comment entered 2025-04-16 15:54:12 by Kline, Robert (NIH/NCI) [C]

Yes. She'll need to get a fresh copy of the CDRSetup17 folder from the cdr_deployments share.

Comment entered 2025-04-16 16:52:48 by Englisch, Volker (NIH/NCI) [C]

We tried to run the script on Robin's laptop but the user is prompted to enter authentication for an admin user and Robin doesn't have the option to "run with elevated permission".

We will have to submit a CBIIT ticket to have them run the script for her.

Instructions for CBIIT:

  1. Close XMetaL

  2. Open the CDRSetup17 folder on the desktop

  3. Double-click the script "repair-python-scripting.cmd"

  4. Enter admin username/password

  5. When completed, open XMetaL to confirm the error messages are gone.

Comment entered 2025-04-16 17:40:05 by Kline, Robert (NIH/NCI) [C]

It's possible that running the script to install Python would work. This would be true if the mechanism CBIIT is using to allow users to run the setup scripts is to identify specific scripts which are approved for execution by a non-administrator. Unfortunately, we have been unable to get a clear explanation from them about how exactly the mechanism they're using actually works (I suspect most of them don't really know themselves). The incentives for proceding with your proposed approach described above are:

  • if the scripts have to be individually approved, then this new script will get the papal blessing

  • reinstalling Python would take longer

Elapsed: 0:00:00.001271