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

users response not OK - limit_required #48

Closed
rmoff opened this issue Jul 5, 2023 · 6 comments
Closed

users response not OK - limit_required #48

rmoff opened this issue Jul 5, 2023 · 6 comments

Comments

@rmoff
Copy link
Contributor

rmoff commented Jul 5, 2023

This tool is great - it works really well, except on one Slack group:

gh slack read https://example.slack.com/archives/C1M5388TF/p1688463409836309
Error: users response not OK: {"ok":false,"error":"limit_required"}

There are ~30k users on this Slack, so perhaps this is the issue

If the collection is too large you may experience limit_required

@rneatherway
Copy link
Owner

👋 Apologies for the slow reply, my notifications were going to a defunct email address. This should be fairly simple to address by adding paging to the users call

func (c *SlackClient) users(params map[string]string) (*UsersResponse, error) {

You could use this function as an example:

func (c *SlackClient) conversations() ([]Channel, error) {

I'd be happy to review such a PR, or may get to it myself at some point!

@rneatherway
Copy link
Owner

This should be fixed by #61. Would you like to give it a test @rmoff?

@rmoff
Copy link
Contributor Author

rmoff commented Jun 11, 2024

Yes, happy to test it - how would i do that? :)

@rneatherway
Copy link
Owner

Great! If you checkout the PR and then run

go run ./cmd/gh-slack/ read https://example.slack.com/archives/C1M5388TF/p1688463409836309

that should be equivalent to the command that you pasted above.

@rmoff
Copy link
Contributor Author

rmoff commented Jun 11, 2024

Works perfectly. thanks!

@rneatherway
Copy link
Owner

Released!

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

No branches or pull requests

2 participants