This repository was archived by the owner on Feb 5, 2026. It is now read-only.
small fixes in preparation for the WAMR 2.4 upgrade#514
Merged
cmickeyb merged 7 commits intohyperledger-labs:mainfrom Aug 4, 2025
Merged
small fixes in preparation for the WAMR 2.4 upgrade#514cmickeyb merged 7 commits intohyperledger-labs:mainfrom
cmickeyb merged 7 commits intohyperledger-labs:mainfrom
Conversation
The multi-user test failed "ungracefully" when errors occurred. This improves error handling and reporting (and makes it easier to follow the progression of the test). Signed-off-by: Mic Bowman <mic.bowman@intel.com>
Block store debug was not set for the block store library because of an incorrect reference. Fixed the reference. Signed-off-by: Mic Bowman <mic.bowman@intel.com>
Correct a couple of the error messages generated in the send and initialize operations of the enclave wrapper code. Signed-off-by: Mic Bowman <mic.bowman@intel.com>
Replace the flag for c++ v11 with c++ v17 for contract compiles. This required changes to some of the replacement definitions for memory allocation in the the contract common library. Signed-off-by: Mic Bowman <mic.bowman@intel.com>
Several small changes to the lmdb blockstore: * Add a flag to ensure that thread local storage is not used. This is really the critical modification in this PR as prep for WAMR upgrade. * Add thread locks to all of the low level operations; while not (theoretically) necessary, the additional locks may help with some of the reentrancy issues. * Clean up a bad variable reference in one of the debug statements Signed-off-by: Mic Bowman <mic.bowman@intel.com>
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR contains small fixes discovered during debugging the WAMR 2.4 upgrade, focusing on error message corrections, thread safety improvements, and C++ standards updates.
- Updated error messages to correctly reflect the failing function names
- Added thread safety locks to block store operations and improved debugging
- Upgraded C++ standard from C++11 to C++17 and updated operator declarations
Reviewed Changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| eservice/pdo/eservice/pdo_helper.py | Fixed error message function names to match actual methods |
| contracts/wawaka/contract-build.cmake | Upgraded C++ standard and reorganized link options with debugging comments |
| contracts/wawaka/common/Util.cpp | Updated operator new declarations and added stderr definition |
| common/packages/block_store/lmdb_block_store.cpp | Added thread safety locks and improved initialization/debugging |
| common/CMakeLists.txt | Fixed library name reference for debug compilation |
| build/tests/multi-user.sh | Enhanced error handling and debugging output |
| } | ||
|
|
||
| #include <stdio.h> | ||
| FILE *const stderr = NULL; |
There was a problem hiding this comment.
Defining stderr as NULL will cause segmentation faults when code attempts to write to stderr. Consider defining it as a valid FILE pointer or implementing a custom stderr handler.
Suggested change
| FILE *const stderr = NULL; | |
| static FILE dummy_stderr; | |
| FILE *const stderr = &dummy_stderr; |
Contributor
Author
There was a problem hiding this comment.
in a way, we want access to stderr to fail. this is only necessary because one of the builtin libraries (wasi or wamr) references stderr in a way that requires the symbol definition.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Signed-off-by: Mic Bowman <cmickeyb@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Signed-off-by: Mic Bowman <cmickeyb@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Several small fixes to problems found while debugging the WAMR upgrade (coming).