Coder Social home page Coder Social logo

Comments (6)

brodock avatar brodock commented on August 24, 2024

This is what I receive, instead of the name, it replicates the ID:

#<Lita::Room:0x007f272a53e730 @id="C030B1KQ6", @metadata={}, @name="C030B1KQ6">

You can see this behavior using my plugin: https://github.com/brodock/lita-queue
There is an walkthrough here : https://github.com/brodock/lita-queue/issues/1

from lita-slack.

jimmycuadra avatar jimmycuadra commented on August 24, 2024

Lita::Adapters::Slack::SlackChannel is the class where this information is extracted from the raw data sent by Slack. At a glance it looks correct to me, but clearly it's not. I would be happy to accept a PR to fix this!

from lita-slack.

kingcons avatar kingcons commented on August 24, 2024

I'm also experiencing this bug. For whatever reason, a workaround that returns the correct information is doing Lita::Room.find_by_id("1234abcd").name or conversely, Lita::Room.find_by_name("foobarbazquux").id. If this is still open when I get back from the beach in a week, I'll submit a patch.

from lita-slack.

brodock avatar brodock commented on August 24, 2024

I still have to do a little debug, but suspect Slack isn't following its own API documentation for RTM's API

from lita-slack.

liamdawson avatar liamdawson commented on August 24, 2024

I can confirm @kingcons workaround succeeds, unless it's a private conversation, in which case the room cannot be found.

Any progress on the bug?

from lita-slack.

indirect avatar indirect commented on August 24, 2024

Still seeing this happen today, where response.message.source.room_object has a name that is actually the Slack room ID, where Lita::Room.find_by_id(response.message.source.room_object.id) has a name that is the correct name of the channel. :/

from lita-slack.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.