Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@samcorky
Copy link
Contributor

@samcorky samcorky commented Aug 9, 2024

Enable logging of button press events in Slack plugin for space open/close actions. This includes saving logs to the database and capturing client IP and hostname, along with a stub for testing log inputs.

Only tested with stubbed data (see tests subdirectory in new plugin)

Data gets logged to:

  • Database:
    space_smibhid
  • Collection:
    smibhid-ui-logs

Enable logging of button press events in Slack plugin for space open/close actions. This includes saving logs to the database and capturing client IP and hostname, along with a stub for testing log inputs.
@samcorky samcorky requested a review from sjefferson99 August 9, 2024 16:54
@samcorky samcorky linked an issue Aug 9, 2024 that may be closed by this pull request
samcorky and others added 7 commits August 9, 2024 17:55
Removed the debug logging of the entire event object to streamline the code. This reduces unnecessary logging output, improving clarity and efficiency in handling device IPs and hostnames.
…nitial response, which is overridden with a custom one anyway.

The issue was with the slack to_bolt_request() call, which didn't like JSON arrays as the top level json element.

Changed test log stub to output UTC time
Copy link
Member

@sjefferson99 sjefferson99 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code structure looks good.
Tested new docker and smibhid elements on my test rig and all works as expected.

@samcorky
Copy link
Contributor Author

Can you re-approve?

Copy link
Member

@sjefferson99 sjefferson99 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Re approved.

@samcorky samcorky merged commit 9bd88af into master Aug 10, 2024
@sjefferson99 sjefferson99 deleted the smibhid-ui-log-to-db branch August 10, 2024 16:25
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

Successfully merging this pull request may close these issues.

Capture which smibhid did the thing into the database

3 participants