Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix warning in Connection::tryDeserializeError() #168

Conversation

drunken-monkey
Copy link
Contributor

Description

Fixes code in \OpenSearch\Connections\Connection::tryDeserializeError() to properly check whether $error['error']['root_cause'] exists before accessing it.

Issues Resolved

Closes #167.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Signed-off-by: Thomas Seidl <remus@gmx.net>
shyim
shyim previously approved these changes Nov 18, 2023
@dblock
Copy link
Member

dblock commented Nov 18, 2023

@drunken-monkey Your second commit is missing DCO, please?

Copy link

codecov bot commented Nov 18, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (9ebb183) 24.19% compared to head (cc67d75) 24.19%.

❗ Current head cc67d75 differs from pull request most recent head dbd796f. Consider uploading reports for the commit dbd796f to get more accurate results

Additional details and impacted files
@@             Coverage Diff              @@
##               main     #168      +/-   ##
============================================
- Coverage     24.19%   24.19%   -0.01%     
+ Complexity     1938     1936       -2     
============================================
  Files           246      246              
  Lines          6865     6862       -3     
============================================
- Hits           1661     1660       -1     
+ Misses         5204     5202       -2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Signed-off-by: Thomas Seidl <remus@gmx.net>
@drunken-monkey drunken-monkey force-pushed the 167--fix-tryDeserializeError-warning branch from ecf7f6f to 7b432c2 Compare November 18, 2023 15:45
@drunken-monkey
Copy link
Contributor Author

@drunken-monkey Your second commit is missing DCO, please?

Sorry, fixed!

Copy link
Member

@dblock dblock left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See below?

src/OpenSearch/Connections/Connection.php Show resolved Hide resolved
@dblock
Copy link
Member

dblock commented Nov 20, 2023

Do add a line to CHANGELOG. This fixes a bug.

@dblock
Copy link
Member

dblock commented Nov 22, 2023

@drunken-monkey You have to amend your last commit to pass DCO, please?

Signed-off-by: Thomas Seidl <remus@gmx.net>
@drunken-monkey drunken-monkey force-pushed the 167--fix-tryDeserializeError-warning branch from cc67d75 to dbd796f Compare November 22, 2023 17:18
@j-fulbright
Copy link

Can this get brought in? It is causing headaches with AWS OSS

@dblock
Copy link
Member

dblock commented Mar 27, 2024

Need another maintainer to approve. @VachaShah @shyim @harshavamsi ?

@dblock dblock merged commit 8962f02 into opensearch-project:main Mar 28, 2024
2 checks passed
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.

[BUG] PHP warning Undefined array key "root_cause" in Connection::tryDeserializeError()
4 participants