Skip to content

Conversation

@Jimbolino
Copy link
Contributor

This small change fixes an issue i encountered when running laravel via serverless framework on aws lambda.

https://github.com/brefphp/laravel-bridge/blob/master/src/BrefServiceProvider.php#L65
I dont like the above workaround, because it forces blade templates to be recompiled every time, which defeats the purpose of caching.

But when including the storage (or any other) directory in the serverless.zip, i noticed that all dates in the zip file were set to 01-01-1980
This was not a bug, but a feature to create reproducible builds/zip files:
https://github.com/serverless/serverless/blob/master/lib/plugins/package/lib/zipService.js#L95

When searching i found some PR's that touched the subject:
#13938 (comment)
#31206

I believe this PR could fix all these edge cases, without drastically changing the caching behaviour.

dont recompile view if .blade.php has same mtime as cache file
@taylorotwell
Copy link
Member

I don't think I can change this on a patch release.

@GrahamCampbell
Copy link
Collaborator

This change looks sensible to me. Also would affect vapor deploys?

@GrahamCampbell
Copy link
Collaborator

Actually, no, vapor builds views into tmp.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants