ML iVUdZddlmZddlZddlZddlZddlZddlZddlm Z ddl m Z ddl m Z ddl mZddlmZmZmZmZmZmZdd lmZmZmZmZdd lmZmZmZmZdd l m!Z!dd l"m#Z#dd l$m%Z%m&Z&ddl'm(Z(ddl)m*Z*m+Z+m,Z,m-Z-m.Z.m/Z/ddl0m1Z1m2Z2m3Z3ddl4m5Z5ddl6m7Z7erddl8m9Z9ejtZ;dedeZ^ddd? dPd@Z_y)Qz$Mypy type checker command line tool.) annotationsN) defaultdict)Sequence)gettext) TextIOWrapper)IO TYPE_CHECKINGAnyFinalNoReturnTextIO)builddefaultsstateutil)get_config_module_namesparse_config_file parse_versionvalidate_package_allow_list)OUTPUT_CHOICES) CompileError)InvalidSourceListcreate_source_list)FileSystemCache) BuildSourceFindModuleCacheModuleNotFoundReason SearchPathsget_search_dirs mypy_path)INCOMPLETE_FEATURES BuildTypeOptions)SplitNamespace) __version__) SupportsWriter orig_statF MEM_PROFILEi@RECURSION_LIMITc t|}td||j|j|jfz|S#t $r}td|d|d}~wwxYw)Nz1stat(%r) -> (st_mode=%o, st_mtime=%d, st_size=%d)zstat(z) -> )r'printst_modest_mtimest_sizeOSError)pathsterrs O/mnt/ssd/data/python-lab/Trading/venv/lib/python3.12/site-packages/mypy/main.py stat_proxyr40sk  t_  ?RZZbjj9 :    dXU3%() s ? AAA)argsstdoutstderr clean_exitctjdtj}tjt |tj dd}t|tr!|jdk(r|jdt}t||||\}}|rd|_ tj|||jt!|j" }|j$r|j&s t)d |||j*r1|tj,us|tj.ur t)d |||j0r|j*s t)d |||j*r|j2s t)d |||j*r|j4 t)d|||j*r|st+|||j0yt7||||||\} } } |j0rdt9|j:d} | r=t+||dd|j=t?t7||||||\} } } tA| |||tBr ddl"m#} | d}tjH| \}}}| r|tK| kr| rdnd}|jLr|r>|jO||tK|| |jP}|jS|dznG| r|tK| k(r7|jS|jUtK||jPdz|j=|j*r4|j0s(t+||dd}|rt?t?dd}|jrtjV|n|rtjX|t[| gy)zMain entry point to the type checker. Args: args: Custom command-line arguments. If not given, sys.argv[1:] will be used. clean_exit: Don't hard kill the process on exit. This allows catching SystemExit. mypyNstrictbackslashreplace)errors)r6r7fscacheF hide_successzNerror: --local-partial-types must be enabled if using --allow-redefinition-newzAerror: --install-types not supported in this mode of running mypyz?error: --non-interactive is only supported with --install-typeszCerror: --install-types not supported with incremental mode disabledzOerror: --install-types not supported without python executable or site packages)non_interactiveT) after_runrCrBr)print_memory_profile)blockers use_color z@note: Run mypy again for up-to-date results with installed types).rcheck_python_versiontimesyssetrecursionlimitr)argv isinstancerr> reconfigurerprocess_options fast_exitFancyFormatterhide_error_codesbooloutputallow_redefinition_newlocal_partial_typesfail install_typesr6r7rB incrementalpython_executable run_buildread_types_packages_to_install cache_dirflushr+ show_messagesr(mypy.memprofilerE count_statslen error_summary format_error color_outputwriteformat_success hard_exitexitlist)r5r6r7r8t0r?sourcesoptions formatterresmessagesrG missing_pkgsrEcoden_errorsn_notesn_filessummaryresults r3mainrz>sG f% B/* |xx|&-(V]]h-F"45G&tF6SZ[GW!##00tGNN?SI%%g.I.I \   & ":fCJJ>V PRXZabw'<'< NPVX_`W%8%8 QSY[b !:!:!B ]   Wi':Q:QR''2vvVC85g6G6GSWX  )Wd S MMO G&/'2vW]&^ #C8h 7;8 D!%!1!1(!;HgwGc(m+q! ,,'3w<(gNbNb-G LL4 (WH 5 LL11#g,@T@TUX\\ ] W%<%<y'TSXY  G T UD t   #Kc  tjjtj g t t d fd }d}d}d} tj|d||} jrjrjs{jsotdjj t#j j$j'D cgc]} | jvr| c} t)t+j*|z | | |fS#t$r} d}| jsd}Yd} ~ d} ~ wwxYwcc} w)Nr@cjrj|}j||r|j|jry|rn }t ||yN)prettyfit_in_terminalextendrBra) filename new_messagesseriousfrprrmessages_by_fileror7r6s r3 flush_errorszrun_build..flush_errorss_ >>$44\BL %  X & - -l ;  " " F6lAy':r{FTz$Warning: unused section(s) in {}: {})file)r str | Noner list[str]rrUreturnNone)rrSrTrUrVrrlrr use_stdoutwarn_unused_configsunused_configsr[rBr+format config_filerper_module_optionskeysmaybe_write_junit_xmlrK)rnror?rmr6r7rrrGrqeglobrprrrs ` `` @@@r3r]r]s`##00tGNN?SIH"4( ; ;GH Ckk'7D,QWX ##  " "##'' 2 9 9##'''%,$>$>$C$C$E 7#9#99  $))+*GX?OQXY ( ""3 ||Gs E2E) E& E!!E&c|D]3}|jr|j|}|j|dz5|jyNrI)rgcolorizerhr`)rrrrpromsgs r3rarasG   $$S)C d GGIr{c,eZdZdfd Zdfd ZxZS)AugmentedHelpFormatterc *t|d|dd|y)N)progmax_help_position)super__init__)selfrkwargs __class__s r3rzAugmentedHelpFormatter.__init__s CdbCFCr{crd|vrt||||Stjj||||Sr)r _fill_textargparse HelpFormatter)rtextwidthindentrs r3rz!AugmentedHelpFormatter._fill_texts= 4<7%dE6: :))44T4O Or{)rstrrr rr)rrrintrrrr)__name__ __module__ __qualname__rr __classcell__rs@r3rrsDPPr{r)allowdisallow)showhideflag_prefix_pairszFinal[dict[str, str]]flag_prefix_mapc|ddjdd}t|dk(r&|\}}|tvrdt|d|S|dk(rd|Sd|ddS)NrF-r;--noz--no-)splitrdr)flagrprefixrests r3invert_flag_namerss HNN3 "E 5zQ  _ $/0$8 8 t^v;  48* r{ceZdZdZy)PythonExecutableInferenceErrorzHRepresents a failure to infer the version or executable while searching.N)rrr__doc__rr{r3rrsRr{rcBtjdk(rdd|gSd|gS)Nwin32pyrpython)rLplatform)vs r3python_executable_prefixr!s. ||w !g ~r{ctjdd|k(rtjSdjt t |} t jt|ddgzt jjj}|S#t jtf$r }tdj||d}~wwxYw)NrF.-cz!import sys; print(sys.executable))r7zofailed to find a Python executable matching version {}, perhaps try --python-executable, or --no-site-packages?)rL version_info executablejoinmapr subprocess check_outputrSTDOUTdecodestripCalledProcessErrorFileNotFoundErrorrr)python_versionstr_versys_exers r3_python_executable_from_versionr,s ~-~~hhs3/0G  # #(1T;^4__!(( VX UW   ) )+< =, GGMvnG]  sABC1C  Cc|jxs |j}|-|js!|jst|j}||_y)zInfer the Python executable from the given version. This function mutates options based on special_opts to infer the correct Python executable to use. N)r\ no_executableno_site_packagesrr)ro special_optsr\s r3infer_python_executablerAsK%66S':S:S ))'2J2J ?@V@V W  1Gr{zt%(prog)s [-h] [-v] [-V] [more options; see below] [-m MODULE] [-p PACKAGE] [-c PROGRAM_TEXT] [files ...]HEADERa Mypy is a program that will type check your Python code. Pass in any files or folders you want to type check. Mypy will recursively traverse any provided folders to find .py files: $ mypy my_program.py my_src_folder For more information on getting started, see: - https://mypy.readthedocs.io/en/stable/getting_started.html For more details on both running mypy and using the flags below, see: - https://mypy.readthedocs.io/en/stable/running_mypy.html - https://mypy.readthedocs.io/en/stable/command_line.html You can also use a config file to configure mypy instead of using command line flags. For more details, see: - https://mypy.readthedocs.io/en/stable/config_file.html DESCRIPTIONzEnvironment variables: Define MYPYPATH for additional module search path entries. Define MYPY_CACHE_DIR to override configuration cache_dir path.FOOTERcTeZdZdZdfd Zd d dZd d dZd d dZd d dZddZ xZ S)CapturableArgumentParserzOverride ArgumentParser methods that use sys.stdout/sys.stderr directly. This is needed because hijacking sys.std* is not thread-safe, yet output must be captured to properly support mypy.api.run. c|jdtj|_|jdtj|_t ||i|y)Nr6r7)poprLr6r7rr)rr5rrs r3rz!CapturableArgumentParser.__init__|sAjj3::6 jj3::6  $)&)r{c`| |j}|j|j|yr~)r6_print_message format_usagerrs r3 print_usagez$CapturableArgumentParser.print_usages) <;;D D--/6r{c`| |j}|j|j|yr~)r6r format_helprs r3 print_helpz#CapturableArgumentParser.print_helps) <;;D D,,.5r{cH|r | |j}|j|yyr~)r7rh)rmessagers r3rz'CapturableArgumentParser._print_messages$ |{{ JJw  r{cj|r|j||jtj|yr~)rr7rLrk)rstatusrs r3rkzCapturableArgumentParser.exits%     5 r{c|j|j|j|d}|jdt d|zy)zerror(message: string) Prints a usage message incorporating the message to stderr and exits. If you override this in a subclass, it should not return -- it should either exit or raise an exception. )rrrFz%(prog)s: error: %(message)s N)rr7rrkr)rrr5s r3errorzCapturableArgumentParser.errors= % g6 !W=>EFr{)r5r rr rrr~)rSupportsWrite[str] | Nonerr)rrrrrr)rN)rrrrrr )rrrr ) rrrrrrrrrkrrrs@r3rrus' *7 6   Gr{rceZdZdZej ej ddf dfd Z d ddZxZS) CapturableVersionActionatSupplement CapturableArgumentParser to handle --version. This is nearly identical to argparse._VersionAction except, like CapturableArgumentParser, it allows output to be captured. Another notable difference is that version is mandatory. This allows removing a line in __call__ that falls back to parser.version (which does not appear to exist). z&show program's version number and exitNcnt||||d|||_|xstj|_y)Nr)option_stringsdestdefaultnargshelp)rrversionrLr6)rrrrrrr6rs r3rz CapturableVersionAction.__init__s< )gQUY   *  r{c|j}|j|j|j|j |j |j yr~)_get_formatteradd_textrrrr6rk)rparser namespacevalues option_stringrps r3__call__z CapturableVersionAction.__call__sJ))+ 4<<(i335t{{C r{)rz Sequence[str]rrrrrrrrr6zIO[str] | Nonerrr~) rargparse.ArgumentParserrargparse.Namespacer zstr | Sequence[Any] | Noner rrr ) rrrrrSUPPRESSrr rrs@r3rrs%%((d?d@dAdBC| j dDd5dEdF| j dGd5dH j dIdJ%} | j dKtdLdMdNO| j dPd?dQdRS| j dTdUdVgdWX| j dYdUdVgdZXj d[d\%} | j d]dd5d^_| j d`dd5da_| j dbdd5dc_|dddd+de| -|dfddg| h|didd+dj| -j dkdl%} |dmdd+dn| -| j dodpdVgdqX|drdd+ds| -|dtdd+du| -|dvdd+dw| -|dxdd+dy| -j dzd{%} |d|dd}| h| j d~d5t j" | j dddd|ddt j"| h|ddt j"| hj dd%}|ddd+d|-|ddd+d|-|ddd+d|3|ddd+d|-|dddd|-|dddd|-|j ddpdVgdXj d }|dddd|-|dddd|-|dddd|-|dd+d+dd||ddd+d|-|dddd|-|ddd+d|-|ddd+d|-dj%d(j}|j dd5d||j ddUdVgdX|j ddUdVgdXj dd%}|dddd||ddd|h|ddd|h|ddd|h|ddd|h|ddd|h|ddd+d|3|ddd+d|3|ddd|h|j dtj&t(dt j"ʫj dd̬%}|j ddd5t j" |j ddddѬ|j dd?ddj%tj*S|ddd|h|j dd5dج |j dd5|dk(rdnt j" |j dd5dܬ |j dd5dެ j dd%}|j dd5d |j ddd5d |j dd5d |j ddpdd|j dd5t j" |j dd5t j" j ddVddjt-t.zdzdS|j ddd|ddd|h|j dddddVd|j dd5t j" |j dddt j"|ddt j"|h|j dd5t j" j dd%}t-tj0D];}|dvs |j d|j3ddd dӐd |d  =|j d dt4dt j"|j ddd5t j"j d }|j dt j")|j dd)| j dddgdd=|j dddd|j dd5d |d!ddd"|-|d#ddd$|d%&|r.|j d'd5d(d)|j d*d5d+ j d,d5d-t j"j d.d5d/t j"j d0d5t j" j d1d2t j"3j d4d5t j"3j d6d5t j" j d7d5t j" j d8d5t j" j d9d5t j" j d:d5t j" |d;dt j"<j d=d5t j" j d>d5t j" j d?d@dVgt j"Xj dAdBdCt j"Dj dEd5t j" j dFd5t j" j dGd5t j" j dHd5t j" j dIdJ%}|dKddL|h|dMdt j"|h|j dNdVdOgdPQ|dRddS|h|j dTdUdVdpgdVdWX|j dYdZdVd[gd\d]X|j d^d_dVd`dadbc|j dddedfdghfS(jaDefine the options in the parser (by calling a bunch of methods that express/build our desired command-line flags). Returns a tuple of: a parser object, that can parse command line arguments to mypy (expected consumer: main's process_options), a list of what flags are strict (expected consumer: docs' html_builder's _add_strict_list), strict_flag_assignments (expected consumer: main's process_options).@F) rusage descriptionepilogfromfile_prefix_charsformatter_classadd_helpr6r7N)inverser strict_flaggrouprcN| t|}|}|tjur |d|dz }|j||rdnd||}|j}|j||rdnd|tj|r*|J j | j || fyy)Nz (inverse: ) store_false store_trueactionrr)rrr add_argumentrappend) rrrrrrrargrstrict_flag_assignmentsstrict_flag_namess r3add_invertible_flagz+define_options..add_invertible_flags ?&t,G =E x(( ( k'!, ,D  '|$UY! xx  #*< ""  # ##  $ $T * # * *Dg++> ? r{zOptional arguments)titlez-hz--helpzShow this help message and exit)rrz-vz --verbosecount verbosityzMore verbose messagesr.pyryesz-Vz --versionz %(prog)s z (compiled: rz&Show program's version number and exit)rrrr6z-Oz--outputFORMATzSet a custom output format)metavarrchoicesz Config filezUse a config file instead of command line arguments. This is useful if you are using many flags or want to set different options per each module.)r&rz --config-filez]' or '[[tool.mypy.overrides]]' config sections)rrrrzImport discoveryz2Configure how imports are discovered and followed.z--no-namespace-packagesnamespace_packageszBDisable support for namespace packages (PEP 420, __init__.py-less))rrrrz--ignore-missing-importsrz*Silently ignore imports of missing modulesz--follow-untyped-importsz2Typecheck modules without stubs or py.typed markerz--follow-imports)normalsilentskiprr0z%How to treat imports (default normal))r-rrz--python-executablestore EXECUTABLEzQPython executable used for finding PEP 561 compliant installed packages and stubszspecial-opts:python_executable)rr,rrz--no-site-packageszspecial-opts:no_executablez6Do not search for installed PEP 561 compliant packagesz--no-silence-site-packagesz=Do not silence errors in PEP 561 compliant installed packageszPlatform configurationzType check code assuming it will be run under certain runtime conditions. By default, mypy assumes your code will be run using the same operating system and Python version you are using to run mypy itself.z--python-versionzx.yz9Type check code assuming it will be running on Python x.yzspecial-opts:python_version)typer,rrz --platformPLATFORMzRType check special-cased code for the given OS platform (defaults to sys.platform))rr,rz --always-trueNAMEr!z;Additional variable to be considered True (may be repeated))r,rrrz--always-falsezDisable treating bytearray and memoryview as subtypes of bytesz--extra-checkszEnable additional checks that are technically correct but may be impractical in real code. For example, this prohibits partial overlap in TypedDict updates, and makes arguments prepended via Concatenate positional-onlyz,Strict mode; enables the following flags: {}z--strictspecial-opts:strictz--disable-error-codezDisable a specific error codez--enable-error-codezEnable a specific error codezConfiguring error messagesz4Adjust the amount of detail shown in error messages.z--show-error-contextshow_error_contextz7Precede errors with "note:" messages explaining context)rrrrz--show-column-numbersz%Show column numbers in error messagesz--show-error-endzVShow end line/end column numbers in error messages. This implies --show-column-numbersz--hide-error-codesz"Hide error codes in error messagesz--show-error-code-linksz&Show links to error code documentationz--prettyz{Use visually nicer output in error messages: Use soft word wrap, show source code snippets, and show error location markersz--no-color-outputrgzDo not colorize error messagesz--no-error-summaryrezDo not show error stats summaryz--show-absolute-pathzShow absolute paths to filesz--soft-error-limitmany_errors_threshold)rr5rrzIncremental modezAdjust how mypy incrementally type checks and caches modules. Mypy caches type information about modules into a cache to let you speed up future invocations of mypy. Also see mypy's daemon mode: mypy.readthedocs.io/en/stable/mypy_daemon.html#mypy-daemonz-iz --incrementalz--no-incrementalr[z-Disable module cache (inverse: --incremental)z --cache-dirDIRzRStore module cache info in the given folder in incremental mode (defaults to '{}')z--sqlite-cachez(Use a sqlite database to store the cachez--cache-fine-grainedzLInclude fine-grained dependency information in the cache for the mypy daemonz--fixed-format-cachez4Use experimental fast and compact fixed format cachez--skip-version-checkz/Allow using cache written by older mypy versionz--skip-cache-mtime-checksz5Skip cache internal consistency checks based on mtimezAdvanced optionsz#Debug and customize mypy internals.z--pdbzInvoke pdb on fatal errorz--show-tracebackz--tbzShow traceback on fatal errorz--raise-exceptionszRaise exception on fatal errorz--custom-typing-modulecustom_typing_modulezUse a custom typing module)r,rrz--old-type-inferencez--disable-expression-cachez--enable-incomplete-feature{,}zDEnable support of incomplete/experimental features for early previewz--custom-typeshed-dirzUse the custom typeshed in DIR)r,rz--warn-incomplete-stubz}Warn if missing type annotation in typeshed, only relevant with --disallow-untyped-defs or --disallow-incomplete-defs enabledz --shadow-filerF) SOURCE_FILE SHADOW_FILE shadow_filezWWhen encountering SOURCE_FILE, read and type check the contents of SHADOW_FILE instead.)rr,rrrz --fast-exitz--no-fast-exitrRz--allow-empty-bodiesz--export-ref-infozReport generationz*Generate a report in the specified format.> memory-xmlr_rz-report special-opts:_report)r,rz-amypyc_annotation_file)rr5rrz --skip-c-genmypyc_skip_c_generation)rrr Miscellaneousz--quickstart-filez --junit-xmlz!Write junit.xml to the given filez--junit-formatglobalper_filez}If --junit-xml is set, specifies format. global: single test with all errors; per_file: one test entry per file with failuresz--find-occurrencesz CLASS.MEMBERzspecial-opts:find_occurrencesz5Print out all usages of a class member (experimental)z--scripts-are-modulesz-Script x becomes module x instead of __main__z--install-typesz8Install detected missing library stub packages using pipz--non-interactivezSInstall stubs without asking for confirmation and hide errors, with --install-typesz --interactive)rrrrrz--experimentalfine_grained_incrementalz$Enable fine-grained incremental modez--use-fine-grained-cachez.Use the cache in fine-grained incremental modez--statsdump_type_statsz --inferstatsdump_inference_statsz--dump-build-statsz--timing-stats timing_stats)rrz--line-checking-statsline_checking_statsz --debug-cachez --dump-depsz --dump-graphz--semantic-analysis-onlyz --test-envz--local-partial-types)rrz--logical-depsz--bazelz--package-rootROOTz --cache-map+zspecial-opts:cache_map)rrrz--debug-serializez--disable-bytearray-promotionz--disable-memoryview-promotionz--strict-concatenatez Running codez{Specify the code you want to type check. For more details, see mypy.readthedocs.io/en/stable/running_mypy.html#running-mypyz--explicit-package-baseszLUse current directory and MYPYPATH to determine module names of files passedz--fast-module-lookupz --excludePATTERNzRegular expression to match file names, directory names or paths which mypy should ignore while recursively discovering files to check, e.g. --exclude '/setup\.py$'. May be specified more than once, eg. --exclude a --exclude b)rr,rrz--exclude-gitignorezhUse .gitignore file(s) to exclude files from checking (in addition to any explicit --exclude if present)-mz--modulezspecial-opts:modulesz.Type-check module; can repeat for more modules)rr,rrrz-pz --packagePACKAGEzspecial-opts:packagesz/Type-check package recursively; can be repeatedrz --command PROGRAM_TEXTzspecial-opts:commandz&Type-check program passed in as string)rr,rrfiles*zspecial-opts:filesz%Type-check given files or directories)r,rrr)rrrrrrUrrrrrrUrz!argparse._ActionsContainer | Nonerr)rrrradd_argument_groupr __file__endswithrr%rrr CONFIG_NAMESSHARED_CONFIG_NAMESrrrrMANY_ERRORS_THRESHOLDr CACHE_DIRsortedr!REPORTER_NAMESreplacer)programheaderr6r7server_optionsr% general_groupcompilation_status config_group imports_groupplatform_groupdisallow_any_group untyped_group none_group lint_groupstrictness_group strict_help error_groupincremental_groupinternals_group report_group report_type other_group code_grouprr#r$s @@@r3define_optionsr|s& !. F$&68 #!37@@@ @  @  @@1@ @@x--4H-IM hv,M k' BY"*!2!25!9u &k)l;M:Na,PP 5   ) ,,4-L  IIh&;&;h>Z>Z&Z[\\] _ ` -- .b.M! ! Q " 9 " A 5 4   ` -  ) E  $ L ..&4/N  H *   a    J   K   22'Z3## : $ ##" a $ ##! 6 $ ! [ # C  $ N ---.M"0 !3 !/ $B  L ' J ***e+J  H  / 8K\K\]  J $e(:K:KS]H4E4EZ**$M+J  D  <   E  S  N % W $3  007W0X! E  T " Q   6  $ ;  M HAGG #$K!!<.C+"!! , "!! + "++*J,K ! F  4  .  1  ! 5  +   -   .  +  ..  $    11 E2"" ol9J9J#""  < # ""#VH$6$67 # 7  "" [# """U* C"" #"" ># ""# D# // .S0O  D_ `  F<>]!  \8X!    # ) !   |(:K:K!  $\@Q@Q! %chhv&9:;;cA S    5U! I   . / !  |(J[J[ \  [xGXGX! H4E4E_  !4\PXPaPa b,,!/[-Lh556 n ,  % %[((c237;$[M9 &  *dIZIZ 6|RZRcRc++/+BK0x7H7HI]1TU:&M   , D   <  G  -   +7 !   &A !  ,->XEVEV |2HxO`O` ,\HYHYZ (~HDUDUV &;(BSBS   8CTCTU  lARARS |(BSBST 2  # 5  ! 4  $&= ==r{Tc !"||ntj}||ntj}t|||||\}} !t j } |j || | j} | r4tjj| s|jd| dt d"d) !"fd } t | | ||t| dr| tjdd} | j!r| _tjj% j" _t j }|j |t' |d |j(xs  j( _ j(d kr|jd  t+ ||j0s j2rd _|j6so|j8sc|j:sW j6r j6|_ j8r j8|_ j:r j:|_|ryt=d |j:|j8z|j>|j6fD}|d k(r j@s|jdn|dkDr|jd jBr jDs|jdtG jHtG jJz}|r,|jddjMtO|ztQ jRtQ jT jW|j jY|jtZ j\.tjj_ j\ _0|jbrmte|jbjgd}ti|dkr|jdti|dk7r|jd|tj_1tm|joD]@\}}|jqds||ddjsdd}|}| jt|<B jvr ty|| |jzr* j|r|jdt||  j jrd _B jrd _D jrd _A jr "s t[d  jr t[d!|j:|j8zrutj _Jt j4\}} ttjftet jzte|d"}g}t|| }|j8D]}tj|vs"tjr#tj|vrtd#|d$| |j|}|sF|j|}|tjurtd%|d&| ntd'|d| |j||j:D]}|jtd|d | fS|j>r@tj _Jtddd(jM|j>g}| fS t|j6 |}| fS#t,$r%}|jt/|Yd}~d}~wwxYw#t$r#}tt/|| Yd}~ fSd}~wwxYw)*aParse command line arguments. If a FileSystemCache is passed in, and package_root options are given, call fscache.set_package_root() to set the cache's package root. Returns a tuple of: a list of source files, an Options collected from flags. NzCannot find config file ''Fc8dD]\}}t||y)NT)setattr)rvalueror#strict_option_sets r3set_strict_flagsz)process_options..set_strict_flagsos( 2 *KD% GT5 ) *r{r<MYPY_CACHE_DIRrI)zrMypy no longer supports checking Python 2 code. Consider pinning to mypy<0.980 if you need to check Python 2 code.c32K|]}t|ywr~)rU).0cs r3 z"process_options..s  G srz2Missing target module, package, files, or command.r;z;May only specify one of: module/package, files, or command.zCan only use --explicit-package-bases with --namespace-packages, since otherwise examining __init__.py's is sufficient to determine module names for filesz;You can't make a variable always true and always false (%s)r.)error_callback)rwarning_callbackrrFz+Can only find occurrences of class members.z6Can only find occurrences of non-nested class members.rJirHrz/--cache-map is incompatible with --sqlite-cacheTzGWarning: --strict-concatenate is deprecated; use --extra-checks insteadzQWarning: --force-uppercase-builtins is deprecated; mypy only supports Python 3.9+rzPackage name 'z' cannot have a slash in it.z Package 'z' cannot be type checked due to missing py.typed marker. See https://mypy.readthedocs.io/en/stable/installed_packages.html for more detailszCan't find package 'rI)rr)]rLr6r7r|r Namespace parse_argsrosr0existsrr#rgetattrgetenvrr_ expanduserr$rrrrrrr\r[packagesmodulessumcommandrZexplicit_package_basesr/set always_true always_falserrdruntyped_calls_excludedeprecated_calls_excludeprocess_error_codesprocess_incomplete_featuresr+custom_typeshed_dirabspathabs_custom_typeshed_dirfind_occurrencestuplerrdrvarsitemsr_rf report_dirs package_rootprocess_package_roots cache_map sqlite_cacheprocess_cache_mapprocess_strict_bytescache_fine_grainedrXshow_error_endshow_column_numbers logical_depsstrict_concatenateforce_uppercase_builtinsr"r8 build_typerrgetcwdr rsepaltseprYfind_modules_recursive find_modulerFOUND_WITHOUT_TYPE_HINTSrr!rrZrr)#r5r6r7require_targetsrir?rgrhrrHdummyrrenviron_cache_dirrr code_methodsoverlap_find_occurrencesrvalry report_dirsys_path search_pathstargetscachep p_targetsreasonme2ror#rs# @@@r3rQrQJs")VszzF)VszzF)7*&FA&    E dE"##K277>>+6 0 Q?@iG*g/ffMu+, "2B7 -**7+<+<=G%%'L dN7L/RS*88RG @ @A v||< ''v||V['\"".*,''//':U:U*V'$$!,"?"?"E"Ec"JK  !A % LLF G  !Q & LLQ R!2,'--/: c == #s)++C5KJ/9G   , :gvw7    LLJ K&,8   "!!&*#&*#%)"!!*; WX'' abl333&--%g&?&?@ !" YY[NE)+0A0A"ABE(OUW  gw?&& &Avv{biiBIIN~aS(DEvwW44Q7I**1-1JJJ#A3'rs /s!4fgF NN9 % &%% 7A NN;tQ5 6 7 G    &33tT499\5I5I+JKL G  +(););WgNG G [ * SVV! + R&' * * G  +s0) ^&^2 ^/ ^**^/2 _;__c||jd|Jtjjtj\}}tj }tj tj z}tjtj z}||h}g} |jD]} tjj| r|jd| tjj| \} } | r| |k7r|jd| | z| r|tjj| } | jtj s| tj z} | j|r|jd| | |vrd} | j| | |_|j| y)z$Validate and normalize package_root.Nz.--package-root does not work here (no fscache)z!Package root cannot be absolute: z'Package root must be on current drive: z0Package root cannot be above current directory: r)rrr0 splitdrivercurdirrpardirrisabsrelpathr_ startswithr!set_package_root) r?rro current_driverHdotdotslash dotdotslash trivial_pathsrrootdrives r3rr!sv EF   ww))"))+6M1 ))Cyy266!H))bff$K(OML$$" 77==  LLZ[ \!!,/ LLRU^^ !!,/ LLRU^^ &/ $:&!;r{cD|jr|jdd|jd}|jdk(r5tj|||rd|ini|j||j ytj||||j||j yy)NrrHr;rN) junit_xmlr junit_formatrwrite_junit_xmlr)tdr all_messagesrro py_versions r3rr\s..q12!G4J4J14M3NO   8 +  (4|$"!!     G-w/@/@*gN^N^ r{c~|j|dtdd|gd|gi|tjdy)zFail with a serious error.rIgTN)rrrrorF)rhrrLrk)rr7ros r3rYrYus= LLC5 Tu W^HHQKr{ctjj|sA|s tjj dntjj dt j|}tjj|sgSt|5}|Dcgc]}|jc}cdddScc}w#1swYyxYw)Nzkerror: Can't determine which types to install with no files to check (and no cache from previous mypy run) zTerror: --install-types failed (an error blocked analysis of which types to install) ) rr0isdirrLr7rhrmissing_stubs_fileisfileopenr)r_rCfnamrlines r3r^r^~s 77== # JJ  <  JJ  g   # #I .D 77>>$  d,q)*+ +,,+,,s"C'C >C CCrDc:t|j|}|sy|r |s ttd|jsJd|jdddg|z}t|j dj |dd t|svt d }|jr|jjd s2t|j d dd tjdttj|y )zDInstall stub packages using pip if some missing stubs were detected.Fz!Installing missing stub packages:z+Python executable required to install typesrXpipinstall noneT)boldzInstall? [yN] yzmypy: Skipping installationredrF)r^r_r+r\stylerinputrlowerrrLrkrrun)rprorCrBrcmdxs r3rZrZs.g.?.?KH   -.  $ $S&SS $  $ $dE9 = HC )//#((3-d/ ;< G  " #wwy 4 4S 9 )//"?T/R S HHQK NN3 r{)r0rrzos.stat_result) r5zlist[str] | Noner6r r7r r8rUrr)rnzlist[BuildSource]ror#r?rrmfloatr6r r7r rz0tuple[build.BuildResult | None, list[str], bool]) rrrrr rputil.FancyFormatterror#rr)rrrr)rrrr)rztuple[int, int]rr)ror#rr rr) rgrrhrr6r r7r rirUrzBtuple[CapturableArgumentParser, list[str], list[tuple[str, bool]]])r5rr6 TextIO | Noner7rrrUrirUr?FileSystemCache | Nonergrrhrrz!tuple[list[BuildSource], Options])r?rrr ror#rr)rr rr ror#rr) rrrrUrrrzdict[str | None, list[str]]ror#rr)rrr7r ror#rr )r_rrCrUrr) rprror#rCrUrBrUrrU)`r __future__rrrrrLrK collectionsrcollections.abcrriortypingrr r r r r r:rrrrmypy.config_parserrrrrmypy.error_formatterr mypy.errorsrmypy.find_sourcesrr mypy.fscachermypy.modulefinderrrrrrr mypy.optionsr!r"r#mypy.split_namespacer$ mypy.versionr% _typeshedr&statr'__annotations__r(r)r4r6r7rzr]raRawDescriptionHelpFormatterrrrabr ExceptionrrrrrrrArgumentParserrActionrr|rQrrrrYr^rZrr{r3rs*"  #$BB-- 0$C(A@/$'77 5 U  "ZZZZ q q q  q  q  qh;# ;# ;#;#  ;#  ;#  ;#6;#|"/BMT  PXAA P23CD5D)+&+ DAqOAOA SYS*2(FF U.EE 2Gx662Gj$hoo$PZZZZ v > v > v > v >  v >  v > H v >v!   &*T T T T T  T $ TT T'Tn + # +-D +OV +  +F; #;3E;PW; ;0  2     2,.! "      r{