Add verified column and badge for dashAI plugins#692
Open
Irozuku wants to merge 4 commits into
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Plugins published by the official dashAI PyPI account (
dashai.nocode) now show a Verified badge in the plugins UI. PyPI exposes no uploader account field through its API, so verification is derived from package author metadata: a plugin is verified when itsauthor_emailcontainsdashaisoftware@gmail.comor itsauthorisDashAI team. This lets users distinguish official plugins from third partydashai-*packages.Type of Change
Check all that apply like this [x]:
Changes (by file)
DashAI/back/dependencies/database/models.py: addverifiedboolean column to thePluginmodel (server_default "0").DashAI/alembic/versions/e2a9c4f1b8d3_add_verified_column_to_plugin.py: migration adding theverifiedcolumn (revises3db684f4090a).DashAI/back/plugins/utils.py: add_is_verified_author()helper and computeverifiedfrom author metadata inget_plugin_by_name_from_pypi.DashAI/back/api/api_v1/schemas/plugin_params.py: addverified: bool = FalsetoPluginParams.DashAI/back/dependencies/database/utils.py: persistverifiedon plugin create, update, and upgrade.DashAI/front/src/types/plugin.ts: addverified: booleantoIPlugin.DashAI/front/src/pages/plugins/components/PluginsCard.jsx: render a verified badge (tooltip) in grid and list views.DashAI/front/src/pages/plugins/components/PluginsDetails.jsx: render a verified badge beside the title.DashAI/front/src/utils/i18n/locales/{en,es,pt,de,zh}/plugins.json: addlabel.verifiedstring.tests/back/plugins/test_plugin_utils.py: parametrized test for_is_verified_author+ updated output assertions.Testing
POST /api/v1/plugins/indexto refresh from PyPI, then confirm official dashAI plugins show the badge.Notes
verifiedis recomputed only on the plugins index refresh (POST /plugins/index). Existing DB rows default tofalseuntil refreshed.DashAI/back/plugins/utils.py(_VERIFIED_AUTHOR_EMAIL,_VERIFIED_AUTHOR_NAME).