SwiftXcode / swift-lambda

Build and deploy Swift Package Manager projects on AWS Lambda
Apache License 2.0
24 stars 1 forks source link

`Fatal error: could not load resource bundle` when using packages with resources #5

Closed alfavata closed 3 years ago

alfavata commented 3 years ago

I'm trying to integrate PhoneNumberKit in my lambda, and according to this PR it should work on Linux servers.

However, when I build and deploy my lambda using swift-lambda it encounters the following error:

Fatal error: could not load resource bundle: from /var/task/PhoneNumberKit_PhoneNumberKit.resources or /Users/alfavata/Code/ios-hiya/CallLogLambda/.build/x86_64-unknown-linux/release/PhoneNumberKit_PhoneNumberKit.resources: file PhoneNumberKit/resource_bundle_accessor.swift, line 11

(Note that it's referring to the path on my local machine)

I've put a minimal example package here as suggested by @helje5

helje5 commented 3 years ago

Works now.