Skip to content
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

python3 compat? #28

Open
cyrinux opened this issue Jul 27, 2019 · 6 comments
Open

python3 compat? #28

cyrinux opened this issue Jul 27, 2019 · 6 comments
Assignees

Comments

@cyrinux
Copy link

cyrinux commented Jul 27, 2019

Hi,

I got this running example, after adding () to print() in dojo_populate.py, i got this one.

» ❯ python3 dojo_populate.py
Traceback (most recent call last):
  File "dojo_populate.py", line 27, in <module>
    dd = defectdojo.DefectDojoAPI(host, api_key, user, debug=False)
  File "/home/cyril/trydefectdojoapi/venv/lib/python3.7/site-packages/defectdojo_api/defectdojo.py", line 37, in __init__
    if host.split('/') > 3:
TypeError: '>' not supported between instances of 'list' and 'int'

Thanks for help

@Martin2877
Copy link

I have the same problem.

@damiencarol
Copy link
Contributor

seems an error in one of the scripts.
@Martin2877 @cyrinux The code your referring to was modified by @aaronweaver on Aug 14, 2018
=> 0eab5e5#diff-398ee4538a05ce9f45dc774f83e67aa783e808ab48aa91ad9ec26ce22bd2fb26

@jyotiraws
Copy link

i have the same problem but using defectdojo_api==1.1.3 helped

@benmeyer50
Copy link

Any updates on this?

@Siryu6
Copy link
Contributor

Siryu6 commented Dec 30, 2021

You can quickfix it in site-packages/defectdojo_api/defectdojo.py
Replace:
if host.split('/') > 3:
By:
if len(host.split('/')) > 3:

or build it from GitHub :)

@damiencarol
Copy link
Contributor

damiencarol commented Dec 31, 2021

FYI: this piece of code was removed in 0eab5e5#diff-398ee4538a05ce9f45dc774f83e67aa783e808ab48aa91ad9ec26ce22bd2fb26.
Should it be more simple to update the module to a new version?
This modification is part of 1.1.4

@damiencarol damiencarol self-assigned this Dec 31, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants