Skip to content

fix: fill thesis grade only in last semester and fix finish() redirect - #114

Merged
ffooll-bit merged 1 commit into
mainfrom
hotfix/thesis-grade-last-semester
Aug 31, 2026
Merged

fix: fill thesis grade only in last semester and fix finish() redirect#114
ffooll-bit merged 1 commit into
mainfrom
hotfix/thesis-grade-last-semester

Conversation

@ffooll-bit

Copy link
Copy Markdown
Owner

Summary

Fixes two blocking defects in the PISN graduation wizard's submission path plus the thesis-grade fill target:

  1. finish() fatal TypeError on submitGraduation::finish() was declared : string but returns a RedirectResponse, throwing TypeError: Return value must be of type string the moment the wizard is actually submitted to Neo Feeder. Changed the return type to CodeIgniter\HTTP\RedirectResponse.

  2. finish() time limit exceeded — the full submission iterates the whole batch with a synchronous Neo Feeder call chain per student (InsertMahasiswaLulusDO + academic edits + thesis grade), which could exceed PHP's default 60 s limit on large batches. Added set_time_limit(0) at the top of finish().

  3. Thesis grade fill targeted the wrong semester (ENH-010 regression) — when a student had several thesis/skripsi rows across semesters (e.g. retakes), card 3 tagged every missing-grade row "(akan diisi)" and finish() could push the Excel grade into an older row. Now only the thesis/skripsi in the last semester (id_smt largest) is targeted, and only while that row is still ungraded; if the last-semester thesis already has a grade, no value is filled and no older row is backfilled.

Fixes

#113

Checklist

  • php -l clean on changed files
  • php-cs-fixer fix --dry-run — 0 files
  • PHPUnit — 36/36 tests pass
  • Logic check (temp) — 4 cases pass (201910176 → 20252; 201910085 → null; graded-only → null)
  • Playwright live — NIM 201910085 shows 0 "(akan diisi)" (last semester already graded, nothing backfilled); NIM 201910176 tags only 20252

Notes

  • docs/ARCHITECTURE.md / docs/STRUCTURE.md left unstaged (out of scope).
  • Syntax/CS/unit verified locally; the live submission path (TypeError + time limit) is confirmed by the reporter's own Neo Feeder push attempt after these fixes.

Targets the thesis/skripsi row in the last semester, only while that row is still ungraded (no backfill when the last-semester thesis already has a grade). Also fixes Graduation::finish() declared ': string' while returning a RedirectResponse (TypeError on submit) and lifts the 60s PHP time limit for the long synchronous batch submission.
@ffooll-bit
ffooll-bit merged commit ada73e1 into main Aug 31, 2026
1 check passed
@ffooll-bit
ffooll-bit deleted the hotfix/thesis-grade-last-semester branch August 31, 2026 05:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant