MarketSquare / MarketSquare/robotframework-requests

Disable warnings not working properly?

Open
#366 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
512
Forks
283
PR merge metrics
No merged PRs in 30d

Description

I am using version 0.9.4 on RF 4.1.3.
I have weird behavior of disable_warnings=1.
I set this option on create session together with max_retries=5.
To check if I have a proper connection I execute a valid command on get on session.
If the connection is bad I get 5 warnings on console before the keyword fails.
I can suppress these warnings if I add disable_warnings=1 on get on session!
If the connection is OK I get an error:
TypeError: request() got an unexpected keyword argument 'disable_warnings'

Looking at the documentation disable_warnings is not allowed on get on session.
But I do not want those warnings displayed on console for a bad connection and can successfully suppress them by using this parm on get on session.
Following the documentation apparently the disable_warnings set on create session is not inherited for the get on session?

Is this a bug?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue through the Create Session and get on session entry points using disable_warnings=1 and max_retries=5, comparing failed and successful connections. Trace how session options are passed to the request call; done means inherited suppression works without passing the unsupported argument to get on session.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
api, backend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.