Skip to content

Commit 4984ead

Browse files
donnapepclaude
andcommitted
Add changelogs, Psalm baseline, and AGENTS.md updates
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent c9d2d69 commit 4984ead

File tree

5 files changed

+38
-1
lines changed

5 files changed

+38
-1
lines changed

AGENTS.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
## Linting
22
- **PHPCS**: Run `npm run lint-php`.
3+
- **Psalm**: Run `vendor/bin/psalm --no-cache --diff`.
4+
- **Before pushing**: The pre-commit hook only lints new files. CI lints all changed lines. Always run both PHPCS and Psalm on modified files before pushing to avoid CI failures.
35

46
## Conventions
57
- **Changelogs**: Every user-facing change MUST have a changelog entry before opening a PR. Run `npm run changelog` (entries stored in `changelog/`).
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
Significance: minor
2+
Type: added
3+
4+
Internal: Integrate HPPS in reports backend.
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
Significance: patch
2+
Type: fixed
3+
4+
Fix Course Reports Last Activity showing an arbitrary date instead of the most recent activity date across all lessons.
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
Significance: patch
2+
Type: fixed
3+
4+
Fix Days to Completion calculation in Reports to exclude lessons with ungraded or failed quizzes, which do not have a valid completion date.

config/psalm/psalm-baseline.xml

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1620,6 +1620,14 @@
16201620
</file>
16211621
<file src="includes/class-sensei-grading-main.php">
16221622
<ArgumentTypeCoercion occurrences="1"/>
1623+
<InvalidArrayAccess occurrences="6">
1624+
<code>$counts['complete']</code>
1625+
<code>$counts['failed']</code>
1626+
<code>$counts['graded']</code>
1627+
<code>$counts['in-progress']</code>
1628+
<code>$counts['passed']</code>
1629+
<code>$counts['ungraded']</code>
1630+
</InvalidArrayAccess>
16231631
<MissingParamType occurrences="1">
16241632
<code>$args</code>
16251633
</MissingParamType>
@@ -4549,11 +4557,25 @@
45494557
</PossiblyInvalidPropertyFetch>
45504558
</file>
45514559
<file src="includes/internal/services/class-comments-based-progress-aggregation-service.php">
4560+
<PossiblyInvalidPropertyFetch occurrences="5">
4561+
<code>$row-&gt;days_to_complete_count</code>
4562+
<code>$row-&gt;days_to_complete_sum</code>
4563+
<code>$row-&gt;lesson_completed_count</code>
4564+
<code>$row-&gt;lesson_start_count</code>
4565+
<code>$row-&gt;unique_student_count</code>
4566+
</PossiblyInvalidPropertyFetch>
45524567
<UndefinedConstant occurrences="1">
45534568
<code>ARRAY_A</code>
45544569
</UndefinedConstant>
45554570
</file>
45564571
<file src="includes/internal/services/class-tables-based-progress-aggregation-service.php">
4572+
<PossiblyInvalidPropertyFetch occurrences="5">
4573+
<code>$row-&gt;days_to_complete_count</code>
4574+
<code>$row-&gt;days_to_complete_sum</code>
4575+
<code>$row-&gt;lesson_completed_count</code>
4576+
<code>$row-&gt;lesson_start_count</code>
4577+
<code>$row-&gt;unique_student_count</code>
4578+
</PossiblyInvalidPropertyFetch>
45574579
<UndefinedConstant occurrences="2">
45584580
<code>ARRAY_A</code>
45594581
</UndefinedConstant>
@@ -4827,7 +4849,8 @@
48274849
<InvalidArgument occurrences="1">
48284850
<code>$lessons</code>
48294851
</InvalidArgument>
4830-
<InvalidScalarArgument occurrences="1">
4852+
<InvalidScalarArgument occurrences="2">
4853+
<code>$lesson_students</code>
48314854
<code>$value</code>
48324855
</InvalidScalarArgument>
48334856
<PossibleRawObjectIteration occurrences="1">

0 commit comments

Comments
 (0)