Aws-sdk-php: Undefined index notice after registering DynamoDB session handler & calling session_start()

Created on 9 Jul 2019  路  2Comments  路  Source: aws/aws-sdk-php

With the 3.106.0 release, sessions via DynamoDB are no longer working. Using this code:

$dynamoDb = new \Aws\DynamoDb\DynamoDbClient([
    'region' => 'us-east-1',
    'version' => '2012-08-10',
]);

$sessionHandler = \Aws\DynamoDb\SessionHandler::fromClient($dynamoDb, ['table_name' => 'php_sessions']);

$sessionHandler->register();
session_start()

The SDK generates the following error:

Notice: Undefined index: default in <path>/vendor/aws/aws-sdk-php/src/Credentials/CredentialProvider.php on line 358

This worked up until today's release.

bug

All 2 comments

@edillingham

Thanks for raising this issue. We'll get this resolved.

@edillingham

This fix will go out with the next release of the SDK.

Thank you!!

Was this page helpful?
0 / 5 - 0 ratings