Unable to select organisation github repository for deployment

Hi,

I have connected my work Github account to Streamlit. When I try to deploy an app, it is expecting the repo to be from my specific account (my-user-name/repo-name). However, the repository is part of my organisation on Github. It does not recognise ‘org-name/repo-name’ and gives a ‘This repository does not exist’ error.

I have tried using the alternate option of pasting the full URL. That gives the following error -

I was wondering if anyone else has faced this issue. Thanks.

Hi @mjo :wave:

Have you tried switching workspaces? Manage your app - Streamlit Docs

@snehankekre,

I can only see one workspace which is linked to my Github account. I cannot see a workspace for the Organisation. The repository is under the organisation.

How do I add a second workspace for the organisation?

Hi @mjo, please shoot us an email at support@streamlit.io and we’ll get this resolved for you. cc @Caroline

I just want to summarise the solution in case it can help others -

  • If the repository is under an Organisation in Github, then Streamlit needs to be given access to that Organisation as well and not just the user account of the person trying to deploy the app.
  • There needs to be at least one public repository inside the Organisation for Streamlit to establish a connection at the time of deployment on Streamlit Cloud. The app that is being deployed can itself be in a separate private repository. The support team mentioned that once deployment has been completed, this public repository can be deleted, but I have not tested this point.
1 Like

@mjo thanks so much for writing this up! A follow-up question –

If the repository is under an Organisation in Github, then Streamlit needs to be given access to that Organisation as well and not just the user account of the person trying to deploy the app.

How does one do this? (I am probably overlooking something that should be clear to me – thanks!)

@brahn
Giving Streamlit access to the Organisation can only be done by the person who owns the Organisation in Github. When you try to connect your Github account to Streamlit, the authentication request page that appears also has an option to request access to the Organisation your account belongs to (it is possible to miss it). In case you missed it, you can delink your Github account from Streamlit and repeat the process. Once you click on the button to request access to the Organisation for Streamlit, the owner will receive an email and they can approve the request.

Thanks @mjo ! I’m still not seeing the relevant options but will ping the support folks to see if we can resolve.

OK I managed to get this to work by asking another owner of the github org to authenticate and grant org access. That said, @snehankekre this was a bit of a winding road. Here’s what did not work –

  1. A colleague made me an owner of our github org. I then went to streamlit settings, attemped to disconnect and reconnect my github account. However, I was not prompted to authorize streamlit’s access to the org.

  2. A colleague who is an owner of the org created their own streamlit account. They were prompted to authorize access to the github org and did so. When they attempted to create the streamlit app they received an error indicating that they were in the wrong workspace and needed to switch using the menu in the upper right. However, clicking their avatar did not reveal an option for a separate workspace.

That said, after step 2 I reattempted to create the app, received the same message about switching workspaces, and was able to do so. So, success in the end!