Skip to content

Signing implementation currently not interchangeable (impl trait return) #2173

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

Closed
yanganto opened this issue Apr 9, 2024 · 1 comment
Closed
Labels
bug Something isn't working

Comments

@yanganto
Copy link
Contributor

yanganto commented Apr 9, 2024

The return type of SignBuilder is a bug.

impl as a return type only helps simplify your type signatures
https://doc.rust-lang.org/rust-by-example/trait/impl_trait.html

It will not be a generic thing as you think.
https://stackoverflow.com/questions/52001592/why-can-impl-trait-not-be-used-to-return-multiple-conditional-types

Your project uses tab not space, but the Sign trait implementation is mixed with tab and space here
https://github.com/extrawurst/gitui/blob/5d68ea0e397ea65dce6c8aeb653b1c43918c78e1/asyncgit/src/sync/sign.rs#L122-L134

You don't like a simple and working solution #2047, but implement a buggy trait with unnecessary complexity to force me to follow, or want me to solve your issue for free and in silence.

@yanganto yanganto added the bug Something isn't working label Apr 9, 2024
@extrawurst
Copy link
Collaborator

extrawurst commented Apr 9, 2024

The return type of SignBuilder is a bug.

impl as a return type only helps simplify your type signatures

Fair point, we can simply Box it and that's fixed. PR welcome.

You don't like a simple and working solution #2047,

I like simple but like I explained over there already: we cannot hardcode a solution that will only work with your branch, there was already the gpg-work ongoing for months prior that was conflicting with your work. Plus GPG was a far more requested feature than ssh-signing so it got priority.

but implement a buggy trait with unnecessary complexity

Seems like a fairly simple bug (see above)

to force me to follow, or want me to solve your issue for free and in silence.

No one is forcing you to do anything, I would suggest you check your tone here, we all work on this for close to nothing. The time I invested into providing this tool to you and the whole community for free far exceeds any donations (less than 1% of time invested was paid)

Of course I would like you to keep helping as you made a lot of valuable contribution over the years but you need to look beyond your own interest and show appreciation for other peoples work too

@extrawurst extrawurst changed the title Sign trait is buggy Signing implementation currently not interchangeable (impl trait return) Apr 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants