Uploaded image for project: 'Compass '
  1. Compass
  2. COMPASS-6050

eslint: enforce rules for TODO comments

    XMLWordPrintableJSON

Details

    • Icon: Task Task
    • Resolution: Won't Do
    • Icon: Major - P3 Major - P3
    • No version
    • None
    • Tech debt
    • None
    • Not Needed

    Description

      (This came out of Technical Alignment Sync)

      At the time of writing we have 354 TODO comments across 179 files. Ideally we'd cut down on those.

      To at least stop the proliferation of TODO comments that never get done we can have rules for new comments. Using something like https://github.com/sindresorhus/eslint-plugin-unicorn/blob/main/docs/rules/expiring-todo-comments.md  we can enforce that each TODO comment has a ticket number.

      People seem to have concerns about expiring TODO comments blocking a release, so see if we can disallow expiring comments and enforce a ticket number.

      When opening the Jira ticket we should also link back to the line of code that contains the TODO comment to help track it.

       

      As part of the PR we'd probably have to ignore all the old comments somehow, so we can maybe find/replace them to TODO-OLD or something else that we can ignore. And then we can separately run through them and either remove or fix them up.

      Attachments

        Activity

          People

            Unassigned Unassigned
            leroux.bodenstein@mongodb.com Le Roux Bodenstein
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: