Showing 713 of 713 total issues
FIXME found Open
x, y, z = self._select_coords(use, bins=bins) # TODO FIXME
- Create a ticketCreate a ticket
- Exclude checks
TODO found Open
# TODO: tests on the second dimension...
- Create a ticketCreate a ticket
- Exclude checks
TODO found Open
0]): # TODO should this be moved out of assign_layers?
- Create a ticketCreate a ticket
- Exclude checks
TODO found Open
# TODO: should move all AtomGroup references to a higher level
- Create a ticketCreate a ticket
- Exclude checks
TODO found Open
# TODO the successive layers analysis should be done by removing points
- Create a ticketCreate a ticket
- Exclude checks
TODO found Open
# TODO: add a flag to prevent recomputing the reference frame, in case
- Create a ticketCreate a ticket
- Exclude checks
TODO found Open
# TODO: tests on the second dimension...
- Create a ticketCreate a ticket
- Exclude checks
TODO found Open
# TODO: does it need extension to 2- or 1- dimensional frames?
- Create a ticketCreate a ticket
- Exclude checks
Rename function "_NN_query" to match the regular expression ^[a-z_][a-z0-9_]{2,}$. Open
def _NN_query(kdtree, position, qrange):
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Shared coding conventions allow teams to collaborate efficiently. This rule checks that all function names match a provided regular expression.
Noncompliant Code Example
With the default provided regular expression: ^[a-z_][a-z0-9_]{2,30}$
def MyFunction(a,b): ...
Compliant Solution
def my_function(a,b): ...
Rename function "patchOpenMM" to match the regular expression ^[a-z_][a-z0-9_]{2,}$. Open
def patchOpenMM(simulation, interface):
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Shared coding conventions allow teams to collaborate efficiently. This rule checks that all function names match a provided regular expression.
Noncompliant Code Example
With the default provided regular expression: ^[a-z_][a-z0-9_]{2,30}$
def MyFunction(a,b): ...
Compliant Solution
def my_function(a,b): ...
Rename function "EulerRotation" to match the regular expression ^[a-z_][a-z0-9_]{2,}$. Open
def EulerRotation(phi, theta, psi):
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Shared coding conventions allow teams to collaborate efficiently. This rule checks that all function names match a provided regular expression.
Noncompliant Code Example
With the default provided regular expression: ^[a-z_][a-z0-9_]{2,30}$
def MyFunction(a,b): ...
Compliant Solution
def my_function(a,b): ...
Remove this commented out code. Open
# return cartesian[:,self.dirmask]
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Programmers should not comment out code as it bloats programs and reduces readability.
Unused code should be deleted and can be retrieved from source control history if required.
See
- MISRA C:2004, 2.4 - Sections of code should not be "commented out".
- MISRA C++:2008, 2-7-2 - Sections of code shall not be "commented out" using C-style comments.
- MISRA C++:2008, 2-7-3 - Sections of code should not be "commented out" using C++ comments.
- MISRA C:2012, Dir. 4.4 - Sections of code should not be "commented out"
Rename function "polygonalArea" to match the regular expression ^[a-z_][a-z0-9_]{2,}$. Open
def polygonalArea(points):
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Shared coding conventions allow teams to collaborate efficiently. This rule checks that all function names match a provided regular expression.
Noncompliant Code Example
With the default provided regular expression: ^[a-z_][a-z0-9_]{2,30}$
def MyFunction(a,b): ...
Compliant Solution
def my_function(a,b): ...
Method "__init__" has 8 parameters, which is greater than the 7 authorized. Open
def __init__(self,
direction=None,
observable=None,
interface=None,
symmetry='default',
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
A long parameter list can indicate that a new structure should be created to wrap the numerous parameters or that the function is doing too many things.
Noncompliant Code Example
With a maximum number of 4 parameters:
def do_something(param1, param2, param3, param4, param5): ...
Compliant Solution
def do_something(param1, param2, param3, param4): ...
Refactor this function to reduce its Cognitive Complexity from 21 to the 15 allowed. Open
def _assign_layers(self):
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Cognitive Complexity is a measure of how hard the control flow of a function is to understand. Functions with high Cognitive Complexity will be difficult to maintain.
See
Remove this commented out code. Open
if np.isclose(fac, 0.0): # a=c and b=0
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Programmers should not comment out code as it bloats programs and reduces readability.
Unused code should be deleted and can be retrieved from source control history if required.
See
- MISRA C:2004, 2.4 - Sections of code should not be "commented out".
- MISRA C++:2008, 2-7-2 - Sections of code shall not be "commented out" using C-style comments.
- MISRA C++:2008, 2-7-3 - Sections of code should not be "commented out" using C++ comments.
- MISRA C:2012, Dir. 4.4 - Sections of code should not be "commented out"
Refactor this function to reduce its Cognitive Complexity from 20 to the 15 allowed. Open
def sample(self, g1=None, g2=None, kargs1=None, kargs2=None):
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Cognitive Complexity is a measure of how hard the control flow of a function is to understand. Functions with high Cognitive Complexity will be difficult to maintain.
See
Refactor this function to reduce its Cognitive Complexity from 18 to the 15 allowed. Open
def _assign_one_side(self,
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Cognitive Complexity is a measure of how hard the control flow of a function is to understand. Functions with high Cognitive Complexity will be difficult to maintain.
See
Rename function "patchTrajectory" to match the regular expression ^[a-z_][a-z0-9_]{2,}$. Open
def patchTrajectory(trajectory, interface):
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Shared coding conventions allow teams to collaborate efficiently. This rule checks that all function names match a provided regular expression.
Noncompliant Code Example
With the default provided regular expression: ^[a-z_][a-z0-9_]{2,30}$
def MyFunction(a,b): ...
Compliant Solution
def my_function(a,b): ...