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

Updating version_check function #180

Open
wants to merge 11 commits into
base: master
Choose a base branch
from

Conversation

Conor0Callaghan
Copy link

What do these changes do?

These changes check that the create-aio-app is the latest version, PR requested by @Arfey #104 (comment)

@Conor0Callaghan Conor0Callaghan changed the title Updating version_check function following comments Updating version_check function Apr 15, 2020
@lgtm-com
Copy link

lgtm-com bot commented Apr 15, 2020

This pull request introduces 1 alert when merging 7ed8c7f into 88bf768 - view on LGTM.com

new alerts:

  • 1 for Except block handles 'BaseException'

@Arfey
Copy link
Member

Arfey commented May 15, 2020

Hi. Could u fix problem with error in build?

@Conor0Callaghan
Copy link
Author

I can't really see what the issue is @Arfey it seems to be failing on library click, but click is already in the requirements and is imported as part of the travis build.

@Arfey
Copy link
Member

Arfey commented May 21, 2020

I see 2 error with bandit

>> Issue: [B310:blacklist] Audit url open for permitted schemes. Allowing use of file:/ or custom schemes is often unexpected.
771   Severity: Medium   Confidence: High
772   Location: ./create_aio_app/utils/versiontools.py:51
773   More Info: https://bandit.readthedocs.io/en/latest/blacklists/blacklist_calls.html#b310-urllib-urlopen
77450	    try: 
77551	        with urllib.request.urlopen(PYPI_URL, timeout=0.1) as req:
77652	            res = json.loads(req.read())
777
778--------------------------------------------------
779>> Issue: [B110:try_except_pass] Try, Except, Pass detected.
780   Severity: Low   Confidence: High
781   Location: ./create_aio_app/utils/versiontools.py:61
782   More Info: https://bandit.readthedocs.io/en/latest/plugins/b110_try_except_pass.html
78360	            click.secho('pip install --upgrade create-aio-app',fg='yellow')
78461	    except:
78562	        pass

Error with click so similar with circle import in python. I think that problem with this import

import create_aio_app

as solution u can try move import into version_check function but I think there is a better solution.

if u'll not find solution text me and we'll try solve together

Removing unneeded import
@lgtm-com
Copy link

lgtm-com bot commented May 21, 2020

This pull request introduces 1 alert when merging c4fb7b6 into 34b1e70 - view on LGTM.com

new alerts:

  • 1 for Except block handles 'BaseException'

Conor O'Callaghan added 2 commits May 21, 2020 22:53
Update urllib request to remove open and replace with Request
Fixing indentation
@lgtm-com
Copy link

lgtm-com bot commented May 21, 2020

This pull request introduces 2 alerts when merging b0a758f into 34b1e70 - view on LGTM.com

new alerts:

  • 1 for Unused local variable
  • 1 for Except block handles 'BaseException'

Fixing try except pass bandit issue
@lgtm-com
Copy link

lgtm-com bot commented May 21, 2020

This pull request introduces 1 alert when merging 3cbd444 into 34b1e70 - view on LGTM.com

new alerts:

  • 1 for Except block handles 'BaseException'

Update versiontools.py

Removing unneeded import

Update versiontools.py

Update urllib request to remove open and replace with Request

Update versiontools.py

Fixing indentation

Update versiontools.py

Fixing try except pass bandit issue
@Conor0Callaghan
Copy link
Author

I've refactored it to not use the import @Arfey but it still throws an error on the click import. Bandit is still throwing some warnings, but I expect them all.

@lgtm-com
Copy link

lgtm-com bot commented May 23, 2020

This pull request introduces 3 alerts when merging 5bad186 into 34b1e70 - view on LGTM.com

new alerts:

  • 2 for Unused import
  • 1 for Except block handles 'BaseException'

@lgtm-com
Copy link

lgtm-com bot commented May 23, 2020

This pull request introduces 1 alert when merging 1b8ec66 into 34b1e70 - view on LGTM.com

new alerts:

  • 1 for Except block handles 'BaseException'

@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

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

Successfully merging this pull request may close these issues.

None yet

3 participants