aws-samples / aws-serverless-workshops

Code and walkthrough labs to set up serverless applications for Wild Rydes workshops
http://wildrydes.com
Apache License 2.0
4.2k stars 2.63k forks source link

sam build fails in Decoupled Microservices Lab Scatter-Gather Lab 3 #307

Open indranilbanerjee2014 opened 3 years ago

indranilbanerjee2014 commented 3 years ago

In the Decoupled Microservices Lab, sam build command fails in the 3rd lab Scatter-Gather - https://async-messaging.workshop.aws/scatter-gather.html

Below is the error I get

indranil:~/environment/wild-rydes-async-messaging/lab-3 $ sam build Building codeuri: request-for-quotes-service/ runtime: python3.7 metadata: {} functions: ['RequestForQuotesService'] Running PythonPipBuilder:ResolveDependencies

Build Failed Error: PythonPipBuilder:ResolveDependencies - list index out of range

template.yaml file is pasted below

AWSTemplateFormatVersion: '2010-09-09' Transform: AWS::Serverless-2016-10-31 Description: > re:invent2019 ARC314-R Lab-3

Sample SAM Template for re:invent2019 ARC314-R Lab-3

More info about Globals: https://github.com/awslabs/serverless-application-model/blob/master/docs/globals.rst

Globals: Function: Timeout: 70

Resources: RequestForQuotesService: Type: AWS::Serverless::Function # More info about Function Resource: https://github.com/awslabs/serverless-application-model/blob/master/versions/2016-10-31.md#awsserverlessfunction Properties: CodeUri: request-for-quotes-service/ Handler: app.lambda_handler Runtime: python3.7 Environment: Variables: TABLE_NAME: !Ref RidesBookingTable TOPIC_ARN: !Ref RequestForQuotesTopic Policies:

Outputs: RideBookingApiSubmitInstantRideRfqEndpoint: Description: "API Gateway endpoint URL for Prod stage for RideBookingService submit-instant-ride-rfq resource" Value: !Sub "https://${ServerlessRestApi}.execute-api.${AWS::Region}.amazonaws.com/Prod/submit-instant-ride-rfq/" RideBookingApiQueryInstantRideRfqEndpoint: Description: "API Gateway endpoint URL for Prod stage for RideBookingService query-instant-ride-rfq resource" Value: !Sub "https://${ServerlessRestApi}.execute-api.${AWS::Region}.amazonaws.com/Prod/query-instant-ride-rfq/{id}"

RideBookingService:

Description: "RideBookingService Lambda Function ARN"

Value: !GetAtt RideBookingService.Arn

RequestForQuotesTopic: Description: "Amazon SNS topic ARN for RequestForQuotes topic" Value: !Ref RequestForQuotesTopic