-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
Username field in the flag report is blank #4134
Comments
Thanks @gsachdev-adeptia for reporting! This is indeed broken, though we have a fix here: #4135 |
Thanks @abidlabs. Do you know when it will be available for revalidation? |
I think we'll merge in |
The fix is on |
I uninstall the gradio and installed it from the main branch as you indicated. Still not seeing any value filled in for the username in the flagged file. Do I need to do anything additional to have that written in the flagged file? |
I tested with this code and it's working for me on import gradio as gr
#login function
def same_auth(username, password):
return username == password
#setup gradio interface
iface = gr.Interface(fn=lambda x:x,
inputs=gr.components.Textbox(lines=7, label="Enter your text"),
outputs="text",
title="testing", allow_flagging="manual",flagging_options=["correct","wrong","ambiguous"])
#launch gradio
iface.launch(auth=same_auth) Can you try it and see if it works for you? You might need to delete the |
I am still getting blank user name. Is the below pip to get from main branch correct I suspect the above link is not correct. |
Please try:
|
It works now. I validated. Thanks for the quick fix. |
This is not working with Blocks. User Name is still blank. code to reproduce:
Gradio version: gradio-3.37.0 Can someone please help. |
@RNBharath One year later, I suspect you've already sorted this out, but I was running into a similar problem today. For anyone encountering this problem in the future, it looks like you need to explicitly pass the username/request to CSVLogger, similar to the code below:
@abidlabs, when following the documentation for the first time, it's very easy to just copy & paste Hope this helps! |
Describe the bug
The flag log file created from Gradio is having username column but value is empty.
Is there an existing issue for this?
Reproduction
#login function
def same_auth(username, password):
return username == password
#setup gradio interface
iface = gr.Interface(fn=chatbot,
inputs=gr.components.Textbox(lines=7, label="Enter your text"),
outputs="text",
title="testing", allow_flagging="manual",flagging_options=["correct","wrong","ambiguous"])
#launch gradio
iface.launch(share=True ,auth=same_auth)
Screenshot
Logs
System Info
Severity
annoying
The text was updated successfully, but these errors were encountered: