
                              S r SSKJr  SSKJr  SSKJr  SSKJr  SSKJr  SSKJr  SSK	J
r
  SSK	Jr  SS	KJr  SS
KJr  SSKrSrSrSSSSS.rSrSrSr SS jrS rg)z0This module holds exceptions raised by commands.    )absolute_import)division)unicode_literals)deploy_command_util)
exceptions)yaml_parsing)
enable_api)convert_yaml)logNa&  descriptor:                  [{descriptor}]
source:                      [{source}]
target project:              [{project}]
target service:              [{service}]
target version:              [{version}]
target url:                  [{url}]
target service account:      [{service_account}]

zXdescriptor:      [{descriptor}]
type:            [{type}]
target project:  [{project}]

zdatastore indexesz	cron jobsztask queueszrouting rules)indexcronqueuedispatchz_     (add --promote if you also want to make this service available from
     [{default_url}])
zYou've generated a Dockerfile that may be customized for your application.  To use this Dockerfile, the runtime field in [{0}] must be set to custom.zCaution: You are updating queue configuration. This will override any changes
performed using 'gcloud tasks'. More details at
https://cloud.google.com/tasks/docs/queue-yaml
c                 T   0 nU(       Ga  U c  [        S5      e[        R                  R                  S5        U GH  n	[        R
                  " U	R                  5      n
[        R                  " X	R                  U(       a  SOUU
S9nXU	R                  '   [        R                  " U5      nSn UR                  U	R                  R                  R                  5       5      R                  SS5      nU R*                  nU(       a  UnO	U(       a  Un[        R                  R                  [,        R%                  UU	R                  UU	R.                  U	R0                  UUS	95        U(       a  GM4  [        R                  " X	R                  U
S
9n[        R                  R                  [2        R%                  US95        GM     U(       a  [5        X5        U$ ! [         aG  n[         R"                  " SR%                  U	R                  [&        R(                  " U5      S95      eSnAff = f)a  Prints the details of the proposed deployment.

Args:
  app: Application resource for the current application (required if any
    services are deployed, otherwise ignored).
  project: The name of the current project.
  services: [deployables.Service], The services being deployed.
  configs: [yaml_parsing.ConfigYamlInfo], The configurations being updated.
  version: The version identifier of the application to be deployed.
  promote: Whether the newly deployed version will receive all traffic
    (this affects deployed URLs).
  service_account: The service account that the deployed version will run as.
  api_version: Version of the yaml file parser to use. Use 'v1' by default.

Returns:
  dict (str->str), a mapping of service names to deployed service URLs

This includes information on to-be-deployed services (including service name,
version number, and deployed URLs) as well as configurations.
Nz7If services are deployed, must provide `app` parameter.zServices to deploy:
)appserviceversionuse_ssl serviceAccountzc[{f}] could not be converted to the App Engine configuration format for the following reason: {msg})fmsg)projectr   r   
descriptorsourceurlservice_account)r   r   r   )default_url)	TypeErrorr   statusPrintr   UseSslservice_infoGetAppHostname
service_idr
   GetSchemaParserConvertValueparsedToDictget
ValueErrorr   ConfigErrorformatsix	text_typer   DEPLOY_SERVICE_MESSAGE_TEMPLATEr   r   PROMOTE_MESSAGE_TEMPLATE DisplayProposedConfigDeployments)r   r   servicesconfigsr   promoter   api_versiondeployed_urlsr   r   r   schema_parserservice_account_from_yamledisplay_service_accountr   s                    4lib/googlecloudsdk/command_lib/app/output_helpers.pyDisplayProposedDeploymentr=   I   s   8 -
{OPPJJ,-#**7+?+?@g..--!$wAc +.G&&'"22;?m"$?$1$>$>  ''..0%225#6F2M 	" !$ 2 2	"1$";	jj
)
0
0(( ++^^5 1 78 W)88//B

188# 9 % 	&C H $W6	9  ?$$55;V&&CMM!,< 6< 6>? 	??s   .AG
H' AH""H'c           	         [         R                  R                  S5        U H  n[         R                  R                  [        R	                  U [
        UR                     UR                  S95        UR                  [        R                  R                  :X  d  Mz   [        R                  " U S5      nU(       d  M  [         R                   " ["        5        M     g! [        R                   a    Sn N@f = f)zPrints the details of the proposed config deployments.

Args:
  project: The name of the current project.
  configs: [yaml_parsing.ConfigYamlInfo], The configurations being
    deployed.
zConfigurations to update:
)r   typer   zcloudtasks.googleapis.comTN)r   r    r!   DEPLOY_CONFIG_MESSAGE_TEMPLATEr-   CONFIG_TYPESconfigfilenamer   ConfigYamlInfoQUEUEr	   IsServiceEnableds_exceptionsListServicesExceptionwarningQUEUE_TASKS_WARNING)r   r4   capi_maybe_enableds       r<   r2   r2      s     **01aJJ3::l1884 ; I J 	vv,,222!&7702 
	 	'(  // ! !s   CC54C5)v1)__doc__
__future__r   r   r   googlecloudsdk.api_lib.appr   r   r   googlecloudsdk.api_lib.servicesr	   rH   /googlecloudsdk.appengine.admin.tools.conversionr
   googlecloudsdk.corer   r.   r0   r@   rA   r1   RUNTIME_MISMATCH_MSGrK   r=   r2        r<   <module>rX      sz     7 &  ' : 1 3 6 F H # 
	# "  !	 
L   +/HV)rW   