VULN_CHECK_I913V6 j"ldZddlZddlZddlZddlZddlZddlZddlZddlmZddl m Z m Z m Z m Z mZddlmZddlmZddlmZddlmZmZdd lmZmZmZmZdd lmZmZm Z m!Z!m"Z"m#Z#m$Z$dd l%m&Z&dd l'm(Z(m)Z)dd l*m+Z+m,Z,ddl-m.Z/ddl-m0Z0m1Z1ddl2m3Z3dgZ4ejje6Z7GddeZ8y)z(Base Command class, and related routinesN)Values)AnyCallableListOptionalTuple) traceback) cmdoptions)CommandContextMixIn)ConfigOptionParserUpdatingDefaultsHelpFormatter)ERRORPREVIOUS_BUILD_DIR_ERROR UNKNOWN_ERRORVIRTUALENV_NOT_FOUND) BadCommand CommandErrorDiagnosticPipErrorInstallationErrorNetworkConnectionErrorPreviousBuildDirErrorUninstallationError)check_path_owner)BrokenStdoutLoggingError setup_logging)get_prognormalize_path)TempDirectoryTypeRegistry)global_tempdir_managertempdir_registry)running_under_virtualenvCommandc eZdZUdZeed<dZeed<ddedededd ffd Zdd Z d e dd fd Z d e de ede fdZde edee e effdZde ede fdZde ede fdZxZS)r"usageFignore_require_venvnamesummaryisolatedreturnNc t|||_||_t |j t d|td||j||_ d|_ |jjd}tj|j||_tj tj"|j}|jj%||j'y)N F)r%prog formatteradd_help_optionr' descriptionr)z Options)super__init__r'r(r r%rr __doc__parserr capitalizeoptparse OptionGroupcmd_optsr make_option_group general_groupadd_option_group add_options)selfr'r(r) optgroup_namegen_opts __class__s C/usr/lib/python3.12/site-packages/pip/_internal/cli/base_command.pyr2zCommand.__init__1s   (**JrVtA|j>|_tC|j>s'tjd |j>d|_d tDd tFfdtDd tFfffd } |jHs||jJ}n"|jJ}tMjNd||||jQ|S#|jQ|wxYw)N) verbosityno_color user_log_filez/The following features are always enabled: %s. z, _PIP_RUNNING_IN_SUBPROCESSzAThe --python option must be placed before the pip subcommand name1 PIP_NO_INPUTr,PIP_EXISTS_ACTIONz2Could not find an activated virtualenv (required).zThe directory '%s' or its parent directory is not owned or is not writable by the current user. The cache has been disabled. Check the permissions and owner of that directory. If executing pip with sudo, you should use sudo's -H flag.run_func.r*c`tjdtdtffd }|S)NrIr*c |}|S#t$rA}tjd|dditjddtcYd}~Sd}~wt $rE}tj t|tjddtcYd}~Sd}~wttttf$rE}tj t|tjddtcYd}~Sd}~wt$r=}tj d|tjddtcYd}~Sd}~wt$r[tdt j"t$j&kr$t)j*t j"tcYSt,$r5tj d tjddtcYSt.$r tj d dt0cYSwxYw) Nz%srichT)extrazException information:)exc_infoz ERROR: Pipe to stdout was broken)filezOperation cancelled by userz Exception:)rloggererrordebugrrcriticalstrrrrrrrrprintsysstderrrSDEBUGr print_excKeyboardInterrupt BaseExceptionr)rIstatusexc level_numberr^s rAexc_logging_wrapperzLCommand._main..intercepts_unhandled_exc..exc_logging_wrapperss-)%t_F!M)!LLs64.LALL!9DLI L,4OOCH-LL!9DLI33%'*  ! OOCH-LL!9DLI L#!OOD#.LL!9DLI L/!<3::N#w}}4!++< L(!OO$ABLL!9DLI L$)OOL4O@(()sc H6A H H:BHH7:C71H7 H2D;5H;A$H!:H%HH) functoolswrapsrint)r^rtrss` rAintercepts_unhandled_excz/Command._main..intercepts_unhandled_excs7__X &. )3. )3. )'. )`' &rBT) show_locals)) enter_contextr rrNverbosequietrWrrXlogsetfeatures_enabledr ALWAYS_ENABLED_FEATURESrewarningjoinsortedpythonosenvironrhrkexitrno_input exists_action require_venvr&r!r cache_dirrrrrw debug_moderLrich_tracebackinstallrH)r=rIrFalways_enabled_featuresrxrLrss @rArRz Command._mainis<!% 2 23C3E F 134- !7==8$nn%%!++ #&g&>&>"?#  . .C #  # NNA &!89:  >>:"**L OOS  HHUO   ),BJJ~ &  .1hhw7L7L.MBJJ* +   (@(@+- TU-.    .w/@/@ AG #G$5$56* %% %)!4 'sCx(4 ' c3h 4 'l 3%%.txx8hh&&48w%  ) )' 2D ) )' 2s 0A K K)F)r*N)__name__ __module__ __qualname__r%ri__annotations__r&boolr2r<rrHrrwrLrrNrUrR __classcell__)r@s@rAr"r"-sE3O %%S3$4< 0040"6"c"s",tCy,U6493D-E,csC3$s)C3C3rB)9r3rurSlogging.configr6rrkr rtypingrrrrrpip._vendor.richrpip._internal.clir !pip._internal.cli.command_contextr pip._internal.cli.parserr r pip._internal.cli.status_codesrrrrpip._internal.exceptionsrrrrrrrpip._internal.utils.filesystemrpip._internal.utils.loggingrrpip._internal.utils.miscrrpip._internal.utils.temp_dirrTempDirRegistryrr pip._internal.utils.virtualenvr!__all__ getLoggerrrer"rErBrArs. 778(AV <O=UQC +   8 $3!3rB