Showing 90 of 187 total issues
File bintray.py
has 3074 lines of code (exceeds 250 allowed). Consider refactoring. Open
""" Python Wrapper for Bintray API
https://bintray.com/docs/api
"""
import os
Bintray
has 157 functions (exceeds 20 allowed). Consider refactoring. Open
class Bintray(object):
""" Python Wrapper for Bintray API
"""
Function update_package
has 14 arguments (exceeds 4 allowed). Consider refactoring. Open
def update_package(self, subject, repo, package, licenses=None, vcs_url=None,
Function create_package
has 14 arguments (exceeds 4 allowed). Consider refactoring. Open
def create_package(self, subject, repo, package, licenses=None, vcs_url=None,
Function debian_upload
has 12 arguments (exceeds 4 allowed). Consider refactoring. Open
def debian_upload(self, subject, repo, package, version, remote_file_path, local_file_path,
Function update_package
has a Cognitive Complexity of 12 (exceeds 5 allowed). Consider refactoring. Open
def update_package(self, subject, repo, package, licenses=None, vcs_url=None,
custom_licenses=None, desc=None, labels=None, website_url=None,
issue_tracker_url=None, github_repo=None, github_release_notes_file=None,
public_download_numbers=None, public_stats=None):
""" Update the information of the specified package.
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function create_repository
has 11 arguments (exceeds 4 allowed). Consider refactoring. Open
def create_repository(self, subject, repo, type, description, private=False, labels=None,
Function create_package
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
def create_package(self, subject, repo, package, licenses=None, vcs_url=None,
custom_licenses=None, desc=None, labels=None, website_url=None,
issue_tracker_url=None, github_repo=None, github_release_notes_file=None,
public_download_numbers=None, public_stats=None):
""" Creates a new package in the specified repo (user has to be an owner of the repo)
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function _create_access_key
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
def _create_access_key(self, request_url, id, url=None, cache_for_secs=None, expiry=None,
white_cidrs=None, black_cidrs=None, api_only=False):
""" Create a new access key identified by an access key id
An access key password will be auto-generated if not specified.
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function update_repository
has 9 arguments (exceeds 4 allowed). Consider refactoring. Open
def update_repository(self, subject, repo, business_unit=None, description=None, labels=None,
Function create_entitlement
has 9 arguments (exceeds 4 allowed). Consider refactoring. Open
def create_entitlement(self, subject, repo=None, package=None, version=None,
Function upload_content
has 9 arguments (exceeds 4 allowed). Consider refactoring. Open
def upload_content(self, subject, repo, package, version, remote_file_path, local_file_path,
Function create_version
has 9 arguments (exceeds 4 allowed). Consider refactoring. Open
def create_version(self, subject, repo, package, version, description=None,
Function update_entitlement
has 9 arguments (exceeds 4 allowed). Consider refactoring. Open
def update_entitlement(self, subject, entitlement_id, repo=None, package=None, version=None,
Function create_entitlement
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
def create_entitlement(self, subject, repo=None, package=None, version=None,
access=None, access_keys=None, path=None, tags=None, product=None):
""" Create an entitlement on the specified scope. Scope can be a product, a repository with
an optional path, a package or a version.
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function update_version
has 8 arguments (exceeds 4 allowed). Consider refactoring. Open
def update_version(self, subject, repo, package, version, description=None,
Function _create_access_key
has 8 arguments (exceeds 4 allowed). Consider refactoring. Open
def _create_access_key(self, request_url, id, url=None, cache_for_secs=None, expiry=None,
Function create_access_key_user
has 8 arguments (exceeds 4 allowed). Consider refactoring. Open
def create_access_key_user(self, user, id, url=None, cache_for_secs=None, expiry=None,
Function create_product
has 8 arguments (exceeds 4 allowed). Consider refactoring. Open
def create_product(self, subject, name, display_name, desc, website, vcs, packages,
Function create_access_key_org
has 8 arguments (exceeds 4 allowed). Consider refactoring. Open
def create_access_key_org(self, org, id, url=None, cache_for_secs=None, expiry=None,