Is your feature request related to a problem? Please describe.
Since our company has patent-pending process patents, we don’t want the code in our app made public. We have implemented the suggested public → private space approach using Gradio.load in the public space. While it works in certain circumstances in 3.50.2, it’s now broken in 4.1.1. There are other limitations, especially when using auth=, since the username doesn’t get passed to the private space. We have also seen that the a .load in the private space throws an error. Overall, using this approach to keep files hidden really complicates the setup and stability of the app on HF.
Describe the solution you’d like
I would suggest that the Space → Settings have a switch (similar to Public/Private switch) that turns off the “Files” tab in the UI. That way we could have a Public space, with auth= turned on, but not expose our code to the general public. It should also not be possible to duplicate the space or clone the repo.