-
Notifications
You must be signed in to change notification settings - Fork 224
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
Issues Parsing the Proxy Settings #124
Labels
Comments
ah good find, this was some techdebt that wasn't captured - I never got around to validating this feature. |
thebigG
added a commit
to thebigG/JobFunnel
that referenced
this issue
Nov 26, 2020
thebigG
added a commit
to thebigG/JobFunnel
that referenced
this issue
Dec 13, 2020
thebigG
added a commit
to thebigG/JobFunnel
that referenced
this issue
Dec 13, 2020
thebigG
added a commit
to thebigG/JobFunnel
that referenced
this issue
Dec 13, 2020
thebigG
added a commit
to thebigG/JobFunnel
that referenced
this issue
Dec 14, 2020
thebigG
added a commit
to thebigG/JobFunnel
that referenced
this issue
Dec 15, 2020
thebigG
added a commit
to thebigG/JobFunnel
that referenced
this issue
Dec 15, 2020
EmersonCosta0915
pushed a commit
to EmersonCosta0915/JobFunnel
that referenced
this issue
Aug 6, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi everyone!
Hope you are all doing well.
Description
While testing the proxy capabilities I discovered that the proxy parsing/validation is not quite correct.
Steps to Reproduce
settings_USA.yaml
and uncomment the bottom of it:NOTE: Notice how I removed the single quotes from the
port
field. This is something I'll fix when I push these fixes(along with unit testing for proxy.py)funnel load -s demo/settings_USA.yaml
TypeError: _validate_type_ipv4address() missing 1 required positional argument: 'value'
The error stack is larger than that, but I'm trying to stay brief.
There are two issues happening here.
cerberus
API does not pass 2 arguments to custom validators, like this function expects:def _validate_type_ipv4address(self, field, value):
It expects 1. One can see this on the Cerberus API on this snippet of code which is on
cerberus/validator.py
:the function
type_handler
points to_validate_type_ipv4address
, and as you can see it only passes 1 argument,value
.Easy fix: make
_validate_type_ipv4address
take 1 argument.Once I fixed that, there was another issue:
This has to do with two functions in the code.
First this function:
Notice how I added
return True
at the end of the try statement.The second function on
cli.py
:This fucntion expects a value from
_validate_type_ipv4address
, but it returns None(at least the current version of it). Hence the newreturn True
in_validate_type_ipv4address
.Hopefully this explanation makes sense.
I will be working on fixing these issues, and will also add unit testing to
proxy.py
.Cheers!
Expected behavior
jobfunnel
should scrape normally with proxy settings on.Actual behavior
The errors described above.
Environment
JobFunnel 3.0.1
on commit cf80740Pop!_OS 20.04 LTS
Cinnamon
The text was updated successfully, but these errors were encountered: