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

Remove use of bou.ke/monkey library #427

Merged
merged 2 commits into from
Oct 14, 2022

Conversation

chromato99
Copy link
Contributor

@chromato99 chromato99 commented Oct 10, 2022

What this PR does / why we need it:

Remove use of bou.ke/monkey library.

Recently there was an issue pointing to the license of the monkey patch library.
I looked for several ways to replace it, but other monkey patch libraries have the same problem that there are too few users and can not used in the arm architecture.

So, I thought about changing it in a way that avoids the need for a monkey patch, and I tried it.
But, this method may be considered unclean.
I'd appreciate it if you could comment on what I've been working on

Edit:
I changed it to use the undefinedlabs/go-mpatch library instead of the above method.
Same problem not working on ARM architecture, but I was able to completely replace the bou.ke/monkey library.

Which issue(s) this PR fixes:

Fixes #416

Special notes for your reviewer:

Does this PR introduce a user-facing change?:


Additional documentation:


Checklist:

  • Added relevant tests or not required
  • Didn't break anything

@codecov
Copy link

codecov bot commented Oct 10, 2022

Codecov Report

Merging #427 (4fbe279) into main (002962d) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             main     #427   +/-   ##
=======================================
  Coverage   46.86%   46.86%           
=======================================
  Files          71       71           
  Lines        5930     5930           
=======================================
  Hits         2779     2779           
  Misses       2846     2846           
  Partials      305      305           

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@hackerwins
Copy link
Member

Thanks for your PR.

However, I am concerned because the structure of the test code seems to add complexity to the original code. 🤔

@chromato99
Copy link
Contributor Author

Thanks for your comment.

As you mentioned, this method seems to increase the complexity of the original code for testing. I'll have to work on using other monkey patch libraries.

@chromato99
Copy link
Contributor Author

I changed it to use the undefinedlabs/go-mpatch library instead of the above method.
Same problem not working on ARM architecture, but I was able to completely replace the bou.ke/monkey library.

@hackerwins hackerwins self-requested a review October 14, 2022 05:49
Copy link
Member

@hackerwins hackerwins left a comment

Choose a reason for hiding this comment

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

Thanks for your contribution. 👍

@chromato99 chromato99 marked this pull request as ready for review October 14, 2022 05:49
Copy link
Member

@blurfx blurfx left a comment

Choose a reason for hiding this comment

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

LGTM 👍

@hackerwins hackerwins merged commit d8aaf81 into yorkie-team:main Oct 14, 2022
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.

Golang monkey patching library utilized against terms of license
3 participants