Skip to content

chore: dsconfig base schema - github#771

Open
yesoreyeram wants to merge 5 commits into
mainfrom
dsconfig/schema-base
Open

chore: dsconfig base schema - github#771
yesoreyeram wants to merge 5 commits into
mainfrom
dsconfig/schema-base

Conversation

@yesoreyeram

@yesoreyeram yesoreyeram commented Jun 19, 2026

Copy link
Copy Markdown
Contributor
  • added dsconfig schema
  • fixed the stargazers test to consistently return timestamp
  • fixed migrated from backend.NewGrafanaCfg to config.NewGrafanaCfg ( changes in plugin SDK ). Old property deprecated and so the plugin is failing with lint
  • refactored the parsing logic for app id and installation id ( to support both number and string formats. String is the desired format and consistent with the frontend. But sometimes yaml provisioning and legacy stuff returns them as number )
  • Added githubPlan in backend settings model for feature parity with frontend.

Copilot AI review requested due to automatic review settings June 19, 2026 10:06
@yesoreyeram yesoreyeram requested a review from a team as a code owner June 19, 2026 10:06
@yesoreyeram yesoreyeram requested a review from jcolladokuri June 19, 2026 10:06

Copilot AI left a comment

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.

Pull request overview

Adds a dsconfig-backed base schema for the GitHub datasource plugin, commits the generated schema artifacts, and ensures those artifacts ship with the built plugin bundle. It also adjusts backend settings parsing to tolerate legacy appId/installationId representations and updates dependencies/build wiring accordingly.

Changes:

  • Introduce dsconfig schema source (pkg/schema/dsconfig.json), Go helpers/tests, and generated schema artifacts (pkg/schema/*.gen.json).
  • Package schema artifacts (and skills) into dist/ via a new root webpack.config.ts and updated package.json build/dev scripts.
  • Normalize legacy appId / installationId parsing in pkg/models/settings.go and update tests; minor test determinism fix and SDK config API update.

Reviewed changes

Copilot reviewed 15 out of 16 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
webpack.config.ts Extends scaffolded webpack config to copy schema artifacts (and skills) into the built bundle.
pkg/schema/dsconfig.json Adds dsconfig “single source of truth” schema for plugin settings.
pkg/schema/schema.go Embeds dsconfig schema and produces SDK plugin schema object.
pkg/schema/schema_test.go Adds artifact generation via go generate and runs dsconfig conformance tests.
pkg/schema/schema.gen.json Committed generated plugin schema (v0alpha1).
pkg/schema/settings.gen.json Committed generated settings schema (v0alpha1).
pkg/schema/settings.examples.gen.json Committed generated settings examples artifact.
pkg/models/settings.go Adds legacy-tolerant JSON unmarshal for appId/installationId and adds githubPlan for frontend parity.
pkg/models/settings_test.go Updates expectations for the new normalized appId/installationId representation.
pkg/github/stargazers_test.go Makes time zone formatting deterministic for golden output.
pkg/github/sql_handler_test.go Switches to config.NewGrafanaCfg per updated plugin SDK API.
package.json Bumps version and switches build/dev scripts to use the new root webpack config.
go.mod Updates Go/tooling and dependency versions; adds dsconfig modules.
go.sum Updates module checksums to match go.mod changes.
cspell.config.json Adds dsconfig-related words and formats ignore list.
CHANGELOG.md Documents 2.8.2 changes and adjusts prior formatting.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread pkg/schema/schema.go
Comment thread pkg/schema/schema_test.go Outdated
Comment thread pkg/models/settings.go Outdated
yesoreyeram and others added 3 commits June 19, 2026 11:11
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@yesoreyeram yesoreyeram changed the title dsconfig: base schema chore: dsconfig base schema - github Jun 19, 2026
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.

3 participants