Skip to content

[CourseRegistry] Require explicit completion integration configuration #93

Description

@Kaylahray

Description

Final course completion currently tolerates missing integration addresses by skipping badge minting or reward payout. This issue makes completion behavior explicit so production deployments cannot silently miss side effects.

User Story

As the Learnault Protocol,
I want to fail or explicitly configure completion side effects,
so that course completion never silently skips reward or badge issuance in production.

Requirements and Context

  • Files: contracts/course-registry/src/lib.rs, contracts/course-registry/src/test.rs
  • Define whether final completion requires RewardPoolAddress, BadgeNftAddress, or both
  • If the selected integration is mandatory, revert when final completion is attempted without the configured address
  • If optional behavior must remain supported, add an explicit mode flag rather than silently skipping work

Suggested Implementation

// 1. Add explicit completion integration configuration or policy flag.
// 2. On final module completion, enforce the chosen policy before side effects run.
// 3. Only allow silent skipping if the policy explicitly enables it.

Acceptance Criteria

  • Final completion behavior is deterministic and documented when integration addresses are missing.
  • Production-mode tests fail if required completion integrations are unset.
  • The contract no longer silently drops badge minting or payout side effects without policy support.

Submission Guidelines

  • Branch: feat/explicit-completion-integrations
  • Depends on: [CourseRegistry] Trigger payout on course completion, [CourseRegistry] Trigger badge minting on completion
  • PR: feat(course-registry): require explicit completion integration configuration

Activity

  1. Martins-594 commented on Jul 21, 2026

    @Martins-594

    Hi, I'd like to work on this issue. I've gone through the description and acceptance criteria and I'm confident I can deliver it. I'll make sure every acceptance criterion is met and submit a clean, tested PR. Please assign it to me.

  2. syed-ghufran-hassan commented on Aug 1, 2026

    @syed-ghufran-hassan
    Contributor

    I have added explicit completion policies (Optional/RewardRequired/BadgeRequired/BothRequired) to CourseRegistry, ensuring badge minting and reward payouts are never silently skipped in production; Optional policy maintains backward compatibility while required policies enforce integration configuration before course completion.

  3. grantfox-oss commented on Aug 19, 2026

    @grantfox-oss

    🦊 GrantFox — @syed-ghufran-hassan has been assigned to this issue as part of the Third Campaign campaign!

    Next steps:

    1. Open a Pull Request referencing this issue (e.g., Closes #93)
    2. Your PR will be reviewed by the learnault maintainers

    Good luck! Track your progress on GrantFox.

  4. syed-ghufran-hassan commented on Aug 19, 2026

    @syed-ghufran-hassan
    Contributor

    @Kaylahray can you please review as I have already raised PR #109

  5. 3m1n3nc3 commented on Aug 29, 2026

    @3m1n3nc3
    Member

    @Kaylahray can you please review as I have already raised PR #109

    Hi @syed-ghufran-hassan can you resolve the current conflict so we can close the issue? I have added it to the current campaign so it can be eligible for payment.

  6. syed-ghufran-hassan commented on Aug 29, 2026

    @syed-ghufran-hassan
    Contributor

    @3m1n3nc3 I have updated the PR please check #109

  7. grantfox-oss commented on Aug 29, 2026

    @grantfox-oss

    🎉 This issue has been marked as completed on GrantFox as part of the Third Campaign campaign!

    @syed-ghufran-hassan's PR #109 was approved and merged by @3m1n3nc3.

    🏆 @syed-ghufran-hassan: You earned 40 FoxPoints for this contribution! Your current tier: Builder (1,783 total points). Track your full progress on GrantFox.

    👏 Great work, @syed-ghufran-hassan! Keep contributing to learnault.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions