Kanaries / pygwalker

PyGWalker: Turn your pandas dataframe into an interactive UI for visual analysis
https://kanaries.net/pygwalker
Apache License 2.0
10.83k stars 549 forks source link

Clone repo and run locally #532

Closed JeevankumarDharmalingam closed 2 months ago

JeevankumarDharmalingam commented 3 months ago

Can we clone this repo locally and run with available files for streamlit. Can you please throw some light upon it

longxiaofei commented 3 months ago

Do you need to develop pygwalker, or just import it?

Local develop, refer it: https://pygwalker.kanaries.net/installation#local-development

Import it, download the built package, https://pypi.org/project/pygwalker/#files

JeevankumarDharmalingam commented 3 months ago

I need to add some features like Authorization and Authentication, So i need to work on the api's coming back from communication.ts add security features and need to validate it in backend while using it in streamlit. Will PYG-Walker Work with Gradio as well ?

longxiaofei commented 3 months ago

Maybe you can consider putting authentication data into cookies, then patching pygwalker

from pygwalker.communications import streamlit_comm

class PrvivatePygwalkerHandler(streamlit_comm.PygwalkerHandler):
    def post(self, gid: str):
        print(self.cookies)
        return super().post(gid)

streamlit_comm.PygwalkerHandler = PrvivatePygwalkerHandler
longxiaofei commented 3 months ago

gradio demo: https://github.com/Kanaries/pygwalker/blob/main/examples/gradio_demo.py

JeevankumarDharmalingam commented 3 months ago

Any plans to develop it as dashboard kind of app ?

ObservedObserver commented 3 months ago

Basically, you can develop a dashboard system based on pygwalker with streamlit/gradio or even flask. If you want a out-of-box solution, you can connect your pygwalker with kanaries cloud, in which you can publish your work from pygwalker to cloud, edit, share and embed anywhere. We also provide OpenAPI for some developers to develop their own dashboard system without building the whole system by themselves.

For open source, we are considering wthether to open source an independent dashboard editing system in pygwalker ecosystem, not a part of pygwalker.

JeevankumarDharmalingam commented 3 months ago

Is there demo where we can develop POC with Flask and having pygwalker part (section) of another Application, Or can you please guide this community how to do it

JeevankumarDharmalingam commented 2 months ago

Hey Kindly lemme know the wrap up for flask getting started

longxiaofei commented 2 months ago

Hi @JeevankumarDharmalingam , I will try to use flask or other web frameworks to build a POC in next week.

JeevankumarDharmalingam commented 2 months ago

Thanks that would be helpful, Appreciate it !

longxiaofei commented 2 months ago

@JeevankumarDharmalingam refer it: https://github.com/Kanaries/pygwalker/blob/main/examples/web_server_demo.py

JeevankumarDharmalingam commented 1 month ago

Thanks for the demo , there's one more request in below api is called from pygwalker http://127.0.0.1:8080/_pygwalker/comm/test0

Is it possible to add bearer token in the header of this api call ?