Skip to content

When using 95th Percentiles, undefined index errors can be generated #3527

@bellwood

Description

@bellwood

Describe the bug

Running Version 1.2.11

Graphs using 95th show a flatline at 0. This behaviour started on v1.2.8.

When I try to edit one of these graphs, I get the following logged:

2020/05/01 08:16:44 - CMDPHP PHP ERROR NOTICE Backtrace: (/graphs.php[116]:graph_edit(), /graphs.php[1611]:rrdtool_function_graph(), /lib/rrd.php[1586]:variable_nth_percentile(), /lib/graph_variables.php[451]:nth_percentile(), /lib/graph_variables.php[36]:CactiErrorHandler())
--
2020/05/01 081:16:44 - ERROR PHP NOTICE: Undefined index: peak in file: /usr/local/share/cacti/lib/graph_variables.php on line: 36

This makes no sense as the nth_percentile function has a default argument $peak = false so how can it not be defined?

Metadata

Metadata

Assignees

No one assigned

    Labels

    aggregateAggregate related issuebugUndesired behaviourconfirmedBug is confirm by dev teamresolvedA fixed issue

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions