Skip to content

Qodo AntiSlop scan found 16 issues across 3 recent PRs #17

Description

@gvago

Hey team,

A user recently scanned this repo using Qodo's AntiSlop Scanner. The analysis reviewed 3 recent PRs and found 16 issues, all confirmed to still exist on main.

Here's one example:

Broken date array math in aggregateRatings

Severity: action_required | Category: correctness

aggregateRatings.dateArray() constructs dates via new Date(now.getDate() - days) and returns an empty array for days=0, making dtoday undefined and generating incorrect date keys (often in 1970). This makes calculated averages incorrect or always zero.

How to validate: Call aggregateRatings.dateArray(0) and inspect the returned array (it will be empty). Call with any positive number and check that dates fall in 1970 instead of the current period.

Agent prompt to fix:

In aggregateRatings.dateArray(), fix the date construction to use new Date(now.getTime() - days * 86400000) instead of new Date(now.getDate() - days). Handle the days=0 case to return an array containing today's date instead of an empty array.


Other confirmed issues

# Title Category PR
1 Unguarded filters iteration throws TypeError correctness #2
2 Wrong datemax comparator ($gte instead of $lte) correctness #2
3 Average sort key mismatch with stored keys correctness #2
4 Non-atomic rating updates lose concurrent votes reliability #2
5 Default index creation disabled by wrong env check performance #2
6 Friendslist mutated in-place maintainability #2
7 Unknown leaderboard error message for code 207 observability #1
8 IDE metadata committed maintainability #9

7 additional findings (including suspected issues) are available in the full report.

Enjoy!

P.S. Qodo offers free tooling for open-source maintainers: https://www.qodo.ai/solutions/open-source/

cc @benlowry

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions