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

[chore] bump go structr cache version -> v0.6.0 #2773

Conversation

NyaaaWhatsUpDoc
Copy link
Member

@NyaaaWhatsUpDoc NyaaaWhatsUpDoc commented Mar 21, 2024

Description

  • updates go-structr to v0.6.0, which made some incompatible API changes that this PR fixes. this latest version adds the Queue{} type to the structr package which allows (in the future) for indexable queues.
  • updates all the cache.GTS{} caches to be struct value types instead of a mixture of values + ptrs
  • adds structr.Cache{} wrapping type to simplify updating with the incompatible API changes + allows for much simpler loading of multiple IDs from caches

Checklist

  • I/we have read the GoToSocial contribution guidelines.
  • I/we have discussed the proposed changes already, either in an issue on the repository, or in the Matrix chat.
  • I/we have not leveraged AI to create the proposed changes.
  • I/we have performed a self-review of added code.
  • I/we have written code that is legible and maintainable by others.
  • I/we have commented the added code, particularly in hard-to-understand areas.
  • I/we have made any necessary changes to documentation.
  • I/we have added tests that cover new code.
  • I/we have run tests and they pass locally with the changes.
  • I/we have run go fmt ./... and golangci-lint run.

@NyaaaWhatsUpDoc NyaaaWhatsUpDoc force-pushed the chore/bump-go-structr-cache-version branch from 545bcd2 to 5462691 Compare March 25, 2024 17:12
@NyaaaWhatsUpDoc NyaaaWhatsUpDoc marked this pull request as ready for review March 25, 2024 17:28
@NyaaaWhatsUpDoc NyaaaWhatsUpDoc force-pushed the chore/bump-go-structr-cache-version branch from f2c1d61 to d25478b Compare March 25, 2024 17:35
test.out Outdated Show resolved Hide resolved
Copy link
Contributor

@tsmethurst tsmethurst left a comment

Choose a reason for hiding this comment

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

Looks good to me! Just the one question about the index map :) And the accidental test output commit ;)

@tsmethurst
Copy link
Contributor

Squerge when you're happy!

@tsmethurst
Copy link
Contributor

(Just merged main into this to fix the docs fail)

@tsmethurst tsmethurst merged commit adf345f into superseriousbusiness:main Apr 2, 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.

None yet

2 participants