-
Notifications
You must be signed in to change notification settings - Fork 374
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
[gnovm/avl] Removing keys from AVL trees does not work #2266
Comments
Possibly related: #1543 |
Since it can not be replicated, I wonder that did it happened with all the key of Blog tree or just randomly failed? |
It happens on every call to the function. EDIT: It is a bit hard to replicate this - you can run Hopefully we will have better previews and ways to replicate these kind of things. |
@leohhhn so the flow to reproduce is just add a post and then call gnoblog-cli post posts/2022-05-02_peace/README.md -publish -key test1
gnokey maketx call -pkgpath "gno.land/r/gnoland/blog" -func "ModRemovePost" -gas-fee 1000000ugnot -gas-wanted 2000000 -send "" -broadcast -chainid "dev" -args "peace" -remote "tcp://127.0.0.1:26657" test1 |
@deelawn I tried it as well, and seems that
Very weird. |
<!-- please provide a detailed description of the changes made in this pull request. --> ## Description This PR provides a hotfix to the edit functionality in the blog package. This is not the best solution, but due to the urgency of the requests, a we cannot wait for a full refactor of the code, and there are still issues with [AVL & GnoVM](#2266) that are blocking the other proper workaround on this. <details><summary>Contributors' checklist...</summary> - [x] Added new tests, or not needed, or not feasible - [x] Provided an example (e.g. screenshot) to aid review or the PR is self-explanatory - [x] Updated the official documentation or not needed - [x] No breaking changes were made, or a `BREAKING CHANGE: xxx` message was included in the description - [x] Added references to related issues and PRs - [ ] Provided any useful hints for running manual tests - [ ] Added new benchmarks to [generated graphs](https://gnoland.github.io/benchmarks), if any. More info [here](https://github.com/gnolang/gno/blob/master/.benchmarks/README.md). </details>
We'll assign this to @omarsy - have to add him to the team |
Description
This is a bit of a weird issue @ajnavarro and I came across while fixing the blog package. Namely, we implemented this function, which removes a pointer to a post from three trees. It makes sure to get the correct keys before removing anything from the trees, to avoid any possible bugs. However, when calling this function, you get the following errror:
I tried isolating & replicating the issue with a simple txtar, but I didn't get lucky, as this test is passing. Any ideas?
The text was updated successfully, but these errors were encountered: