Python Forum
How to ignore - ERROR: The system was unable to find the specified registry key or va
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to ignore - ERROR: The system was unable to find the specified registry key or va
#1
def isAlreadyInstalled(lookupRegistryKey):
    consoleLines = os.popen('reg query "' + APP_REGISTRY_KEY + "\\" + VERSION_SYSTEM_NAME + '"').readlines()
    if len(consoleLines) == 0:
        return False
    return True
I have this snippet. The problem is that it gives this error in the command line without stoping the execution ( wich is ok for my cas), I just want to ignore this error.

ERROR: The system was unable to find the specified registry key or value.
Reply


Messages In This Thread
How to ignore - ERROR: The system was unable to find the specified registry key or va - by asheru93 - Feb-01-2019, 10:04 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
Question How to add Python folder in Windows Registry ? Touktouk 1 248 Feb-20-2024, 01:04 PM
Last Post: DeaD_EyE
  FileNotFoundError: [WinError 2] The system cannot find the file specified NewBiee 2 1,562 Jul-31-2023, 11:42 AM
Last Post: deanhystad
  Read complete windows registry? fredep57 3 936 Mar-15-2023, 08:14 PM
Last Post: buran
  Error when using FIND WJSwan 2 889 Jan-27-2023, 05:49 AM
Last Post: deanhystad
  Ignore WakeWord after it's said Extra 2 1,175 Apr-01-2022, 12:32 AM
Last Post: Extra
  How to ignore "Retrying (Retry(total=2, connect=2, read=5, redirect=5, status=None))" const 3 2,694 Mar-26-2022, 08:55 AM
Last Post: ndc85430
  Error in find pearson correlation function erneelgupta 1 1,859 Mar-01-2022, 03:41 PM
Last Post: stevendaprano
  Getting 'NoneType' object has no attribute 'find' error when WebScraping with BS Franky77 2 5,248 Aug-17-2021, 05:24 PM
Last Post: Franky77
Exclamation "System cannot find path specified"(Geany) kiwi99 2 3,861 Mar-18-2021, 07:37 PM
Last Post: kiwi99
  How to add new registry key shlomi27 3 10,297 Feb-04-2021, 05:45 PM
Last Post: reidnax

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020