Error accessing `/var/task/Gemfile.lock`

Has anyone faced this issue before while deploying with jets 3.1.1?

XXX-jets-base-path-XXX

"errorMessage": "There was an error accessing `/var/task/Gemfile.lock`.\nThe underlying system error is Errno::EROFS: Read-only file system @ rb_sysopen - /var/task/Gemfile.lock",
"errorType": "Init<Bundler::GenericSystemCallError>",
"stackTrace": [
    "/var/runtime/gems/bundler-2.2.33/lib/bundler/shared_helpers.rb:117:in `rescue in filesystem_access'",
    "/var/runtime/gems/bundler-2.2.33/lib/bundler/shared_helpers.rb:102:in `filesystem_access'",
    "/var/runtime/gems/bundler-2.2.33/lib/bundler/definition.rb:303:in `lock'",
    "/var/runtime/gems/bundler-2.2.33/lib/bundler/runtime.rb:98:in `lock'",
    "/var/runtime/gems/bundler-2.2.33/lib/bundler/runtime.rb:35:in `setup'",
    "/var/runtime/gems/bundler-2.2.33/lib/bundler.rb:150:in `setup'",
    "/var/runtime/gems/bundler-2.2.33/lib/bundler/setup.rb:20:in `block in <top (required)>'",
    "/var/runtime/gems/bundler-2.2.33/lib/bundler/ui/shell.rb:136:in `with_level'",
    "/var/runtime/gems/bundler-2.2.33/lib/bundler/ui/shell.rb:88:in `silence'",
    "/var/runtime/gems/bundler-2.2.33/lib/bundler/setup.rb:20:in `<top (required)>'",
    "/var/lang/lib/ruby/site_ruby/2.7.0/rubygems/core_ext/kernel_require.rb:85:in `require'",
    "/var/lang/lib/ruby/site_ruby/2.7.0/rubygems/core_ext/kernel_require.rb:85:in `require'",
    "/var/task/handlers/functions/jets/base_path.rb:1:in `<top (required)>'",
    "/var/lang/lib/ruby/site_ruby/2.7.0/rubygems/core_ext/kernel_require.rb:85:in `require'",
    "/var/lang/lib/ruby/site_ruby/2.7.0/rubygems/core_ext/kernel_require.rb:85:in `require'"
]

}

Means the Gemfile.lock is not up-to-date. Whenever bundle exec runs or require "bundler/setup" which believe is the same thing, bundler can check for dependencies and will update the Gemifile.lock as a part of this. Ran into it before and it’s confusing because you would think only a bundle install would do a write. But from what I’ve seen a bundle exec or require "bundler/setup" can possibly write and update the Gemfile.lock also. Guessing bundler does some extra checks.

Have resolved this before by running bundle and committing the latest Gemfile.lock. At least, that has worked for me when ran into this error. Hope it works for you too :crossed_fingers: