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

feat(examples): add memeland #1751

Merged
merged 47 commits into from
Mar 20, 2024
Merged

feat(examples): add memeland #1751

merged 47 commits into from
Mar 20, 2024

Conversation

leohhhn
Copy link
Contributor

@leohhhn leohhhn commented Mar 11, 2024

Description

This PR adds the p/demo/memeland & r/demo/memeland package & realm to the examples folder. Adding this will be the way we "Deploy" the Memeland realm to the Portal Loop.

The UI and the most up to date code can be found here. Waiting on full release and will copy code over from the other repo.

The only thing currently missing are public realm functions tested. The package is fully tested.

Contributors' checklist...
  • Added new tests, or not needed, or not feasible
  • Provided an example (e.g. screenshot) to aid review or the PR is self-explanatory
  • Updated the official documentation or not needed
  • No breaking changes were made, or a BREAKING CHANGE: xxx message was included in the description
  • Added references to related issues and PRs
  • Provided any useful hints for running manual tests
  • Added new benchmarks to generated graphs, if any. More info here.

@github-actions github-actions bot added the 🧾 package/realm Tag used for new Realms or Packages. label Mar 11, 2024
Copy link

codecov bot commented Mar 11, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 47.49%. Comparing base (5c5d9ef) to head (95c6a1c).

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1751   +/-   ##
=======================================
  Coverage   47.49%   47.49%           
=======================================
  Files         388      388           
  Lines       61311    61311           
=======================================
  Hits        29117    29117           
  Misses      29756    29756           
  Partials     2438     2438           

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

Copy link
Member

@zivkovicmilos zivkovicmilos left a comment

Choose a reason for hiding this comment

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

Overall looks good, please address the comments 🙏

examples/gno.land/p/demo/memeland/memeland.gno Outdated Show resolved Hide resolved
examples/gno.land/p/demo/memeland/memeland.gno Outdated Show resolved Hide resolved
examples/gno.land/p/demo/memeland/memeland.gno Outdated Show resolved Hide resolved
examples/gno.land/p/demo/memeland/memeland.gno Outdated Show resolved Hide resolved
examples/gno.land/p/demo/memeland/memeland.gno Outdated Show resolved Hide resolved
examples/gno.land/p/demo/memeland/memeland.gno Outdated Show resolved Hide resolved
examples/gno.land/r/demo/memeland/memeland.gno Outdated Show resolved Hide resolved
@leohhhn leohhhn marked this pull request as ready for review March 14, 2024 10:18
@leohhhn leohhhn requested a review from a team as a code owner March 14, 2024 10:18
@leohhhn leohhhn requested a review from a team as a code owner March 14, 2024 10:18
@zivkovicmilos zivkovicmilos added the don't merge Please don't merge this functionality temporarily label Mar 15, 2024
Copy link
Contributor

@ajnavarro ajnavarro left a comment

Choose a reason for hiding this comment

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

I know this is a PoC, but took the liberty of giving some feedback related to the data structure and ways to paginate:

  • AFAIK there is no need to remove posts, I would suggest changing the avl.Tree to a slice of Posts. This gives several advantages, like:
    • No need for casting when retrieving from the slice instead of the avl.Tree.
    • Sequential index already there, it will be the slice index instead of a string.
    • No rebalancing is needed.
    • Easier pagination mapping directly the elements per page and the page number to the slice indexes.
  • I would change GetPosts() method to GetPosts(page,pagesize int). Too risky.
  • I would limit the pageSize on GetPostsInRange.

@leohhhn leohhhn marked this pull request as draft March 17, 2024 16:39
@leohhhn leohhhn marked this pull request as ready for review March 19, 2024 14:19
Copy link
Member

@zivkovicmilos zivkovicmilos left a comment

Choose a reason for hiding this comment

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

🚀 🚀 🚀

@leohhhn leohhhn merged commit 06f2915 into gnolang:master Mar 20, 2024
69 of 73 checks passed
@leohhhn leohhhn deleted the feat/memeland branch March 20, 2024 12:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
don't merge Please don't merge this functionality temporarily 🧾 package/realm Tag used for new Realms or Packages.
Projects
Status: Done
Archived in project
Development

Successfully merging this pull request may close these issues.

None yet

3 participants