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
[cli] bru run gets unexpected 401 Unauthorized
error for whatever run
#2174
Comments
hmmmm...maybe i didn't describe the issue clearly - I know 401 Unauthorized looks just like i miss authorization stuff. To make the issue more specific - Difference observed (with same simple request) between Bruno Client run and bru cli run.
Anybody pls could advise? |
@hmeng1024 It's a bit hard to narrow down without seeing the exact Bru file. How does the authorization on the Endpoint work? Could you instead make a request to something like: CLI and Electron/Client have different implementations for making requests, that often causes issues. |
@Its-treason Thank you for your reply and advice. It helped! The Basically what happened is one of my password VAR used in the PUT body cannot be resolved when it's a
Quick replication as below and that should be fair enough for a bug fix request :0
|
Yeah, that is a known Problem with secret variables: #2015 |
I have checked the following:
Describe the bug
Issue
Bru cli - bru run always gets a
401 Unauthorized
error and that blocks every test frombru cli
, while at the same time same request can be executed successfully frombru client
. (see pic-1 and pic-2 attached)Context
bru run
was doing good at the starting 2-3 days after i installed it about 10 days ago. Back at that time i canbru run folder
successfully with more than 10 req inside. (it was likely at client v1.12.x, bru ver not sure now)What have been tried
client
andcli
to latest v1.14.0folder
tosingle request
, fromtoken-required
scenario totoken-generation
scenarioWith above attempts, the issue is still there and shows exactly same error. The attached pics (pic-1 and pic-2) show a
temp request
intemp folder
doing a token api test. It can still run withClient runner
successfully, butbru cli
fails the same.Bru run traceback
The traceback shows
AssertionError
as 200 is expected in the Test. While if the test script is commented out, we can still see the401 Unauthorized
error (see pic-2).I'm not sure if i'm the only person experiencing this issue so far. It appears either 1) it's a
local env
config issue from my own or 2) likely a bug from bru cli run workflow.Can anyone pls shed some light here?
.bru file to reproduce the bug
No response
Screenshots/Live demo link
pic-1
pic-2
The text was updated successfully, but these errors were encountered: