Skip to content

add alternatives field checks for the new entries#2157

Merged
Simek merged 2 commits intomainfrom
add-alternatives-checks-for-new-entries
Jan 27, 2026
Merged

add alternatives field checks for the new entries#2157
Simek merged 2 commits intomainfrom
add-alternatives-checks-for-new-entries

Conversation

@Simek
Copy link
Copy Markdown
Member

@Simek Simek commented Jan 27, 2026

📝 Why & how

We should validate the alternatives array entries for newly proposed packages, refs:

Add few checks to validate-new-entries.ts script which ensures the correctness of alternatives array.

✅ Checklist

  • Documented how you found or replicated the issue.
  • Explained how you fixed the issue or built the feature.

@Simek Simek merged commit fcc61f3 into main Jan 27, 2026
3 checks passed
@Simek Simek deleted the add-alternatives-checks-for-new-entries branch January 27, 2026 10:39
Comment on lines +126 to +130
if (!alternativesDataJson[alternative].unmaintained) {
console.error(
`${alternative} is not marked as unmaintained in the directory, so it cannot be defined as an alternative for the package.`
);
return false;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In your comment you explained

the alternatives should be placed in the unmaintained package entry [...] instead of [the new package entry]

but here, you're enforcing the opposite (that the alternatives in a new package entry point to unmaintained packages) 😅 @Simek

Copy link
Copy Markdown
Member Author

@Simek Simek Jan 27, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch, spotted that too and corrected in:

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.

2 participants