To celebrate the release of Snowpark for Python into GA and the release of the Streamlit integration into private preview, we’re going to do a doubled up Snowpark and Streamlit challenge!
Your challenge is to create an app that looks like the one below:
Requirements:
- You must allow the user to select between the following objects:
- ‘None’
- ‘Shares’
- ‘Roles’
- ‘Grants’
- ‘Users’
- ‘Warehouses’
- ‘Databases’
- ‘Schemas’
- ‘Tables’
- ‘Views’
- The app should display the FF logo
- It should display the version of Snowpark you are using
- It should display the results of show statements as a dataframe
- Schemas, tables, views and grants should be on the account level (i.e. not per database etc…)
Here’s the .png file for the logo, right click to download:
Remember, if you want to participate:
- Sign up as a member of Frosty Friday. You can do this by clicking on the sidebar, and then going to ‘REGISTER‘
- Post your code to GitHub and make it publicly available (Check out our guide if you don’t know how to here)
- Post the URL in the comments of the challenge
7 responses to “Week 24 – Intermediate”
-
Another fun challenge, thanks for putting it together. I must admit, I couldn’t figure out how a nice way to get the version details to appear at the bottom of the sidebar, so I’ve cheated and printed a bunch of blank lines instead. I suspect my version of streamlit isn’t updated as the docs suggest a method (not stating it here to avoid spoilers) but I don’t think that method is available in streamlit version 1.11.0; which I am using
- Solution URL – https://github.com/ChrisHastieIW/Frosty-Friday
-
Still getting to grips with streamlit (sidenote: how can we get access to that integration in SF?)
https://github.com/dsmdavid/frostyfridays-sf/blob/ch_24/extra/ch_24_readme.md
I reused the code from my challenge 12, only to later realise that we were supposed to use Snowpark. So ended up tweaking the original solution:
– One approach without Snowpark (just “regular” snowlake connector)
https://github.com/dsmdavid/frostyfridays-sf/blob/ch_24/extra/ch_24_streamlit.py
– One with Snowpark — could reuse most of it, just some minor tweaks needed.
https://github.com/dsmdavid/frostyfridays-sf/blob/ch_24/extra/ch_24_streamlit_snowpark.py -
I was not able to use Snowpark for this challenge, so I use the original Snowflake connector. As a consequence, the version of Snowpark is missing.
-
Here’s the link
-
Here’s the link
-
Here’s the solution url for YouTube webinar.
- Solution URL – https://github.com/TadakiKanenari/Frosty_Friday/blob/main/demo.py
Leave a Reply
You must be logged in to post a comment.