Babble Chat

I question that answer… First of all wanting to detect the back button is definitely the wrong style, what should probably happen (I’m not using Babble yet but it will be installed on the next refresh of one of my forums so I’m preparing) is when the chat is opened then the url is changed to something like /chat or whatever, or a hash is added like #chat or so (saving prior value) and that is pushed onto the navigation.history stack. The plugin should always be listening to changes on the navigation.history stack and it should open the interface when the appropriate url/hash is set (which also allows someone to bookmark the location to one, especially if you change the hash by replacements instead of pushes as someone navigates a chat). When someone hits back then the navigation.history top no longer has the appropriate hash and thus the chat window should be removed, or if they click a close button or so then all you have to do is pop() the navigation.history stack to remove the chat hash (of which removing would then be seen by the listener and would then close it). This ensures that the chat is only opened or closed in regards to the url/hash changing, and the chat could even add ‘more’ onto the hash (#/chat/somegroup/somemsgid or so) to jump immediately to a specified group chat or message or so, thus encoding the entire view state into the hash, which is great for bookmarking, sharing links to some message in the history, etc… and if that ‘replaces’ the top of the navigation.history stack then a single back or history-pop will entirely remove the chat regardless (or feel free to ‘push’/‘pop’ certain setups like different message groups or so).

Even better if this is handled via a URL instead that is also handled by the server for fast and direct loading as well (it would still allow you to overlay the chat on any other path via javascript of course).

Thanks for the report @Shayham_Kabir , I’ve patched this in latest.

For future reference, please PM me any XSS-related bugs directly, as I’d rather not have them out in public where people can more easily use them.

2 Likes

I’m sorry for that and sure next time I’ll PM you.
Thanks for giving us this awesome plugin :hugs:

can a channel be exported to a normal topic ?

You could try something like the following in the console:

Topic.find_by(title: <chat_topic_title>).update(archetype: Archetype.regular)

But it’s not a supported thing and because the rules are different between making chat posts and topic posts (topic posts must be at least 15 characters, for example) it’s quite possible you’ll run into issues around things like editing or flagging or perhaps even liking posts that have been ported over from a chat topic.

1 Like

@gdpelican, I’m not sure what this means:

Does this mean that there’s a chat history somewhere in Discourse’s topics/categories in case I need to do a search of the chat contents?

Hi @gnyma,

The chat contents are in the database, but they don’t appear in search results currently (the whole nature of chat is relatively high-volume, low-quality postings, so I’ve put in code to prevent them from being indexed or appearing in searches)

I’d be happy if someone wrote some code to add a ‘include chats’ checkbox to the advanced search page, but it’s not a thing I’ll work on in the immediate future.

1 Like

Thanks for the explanation @gdpelican! The plugin is working great, by the way – I appreciate the work you put into it. :slight_smile:

1 Like

Hi all,

I’ve got a bit of an issue here which I’m not sure counts as a bug. So I’d like to ask you for some advice! :slight_smile:

In short: We use Babble for chats, and every now and then we delete the current channel and start a new one - don’t want people to use this as an alternative to a topic.

However, internally chats are treated as topics, but posts there are not searchable and so on. Some functionality was enhanced not too long ago and I think that my problem may be related to this.

In short: I have around 2.500 posts linked to a topic that used to exist and was used as a chat-topic. The topic doesn’t exist anymore, but the posts are still referring that topic.

The problem now is that I can’t delete those messages, or put differently: users can’t delete their own account any more since those posts can’t be deleted:

Failed to process hijacked response correctly : Couldn't find Topic with 'id'=2348

Is there a way for me to remove these messages from the database in a way that doesn’t mess up other stuff?

Thanks in advance!

Hi all,

Seems this wasn’t related to Babble but a regression bug fixed here:

1 Like

Hi guys, just read the features and doc about the plugin, seems really awesome, however, one quick question:

If I have the “Approve TL0 Users Content” flag enabled for the main forum, will it also be applicable to the Babble chat? Or is it “outside” of that rule?

Thanks!

Hey @Iceman,

Babble doesn’t look at that setting, so TL0 users will be able to post in any chats they can see (we don’t have ‘view / edit’ level permissions on chats… yet?) You can of course prevent TL0 users from posting things in chats by making all of your chats accessible to TL1 or above.

1 Like

I’ve read through the thread as much as I could they are LONG! I am wondering if someone can summarize the security aspects of the plugin. I can’t seem to find a specific post on it.
Can I limit this to certain trust level users? can I limit it to certain categories only?

1 Like

Short answer: yes on all counts!

There are two types of chats, ones which are secured by categories, and one which is secured by one or more groups. You can create a chat available to everyone by assigning ‘trust_level_0’ as its group, or one available to TL2 and above by assigning ‘trust_level_2’ as its group.

2 Likes

Where’s auto-open function, will it be available?

1 Like

This is a stupendous plug-in. One minor quibble. Can admins delete the first post in a chatroom? I can delete or edit all subsequent posts except the first. For setting out chatroom channel rules or discussion guidelines for each channel, it is often helpful to edit them as circumstances change and hindsight comes into play. Having to go through and delete a chatroom, lose its entire history, and then recreate a chatroom just to make a new first post seems like a silly exercise. Otherwise, this is wonderful. This saves me the trouble of a separate chatroom (including processing overhead and moderation staff) from my forum.

Hey Guys

my Chat topic has reached 10000 posts and was closed by the system account.
Is creating a new chat room to replace the current one the only way?

Or is there a better seamless way?

Can you describe what ‘closed’ means here? Is it not letting you post further? What’s the behaviour you see after it hits the 10k limit?

Just installed the Plugin, getting the following Error when trying to create a Chat Channel

I have tried doing it for groups and or categories, same result. Any ideas?

Discourse Version: [v2.2.0.beta7 +126]
Bable: 4.0.9

1 Like

Same here, my chat channel dissapeared and now I cant create a channel :frowning:

1 Like