Showing 161 of 211 total issues
Function fuse
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def fuse(self, id1, id2, dim1=None, dim2=None, sync=True):
Function __new__
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __new__(cls, markers, subdomains, mapping, cpp=True, **kwargs):
Function plot_arrow
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def plot_arrow(a, x, y, dx, dy):
Function __new__
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __new__(cls, markers, subdomains, mapping, cpp=True, **kwargs):
Function diffraction_efficiencies
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def diffraction_efficiencies(
Function download_example_data
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def download_example_data(
Function _adaptive_sampler
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def _adaptive_sampler(f, z0, max_bend=10, max_z_rel=1e-3, max_df=0.05):
Function simp
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def simp(a, s_min=1, s_max=2, p=1, complex=True):
Function get_stack_efficiencies
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def get_stack_efficiencies(thicknesses, epsilon, mu, lambda0, angles):
Function rotate
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def rotate(self, tag, point, axis, angle, dim=None):
Function get_coeffs_stack
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def get_coeffs_stack(config, lambda0, theta0, phi0, psi0):
Function add_square
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def add_square(self, x, y, z, dx, **kwargs):
Function maxwell
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def maxwell(self, u, v, epsilon, inv_mu, domain="everywhere"):
Function __init__
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(
Function get_cross_sections_analytical
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def get_cross_sections_analytical(k0, a, eps_sphere=4, eps_bg=1, Nmax=25):
Function __new__
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __new__(self, markers, subdomains, mapping, cpp=True, **kwargs):
Function __new__
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __new__(self, markers, subdomains, mapping, cpp=True, **kwargs):
Function density_proj_filt
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def density_proj_filt(self, density, proj, filt, filtering_type):
Function env_get_outdated
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def env_get_outdated(app, env, added, changed, removed):
Function jacobian_matrix
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
Open
def jacobian_matrix(self):
if self.direction == "x":
s = self.stretch, 1, 1
elif self.direction == "y":
s = 1, self.stretch, 1
- 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"