def METHOD_NAME():
	import installer
	try:
		action = sys.argv[1]
	except IndexError:
		sys.exit("No action")
	args = sys.argv[2:]
	try:
		if action=="install":
			installer.install(bool(int(args[0])),bool(int(args[1])))
		elif action=="unregisterInstall":
			import installer
			installer.unregisterInstallation()
		elif action=="fixCOMRegistrations":
			import COMRegistrationFixes
			COMRegistrationFixes.fixCOMRegistrations()
		elif action=="launchNVDA":
			import subprocess
			import shellapi
			import winUser
			shellapi.ShellExecute(0,None,
				r"%s\nvda.exe"%sys.prefix,
				subprocess.list2cmdline(args),
				None,winUser.SW_SHOWNORMAL)
		elif action=="setNvdaSystemConfig":
			import config
			config._setSystemConfig(args[0])
		elif action == "config_setStartOnLogonScreen":
			enable = bool(int(args[0]))
			import config
			config._setStartOnLogonScreen(enable)
		elif action == "explore_userConfigPath":
			ret = getNvdaHelperRemote().nvdaControllerInternal_openConfigDirectory()
			if ret != 0:  # NVDA is not running
				import systemUtils
				systemUtils.openDefaultConfigurationDirectory()
		elif action == "addons_installAddonPackage":
			try:
				addonPath=args[0]
			except IndexError:
				raise ValueError("Addon path was not provided.")
			ret = getNvdaHelperRemote().nvdaControllerInternal_installAddonPackageFromPath(addonPath)
			if ret != 0:
				import winUser
				winUser.MessageBox(0,
				# Translators: the message that is shown when the user tries to install an add-on from windows explorer and NVDA is not running.
				_("Cannot install NVDA add-on from {path}.\n"
				"You must be running NVDA to be able to install add-ons.").format(path=addonPath),
				0, winUser.MB_ICONERROR)
		elif action == "comGetActiveObject":
			import comHelper
			# py2exe scraps sys.stdout.
			sys.__stdout__.write("%s\n" %
				comHelper._lresultFromGetActiveObject(args[0], bool(int(args[1]))))
			sys.__stdout__.flush()
			try:
				input()
			except EOFError:
				pass
		else:
			raise ValueError("No such action")
	except installer.RetriableFailure:
		logHandler.log.error("Task failed, try again",exc_info=True)
		sys.exit(2)
	except Exception as e:
		logHandler.log.error("slave error",exc_info=True)
		sys.exit(1)