Due to our enterprise setup with AWS, we have SSO keys that rotate every 8 hours for security reasons. This means that anytime our users pass those keys into the R Set.env() connection file to S3, their connection will fail after 8 hours. We tried the aws.ec2metadata as per package online help but did not resolve the issue. We should be able to access an S3 bucket without using credentials, given that we created a role for Sagemaker and applied it to the instance to authorize automatically. This seems to only happen on the R side, and our python users on Sagemaker Studio are not experiencing this issue.