Coder Social home page Coder Social logo

ambro17 / slackify Goto Github PK

View Code? Open in Web Editor NEW
120.0 6.0 10.0 6.08 MB

Slackify: Lightweight framework to quickly develop modern Slack bots ๐Ÿš€

Home Page: https://ambro17.github.io/slackify/

License: GNU General Public License v3.0

Python 51.83% Makefile 0.42% Dockerfile 0.34% Mako 47.41%
python slack bot flask framework slack-events slackapi modern-slack-bots slackify slack-modals

slackify's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

slackify's Issues

Add compatibility layer with aws chalice

Is your feature request related to a problem? Please describe.
AWS chalice has a decorator approach to infer the required infraestrcture and deploy it automagically

Describe the solution you'd like
If one wants to deploy the bot without managing the server, it would be possible

Describe alternatives you've considered
But it could also be an external package, not in this lib

Does not appear possible to use as a Blueprint

I have an existing flask app that includes a Blueprint (mounted at /webhooks/slack) for responding to slack commands. I'd love to replace that Blueprint with slackify, but it doesn't look like it's possible. Would you be open to changing Flack to be a Blueprint rather than a Flask subclass?

[BUG] respond's slackify expects `str` but `dict`s are passed

Describe the bug
When using the respond function from slackify's slack file, it expects to receive a url and a message. Typing was set to str when the entire documentation recommends sending a dictionary with the blocks.

This raises some warnings in the editor and is just confusing. Could we clarify and update the typing type to Dict (from Python's official Typing library)?

To Reproduce
Steps to reproduce the behavior:

  1. Use respond() method from slackify.slack.
  2. Send params as per documented: respond(payload['response_url'], {'blocks': [text_blok]})

Expected behavior
If the library expects a str, a str should be use. If a dictionary, a dictionary should be used.

Desktop (please complete the following information):

  • OS: MacOS
  • Python: 3.8.5
  • Version 1.0.0

Additional context
As I think this is a minor bug, I'm opening a quick PR to fix this issue. Will mention this issue for reference.

how to pass parameters to an existing python file?

Hi,
I'm trying to deploy an app on Heroku.
The application contains 3 main files:

  • The web file, taken from your project.
  • My two main (separate) python files.

It seems I can't execute the other python file with some arguments ( I even tried to execute it w/o args. )
Heroku states that the file is not there. ( but, for sure it's there )
FileNotFoundError: [Errno 2] No such file or directory: 'main_time.py': 'main_time.py'
If you look at the pic, I do have the file.
I tried to excecute it by calling this function:
subprocess.call(['main_time.py', '2391', username, password])

The whole code could be found HERE and I'm on this issue for 4 days already, (newbie).

So, I think that an example of "how to execute external python files" is also needed. ( Python with arguments )

Appreciate all the help I will get here.

Add function to notify user of success/failure of operation taking in consideration posible unmet preconditions

Currently there's no single way to always send a message to a user. One can use the user id as the channel to chat.postMessage but it's not recommended by slack as it will be deprecated.

We should offer an abstraction over this.

It should be able to notify a user in the same chat (private or public channel, or direct message) that the command was invoked.
If certain precondition is not met, show a proper explanation and optionally send a message through slack bot using the user id as channel.

Events API change

The Events API is a system that apps can leverage to be notified of events and activity occurring in Slack. Changes are coming to the Events API that may impact your Slack apps.

On February 24th, 2021, event payloads from this system will send out authorization information related to the event in a new structure and format that returns a single authorization rather than a full list.

I got this email from Slack and I identified that your application still works with the old module.
Am I right here? Or I miss understand that email correctly.

Add instant deploy config with heroku

Several users asked for a beginner friendly, no config option to get a permanent url instead of heroku

Perhaps provide a heroku button if it is free

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.