yuya373 / emacs-slack

slack client for emacs
1.11k stars 117 forks source link

slack-insert-emoji: wrong-number-of-arguments with helm #517

Open chasecaleb opened 4 years ago

chasecaleb commented 4 years ago

Describe the bug Error when attempting to do slack-insert-emoji while helm-mode is enabled. If I disable helm-mode and enable ido-mode I do not have an issue. This is the line in helm (permalink) that it is blowing up on - helm only provides your predicate with a single arg instead of two. I'm not familiar enough with any of the libraries involved (slack, emojify, or helm) to know where the bug lies, so I thought I would start with an issue here. I don't mind filing an issue with a different project if you want me to, or you can as well.

Note: My Slack workspace a moderate amount custom emojis, but I'm guessing that doesn't have anything to do with that. I'm open to trying with a different workspace if you think that's relevant and can suggest one for me to join and test against.

To Reproduce Steps to reproduce the behavior:

  1. Enable helm-mode
  2. Open a slack channel
  3. Invoke slack-insert-emoji
  4. Type any character
  5. Error

Backtrace Too big to fit in character limit and I couldn't quickly figure out a way to truncate lines, so I put it in a gist: https://gist.github.com/chasecaleb/6f11c36b60192c7b62293781f7fb6ed2

Expected behavior Inserting an emoji should work with helm just like it does with ido.

Environment:

maurelio1234 commented 4 years ago

Hi,

I have the same problem when using ivy.

My environment:

https://gist.github.com/maurelio1234/69986f5c76ebcc7dec7af81a34bfac25

I can reproduce it when I try to (slack-message-add-reaction) on any slack buffer.

There goes a stack trace when I do (slack-select-emoji slack-current-team) :

https://gist.github.com/maurelio1234/69986f5c76ebcc7dec7af81a34bfac25

maurelio1234 commented 4 years ago

BTW, when I look at latest emacs-emojify commits I wonder if it comes from there:

dfa3c6d master origin/master Whoops; forgot to remove this…
194741e Revert this back to `completing-read`.

They are kind of related to that...

maurelio1234 commented 4 years ago

I have a temporary fix/explanation for that here:

https://github.com/maurelio1234/emacs-slack/commit/db57f08bcff529cffe7f68d2ba95eb3f527c17f0

I'm not sure that is a solution yet, but at least it got reactions working again on my computer...

powellc commented 3 years ago

Been a while, but I can confirm that this fixes the issue. Any chance of upstreaming this with a PR or some such @maurelio1234 ?

erichlf commented 3 years ago

This also seems to fix the same sort of issue with slack-message-add-reaction.

maurelio1234 commented 3 years ago

Hi, I will transform it on a PR to see what happens.

maurelio1234 commented 3 years ago

I have just created the PR, let's wait for some reaction from the maintainer on how to proceed on this.