Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Separate python files for a better folder hierarchy #907

Closed
mervin-hemaraju-cko opened this issue Jun 5, 2023 · 2 comments
Closed

Separate python files for a better folder hierarchy #907

mervin-hemaraju-cko opened this issue Jun 5, 2023 · 2 comments
Labels
question Further information is requested

Comments

@mervin-hemaraju-cko
Copy link

Hello team,

Is it possible to separate my bolt app into multiple files.

For example, my python script currently looks like the below:

main.py

import....

app = App()

@app.error()
def error():
       ... something ...


@app.command()
def command():
       ... something ...

@app.event()
def event():
       ... something ...

I wanted to break this into multiple files namely main.py, command.py, event.py and error.py.

The slack_bolt version

slack-bolt 1.18.0
slack-sdk 3.21.3

Python runtime version

Python 3.10.11

OS info

ProductName: macOS
ProductVersion: 13.3.1
ProductVersionExtra: (a)
BuildVersion: 22E772610a
Darwin Kernel Version 22.4.0: Mon Mar 6 20:59:28 PST 2023; root:xnu-8796.101.5~3/RELEASE_ARM64_T6000

Steps to reproduce:

(Share the commands to run, source code, and project settings (e.g., setup.py))

N/A

Expected result:

Have slack bolt resource in multiple files

Actual result:

Everything resides in main.py

Requirements

Please read the Contributing guidelines and Code of Conduct before creating this issue or pull request. By submitting, you are agreeing to those rules.

@eddyg
Copy link
Contributor

eddyg commented Jun 5, 2023

Issues #236 and #320 might be helpful.

@filmaj filmaj added the question Further information is requested label Jun 5, 2023
@mervin-hemaraju-cko
Copy link
Author

@eddyg Thanks to the 2 issues that you mentioned, i was able to find this repository through them: https://github.com/slack-samples/bolt-python-starter-template
Thank you so much!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants