deno-slack-sdk icon indicating copy to clipboard operation
deno-slack-sdk copied to clipboard

[BUG] Unable to filter `slack activity` for datastore components

Open mroy-seedbox opened this issue 10 months ago • 4 comments

The deno-slack versions

"deno-slack-sdk/": "https://deno.land/x/[email protected]/",
"deno-slack-api/": "https://deno.land/x/[email protected]/",

Deno runtime version

deno 2.1.9 (stable, release, aarch64-apple-darwin)
v8 13.0.245.12-rusty
typescript 5.6.2

OS info

ProductName:		macOS
ProductVersion:		15.3.1
BuildVersion:		24D70
Darwin Kernel Version 24.3.0: Thu Jan  2 20:24:23 PST 2025; root:xnu-11215.81.4~3/RELEASE_ARM64_T8122

Describe the bug

Unable to specify a datastore as a --component-id for the slack activity command.

Steps to reproduce

slack activity --component-id 'Datastore:something'

Expected result

It works just the same as when we specify a component ID for a workflow (Wf184DU7M25W) or a function (Fn615CUMCEN2).

Actual result

Check /Users/someone/.slack/logs/slack-debug-20250304.log for error logs
The following error was returned by the apps.activities.list Slack API method

Received an invalid response from the server (http_response_invalid)
   `{"ok":false,"error":"invalid_args","errors":["component_id is invalid"]}` Couldn't be parsed as a json object (unable_to_parse_json)

   json: cannot unmarshal string into Go struct field activityResponse.extendedBaseResponse.errors of type slackerror.ErrorDetail

mroy-seedbox avatar Mar 04 '25 23:03 mroy-seedbox

Output from slack doctor:

SYSTEM

    ✔ Operating System (program scheduler and such)
        Version: darwin (amd64)

    ✔ Git (a version control system)
        Version: git version 2.39.5 (Apple Git-154)


SLACK

    ✔ CLI (this tool for building Slack apps)
        Version: v3.0.0

    ✔ Configurations (any adjustments to settings)
        System ID: a8d.................375
        Last updated: 2025-03-03 15:50:36 -08:00
        Experiments: bolt

    ✔ Credentials (your Slack authentication)
        Team domain: something
        Team ID: T...
        User ID: U...
        Last updated: 2025-03-04 14:29:14 -08:00
        Authorization level: Workspace
        Token status: Valid


PROJECT

    ✔ Configurations (your project's CLI settings)
        Manifest source: local
        Project ID: afa..........................330

    ✔ Runtime (foundations for the application)
        deno: 2.1.9
        Note: Applications deployed to Slack use Deno version 1.46.2 

        typescript: 5.6.2
        v8: 13.0.245.12-rusty

    ✔ Dependencies (requisites for development)
        deno_slack_sdk: 2.15.0
        deno_slack_api: 2.8.0

Errors: 0

mroy-seedbox avatar Mar 04 '25 23:03 mroy-seedbox

I realize that this is probably an issue with the Slack CLI, but there is no repo to report these yet (or to submit PRs).

mroy-seedbox avatar Mar 04 '25 23:03 mroy-seedbox

Well, on the bright side, I just discovered the apps.activities.list API! 😅

mroy-seedbox avatar Mar 04 '25 23:03 mroy-seedbox

Hi there,

Thanks for posting! It's true that only workflow or function ID are currently supported for the component_id flag but we'll mark this as a feature request for the CLI!

vegeris avatar Mar 07 '25 00:03 vegeris