tinode / chat

Instant messaging platform. Backend in Go. Clients: Swift iOS, Java Android, JS webapp, scriptable command line; chatbots
GNU General Public License v3.0
12.06k stars 1.88k forks source link

discovery tags #56

Closed bogdantarasenkozp closed 6 years ago

bogdantarasenkozp commented 6 years ago

Hi guys,this is the most awesome open-source product that i saw, but i found a bug, i cant create more then 3 tags on 'acc' it responds with error 500

or-else commented 6 years ago

Thanks for the bug report. Could you please provide a bit more details? Specifically, if you are using the web client, open the browser console and copy the log of commands.

or-else commented 6 years ago

Actually, never mind. I can reproduce it. Thanks!

bogdantarasenkozp commented 6 years ago

2017-12-20 02-30-57

bogdantarasenkozp commented 6 years ago

Thank you for reply) the error 500 appears when i add more then 3 tags, if there are 1, 2 or 3 tags everything works good

or-else commented 6 years ago

I was wrong, this is something else. Since you are running your local server, could you also show the server logs when this happens?

Are you using the stock config file? If you've changed it, can you share what you have for "indexable_tags": ["foo",...], in the config?

I suspect it may not actually be a bug but rather an unclear error message. Indexable tags are supposed to be unique. You may be trying to add a non-unique tag. I.e. gender:female is likely to be non-unique.

If you want to add extra account info, add it to the public or private fields.

or-else commented 6 years ago

I've updated error handling for duplicate tags: https://github.com/tinode/chat/commit/91ab467d55963e03f7c6b2b4c194d470c46c1aa4 I'm certain that you will start receiving error 409 instead of 500.

bogdantarasenkozp commented 6 years ago

yeah,you absolutly right, thank you for responce