-
Notifications
You must be signed in to change notification settings - Fork 12.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Plugins: Fix manifest validation #24573
Conversation
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
2c36bd6
to
88baa85
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Great that you added test manifest files. 👍
return PluginSignatureModified | ||
} | ||
sum := string(h.Sum(nil)) | ||
sum := hex.EncodeToString(h.Sum(nil)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How did this work before? :/
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bergquist I think it was simply broken? When I updated a test's plugin to have a signed manifest (hadn't done it before since making a manifest was difficult), it got so far as to hit this bug.
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
(cherry picked from commit 892f9f7)
* TablePanel: Fix JSON tooltip positioning (#24420) * Fix block element and overflow * Width not needed * Add to styles file (cherry picked from commit f714357) * Minor UI touches (#24371) * Justify to alignment in stat * No stats label in inspect * Use sentence case in panel names * typos * typo * Typo * Query -> query options * prettier * Transformer -> transform data * Do not show deprecated plugins in the viz picker * Update viz picker layout (cherry picked from commit 63d2594) * Reporting: tzdata is needed for reporting (#24422) (cherry picked from commit de8c1b9) * Storybook: Position panel to right (#24429) (cherry picked from commit 8257633) * Chore: move dataFramesReceived event to @grafana/data (#24443) (cherry picked from commit 7e6ac12) * Explore: Revert QueryRows refactor (#24444) While query fields should not rely on getting unmounted when the data source changes (and instead react to that change in e.g. componentDidUpdate()), query fields other than PromQueryField still rely on this. (cherry picked from commit 221042c) * Logs: Clicking "Load more" from context overlay doesn't expand log row (#24299) Closes #24184 (cherry picked from commit 35c097e) * Datasource/CloudWatch: Add data links to CloudWatch logs for deep linking to AWS (#24334) * Datasource/CloudWatch: Fix encoding of CloudWatch Logs deep link URL * Adds data links to cloudwatch logs responses for deep linking to aws console * Implements PR feedback (cherry picked from commit a655aa1) * OldTable: Make old table options align & look better (#24485) (cherry picked from commit e333d61) * Buttons: Use text color (#24439) (cherry picked from commit c671fdb) * StatPanels: Hide calc option if all values is selected (#24416) (cherry picked from commit 352f220) * grafana/toolkit: Support paging in cherrypick task (#24402) * Support paging in cherrypick task * Update packages/grafana-toolkit/src/cli/tasks/cherrypick.ts Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com> * Update packages/grafana-toolkit/src/cli/tasks/cherrypick.ts Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com> * Do not cherry pick closed PRs Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com> (cherry picked from commit c5fc18a) * Reduce Transform: sort order is preserved as entered by user (#24494) (cherry picked from commit e341d4b) * TimeZone: added e2e tests for the custom time zone support. (#24442) (cherry picked from commit a521a39) * CloudWatch/Logs: Add error message when log groups are not selected (#24361) * Add error message * Fix empty check (cherry picked from commit d385045) * CloudWatch/Log: Fix field autocomplete suggestions inside function (#24406) * Fix autocomplete inside function * Remove debug log * Add comment and return type (cherry picked from commit b16202a) * Editor: No default suggestion selected (#24479) * QueryField: No default suggestion selected It's been a long-standing issue that careless typing lead to unwanted tab completion insertions. With this change the completion item list no longer selects the first item by default. The user has to actively click ArrowDown to select the first one. * Added type export * Remove width limit of typeahead list (cherry picked from commit 34f6193) * TablePanel: Fixed persisting column resize time series fields (#24505) (cherry picked from commit f13a15a) * PluginsList: Remove unused panel options (#24501) * Remove unused panel options * satisfy ts (cherry picked from commit 2e69b86) * CloudWatch/Logs: Language provider refactor and test (#24425) (cherry picked from commit 876011d) * Datasource/CloudWatch: Usability improvements (#24447) * Datasource/CloudWatch: Improve handling of long-running queries * Datasource/CloudWatch: Make order of dataframe fields consistent (cherry picked from commit c26374b) * CloudWatch/Logs: Fix suggestions of fields after comma (#24520) (cherry picked from commit 2d29997) * GraphLegend: Only display scrollbar if necessary (#24527) (cherry picked from commit cb74bc6) * CloudWatch/Logs: Fix fields not being refetched when log group changed (#24529) (cherry picked from commit 55533d1) * Datasource/CloudWatch: Switch to metrics mode, logs API, when choosing stats query from cheatsheet (#24398) * Datasource/CloudWatch: Switch to metrics mode, logs API, when choosing stats query from cheatsheet (cherry picked from commit ae7f0ae) * azuremonitor: Deep linking from Log Analytic queries to the Azure Portal (#24417) * azuremonitor: add gzipped and base64 encoded query to metadata for Azure Log Analytic query responses * azure monitor: add fields to metadata for log analytics * azuremonitor: correction to text in query editor * azuremonitor: adds subscription id to result metadata * azuremonitor: build deep link url for Log Analytics Most of the information needed for building the url comes from the backend. The workspace friendly name and the resource group that the workspace belongs to are fetched in a separate API call. This call is cached otherwise there would be a workspaces call per query on the dashboard. * docs: azure log analytics deep linking * Apply suggestions from code review Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com> * docs: fixing review comments for azure monitor Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com> (cherry picked from commit 67ed579) * Datasource/CloudWatch: Results of CloudWatch Logs stats queries are now grouped (#24396) * Datasource/CloudWatch: Results of CloudWatch Logs stats queries are now grouped (cherry picked from commit db91961) * PanelEditor: Fixed issue changing a panel from transparent back to normal (#24483) * PanelModel: Fixed issues with persisting some changes * Fixed other issues (cherry picked from commit 5caf7f5) * LabelsToFields: avoid MutableDataFrame (#24493) (cherry picked from commit c8d3d15) * Prometheus: Show results of instant queries only in table (#24508) * Show results of instant queries only in table, remove them from graph * Update table model (cherry picked from commit 143a267) * PanelEditor: Fix so defaults is selected when datasource can't be found. (#24526) (cherry picked from commit cb4266b) * Graphite: makes query annotations work again (#24556) (cherry picked from commit 7992f8b) * azuremonitor: limit macro regex to known macros (#24528) (cherry picked from commit 64046e9) * TimePicker: fixed so you can enter a relative range in the time picker without being converted to absolute range (#24534) * fixed so you can enter a relative date in the time range form. * did some small adjustments to make sure proper value is stored. (cherry picked from commit 28f54bc) * Admin Settings: makes long settings line break (#24559) (cherry picked from commit 74ddfe0) * Update light variable theme for dropdown (#24566) (cherry picked from commit 67dab0b) * UI spelling: use US form of visualization (#24558) (cherry picked from commit bffa0fa) * e2e: adds verify release (#24568) (cherry picked from commit 7d800e7) * Search: Save folder expanded state (#24496) * Search: Save folder expanded state * Search: Remember expanded state on search close (cherry picked from commit 0396b22) * Data sources: Don't fail if URL doesn't specify protocol (#24497) (cherry picked from commit 164242f) * Security: Tag value sanitization fix in OpenTSDB data source (#24539) Adds HTML sanitization to the tag value of the OpenTSDB datasource. Fixes #24537 (cherry picked from commit 125ba95) * Field: UI & Code consistency Title -> Display name (#24507) * Field: Change getFieldTitle to getFieldDisplayNamne and change the NAME of the title field config from Title to Display name * Review feedback * fixed unit tests * Rename fieldConfig.title to displayName * Fixed tests * Added migration * Renamed getFrameDisplayTitle to getFrameDisplayName (cherry picked from commit 8de10a8) * Do not set insertText if the same as label (#24581) (cherry picked from commit 20f0ee2) * Plugins: Fix manifest verification (#24573) (cherry picked from commit 892f9f7) * Search: Safari UI fixes (#24567) * Search: Add height: 100% to page containers * Search: Reset TagOption display to block * Search: Add title to result list * Search: Use flex-basis vs height * Search: Remove IconButton * Search: Do not shrink select options * Search: Fix hasEditPermissionInFolders * Search: Update tests * Search: Fix prop * Remove select wrapper class * Update snapshot (cherry picked from commit 15ac76a) * OrgUsersTable: Fix width when there are long cells in table (#24533) * Set width for cells and text overflow * Add title and update snapshot (cherry picked from commit 0c1f1dd) * Loki: Allow multiple derived fields with the same name (#24437) (cherry picked from commit a50cb6a) * Datasource/CloudWatch: Fixes various autocomplete issues (#24583) (cherry picked from commit c191994) * CircleCI: Update grabpl to 0.4.5 in order to include manifest with GEL (#24577) * CircleCI: Update grabpl to 0.4.5 * GEL: Upgrade version (cherry picked from commit 824eb94) * CloudWatch/Logs: Make stats hint show consistently (#24392) (cherry picked from commit 5feef22) * Table: fixes Cannot read property subRows of null (#24578) (cherry picked from commit 2d19c04) * TimePicker: some fixes and polish after testing feedback (#24585) * make sure we render the delaynow value from dashboard to the time picker settings. * Added the time zone in the tooltip. (cherry picked from commit cab066f) * Onboarding: New getting started panel (#23826) * image and card component * change height of getting started panel * progress * setup basic step * advanced steps * step forward and backward * do checks * fix button size * minor styling on butttons * add correct links * save tutorial click in localstorage * types and gradients * fix gradients * use spacing variable * lots of responsiveness * add links to help * Getting started work * redo according to split panel design * minor touch ups * new background images * split up docs card to different hrefs * welcome bar touch ups * hide icon on small screens * transparent false on welcome banner * fix urls * source tag in welcome urls * move images to panel dir, removed unused images * Nicer loading message * make the cards look nicer on wide screens * append utm tag on render instead * replace width with margin * new background image for light * remove target on a element * removing buttonselect, add tag to href * more polishing Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com> Co-authored-by: Torkel Ödegaard <torkel@grafana.com> (cherry picked from commit 36fa54a) * Chore: Fix strict null errors on getting started (#24605) * fix strict nulls * fix typings (cherry picked from commit 1848900) * CircleCI: Upgrade grabpl in order to fix package publishing (#24609) Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com> (cherry picked from commit 03940c8) * Fix Safari Icon alignment (#24610) (cherry picked from commit 04c7526) * Transformations: Make transform dropdowns not cropped (#24615) (cherry picked from commit 9e24c09) * Inspect: Allow showing data without transformations and field config is applied (#24314) * Inspect: Should not subscribe to transformed data * PQR- allow controll whether or not field overrides and transformations should be applied * UI for inspector data options * fix * Null check fix * Update public/app/features/dashboard/components/Inspector/InspectDataTab.tsx * Update public/app/features/dashboard/components/Inspector/InspectDataTab.tsx * Apply transformations by default * Update panel inspect docs * Fix apply overrides * Apply time formatting in panel inspect * fix ts * Post review update * Update docs/sources/panels/inspect-panel.md Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com> * lazy numbering * fix ts * Renames * Renames 2 * Layout update * Run shared request without field config * Minor details * fix ts Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com> Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com> (cherry picked from commit f23ecc4) * Transformers: fix binary operation (#24604) * check the display name * remove unchanged line Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com> (cherry picked from commit 97e2837) * SharedPreferences: fixes so UI Theme can be set back to Default (#24628) (cherry picked from commit cd9cbe5) * Datasource/CloudWatch: Prevents hidden dataframe fields from displaying in tables (#24580) * Datasource/CloudWatch: Prevents hidden dataframe fields from displaying in tables (cherry picked from commit 277aee8) * Datasource/CloudWatch: Correctly interpolate variables in CloudWatch Logs queries (#24619) Closes #24603 (cherry picked from commit bfd337d) * Explore: Fix rendering of react query editors (#24593) * Fix rendering of react query editors * Refactor solution for improved readability * Update * Add test coverage * Refactor (cherry picked from commit 285ea75) * CloudWatch: Don't assume that errors are awserr.Error instances (#24641) Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com> (cherry picked from commit 8e5a3a5) * Zipkin: Fix error when span contains remoteEndpoint (#24524) (cherry picked from commit 0f964c0) * Templating: fixes so Textbox variables get value from url (#24623) (cherry picked from commit 622246d) * Templating: fixes filtering options with more than 1000 entries (#24614) * Templating: fixes filtering options with more then 1000 entries * Chore: reduces strict null errors by 2 (cherry picked from commit 083a2ce) * PanelEdit: Make sure side pane is displayed with tabs by default (#24636) * Make sure side pane is displayed with tabs by default * Update e2e tests for (cherry picked from commit f769ed0) * @grafana/ui: Update RadioButtonGroup documentation (#23143) * Add "When to use" info to RadioButtonGroup.mdx * Clarify more clearly when to use 'Select' instead * Update RadioButtonGroup.mdx Add line explaining why we want select for more than four options instead of a radio button group * Update RadioButtonGroup.mdx remove part about when elements are triggering changes. Co-authored-by: Tobias Skarhed <tobias.skarhed@gmail.com> (cherry picked from commit f1386c7) * Search: Fix select item pressing enter 404 (#24634) * Remove appSubUrl for navigation * stripBaseFromUrl * Remove unused imports (cherry picked from commit 37a2ac2) * @grafana/ui: Buttons documentation (#23144) * Add info: when to use which and how to mix buttons * Update description for Button.mdx - add note about scenario without primary action - add note about secondary button being the default * Refine docs info for secondary and destructive Co-authored-by: Tobias Skarhed <tobias.skarhed@gmail.com> (cherry picked from commit 54a9016) * Datasource Config: adds back correct styles for autofill fields (#24671) (cherry picked from commit 9481b7b) * Changelog and Readme: Update packages to beta and add Select breaking change (#24670) (cherry picked from commit 85ae144) * Orgs: Add future deprecation notice (#24502) * Orgs: Fist draft of orgs deprecation infobox * adds warning about potentially deprecating orgs (#24512) * Updates * Fixed ts issue Co-authored-by: Carl Bergquist <carl@grafana.com> (cherry picked from commit 2f22781) * Provisioning: Use proxy as default access mode in provisioning (#24669) fixes #24591 fixes #19501 (cherry picked from commit 7610d57) * Fallback to process.cwd() when PWD is not present (#24677) Fixes #24582 - Error running yarn dev command (cherry picked from commit 660f2b4) * SaveDashboard: Allow editing provisioned dashboard JSON and add confirmation when JSON is copied to dashboard (#24680) (cherry picked from commit cfac591) * Units: adds scale symbol for currencies with suffixed symbol (#24678) (cherry picked from commit 51509bb) * CloudWatch/Logs: Fix panic on multiple aggregations queries (#24683) (cherry picked from commit c60765a) Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com> * Docs: Updated instructions on screens for Dashboard Import (#24584) * change text and image links * Review feedback Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com> * uppercase JSON Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com> Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com> Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com> (cherry picked from commit abfa1b5) * CloudWatch: Unify look of query mode select between dashboard and explore (#24648) (cherry picked from commit e754bcd) * Datasources: fixes async mount errors (#24579) * Chore: updates Elasticsearch DataLinks test async wrapper mount * Chore: updates Loki DervidedFields test async wrapper mount * Chore: fixes typecheck issues * Chore: small strict-null fix (cherry picked from commit e11504d) * Editor: New line on Enter, run query on Shift+Enter (#24654) * Editor: New line on Enter, run query on Shift+Enter - default Enter behavior on query editor fields should be a new line - special behavior should require a special key: running a query is now done on Shift-Enter - Plugins order had to be changed because when typeahead is shown, Enter is accepting the suggestion * Run with ctrl-enter, hint in query placeholder * Fix Kusto field behavior for Enter * Fix Kusto field behavior for default suggestion (cherry picked from commit 01bbcf4) * Add deprecation note about the unofficial first version of backend plugins (#24675) (cherry picked from commit 0c8ee5b) * CloudWatch/Logs: Fix autocomplete after by keyword (#24644) (cherry picked from commit 2b9cc8b) * TablePanel: Do not include angular options in options when switching from angular panel (#24684) (cherry picked from commit c59f543) * Datasources: fix pre styles (#24687) (cherry picked from commit 7fbed90) * @grafana/ui: Checkbox docs (#23141) * Add "When to use" info to Checkbox.mdx Added info about how checkboxes generally work and when to use another component instead. * Replaced words with proper component names * Update Checkbox.mdx Elaborate on explanations. Add examples for how to use checkboxes the user-friendliest way. * Apply suggestions from code review Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com> Co-authored-by: Tobias Skarhed <tobias.skarhed@gmail.com> Co-authored-by: Tobias Skarhed <1438972+tskarhed@users.noreply.github.com> Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com> (cherry picked from commit 405145f) * Logs: Fix total bytes process calculation (#24691) - log stats for Loki are per query - this change tracks the query stats by refId, preventing the summing of the same stats across multiple series of the same response. (cherry picked from commit 25e1238) * Strict null fixes: updates return type of getMessageFromError, fixes QueryOperationAction props (#24690) * Chore: updates getMessageFromError return type * Chore: updates the position of incorrectly placed bang operator * Chore: updates typing on dropdown typeahead directive * Chore: updates QueryOperationAction props to require title * Revert "Chore: updates QueryOperationAction props to require title" (cherry picked from commit ee12f5e) * Docs: Panel inspector release highlights (#24686) * Add Panel inspector highlight * Update CHANGELOG.md * Update CHANGELOG.md Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com> Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com> (cherry picked from commit e4cbeb5) * Explore: fixes loading more logs in logs context view (#24135) (cherry picked from commit d3a8f6d) * Datasource/CloudWatch: Handle invalidation of log groups when switching datasources (#24703) (cherry picked from commit 1b29d34) * PanelInspect: Make header names reflect the field name in the exported CSV file (#24624) * fix header names and filename * use panel title as filename * add frame argument * escaping double quotes * wrapping header name in quotes * Fix replace * Add test for csv double quotes escaping Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com> (cherry picked from commit bf1e5aa) * CloudWatch/Logs: Fix query error when results are sparse (#24702) (cherry picked from commit bc8c051) * Datasource/CloudWatch: Allows a user to search for log groups that aren't there initially (#24695) Closes #24554 (cherry picked from commit 0e8638e) * Transform: fixes so we match the field based on the proper name. (#24659) * fixes so we match the transformer based on name properly. * changed the signature on the FieldMatcher. * introduced a names option so you can filter in name specificly. * changed so the matcher UI uses the new options format. * moved the exported functions together. * changing editors a bit. * made the filter by name work with both regex and name filtering. * fixed failing tests and make sure we always parse regex the same way. * removed unused code. * simplified to make the existing field overrides still working. * fixed issue reported by hugo. * added tests for the name matcher. * added tests for filter by name. * added more tests. (cherry picked from commit 96f26cb) * Fix: changing so we are using date/time values in UTC during test. (#24707) (cherry picked from commit 98d5633) * Docs: generated a 7.0 version of the packages reference docs. (#24708) * fixes so we match the transformer based on name properly. * changed the signature on the FieldMatcher. * introduced a names option so you can filter in name specificly. * changed so the matcher UI uses the new options format. * moved the exported functions together. * changing editors a bit. * made the filter by name work with both regex and name filtering. * fixed failing tests and make sure we always parse regex the same way. * removed unused code. * simplified to make the existing field overrides still working. * fixed issue reported by hugo. * added tests for the name matcher. * added tests for filter by name. * added more tests. * generated new version of the packages docs. * fixed spelling error. * regenerated the docs. (cherry picked from commit 6a0abf8) * Query: do not require datasource name and id (#24718) (cherry picked from commit b73d237) * Metrictank: Fixed updated schema and dedupe strategy (#24685) * Metrictank: Fixed updated schema and dedupe strategy * revert schema change * fix (cherry picked from commit 7fcf261) * Release 7.0.0 Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com> * CircleCI: Upgrade build pipeline tool Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com> Co-authored-by: Tobias Skarhed <1438972+tskarhed@users.noreply.github.com> Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com> Co-authored-by: Leonard Gram <leo@xlson.com> Co-authored-by: Alexander Zobnin <alexanderzobnin@gmail.com> Co-authored-by: Andreas Opferkuch <andreas.opferkuch@gmail.com> Co-authored-by: kay delaney <45561153+kaydelaney@users.noreply.github.com> Co-authored-by: Torkel Ödegaard <torkel@grafana.com> Co-authored-by: Peter Holmberg <peterholmberg@users.noreply.github.com> Co-authored-by: Hugo Häggmark <hugo.haggmark@grafana.com> Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com> Co-authored-by: Andrej Ocenas <mr.ocenas@gmail.com> Co-authored-by: David <david.kaltschmidt@gmail.com> Co-authored-by: Daniel Lee <dan.limerick@gmail.com> Co-authored-by: Ryan McKinley <ryantxu@gmail.com> Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com> Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com> Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com> Co-authored-by: Rotem Reiss <reiss.r@gmail.com> Co-authored-by: Agnès Toulet <35176601+AgnesToulet@users.noreply.github.com> Co-authored-by: Jess <53754871+jessover9000@users.noreply.github.com> Co-authored-by: Carl Bergquist <carl@grafana.com> Co-authored-by: Lukas Siatka <lukasz.siatka@grafana.com> Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
What this PR does / why we need it:
This PR fixes validation of the checksums in plugin manifests. I realized on working with plugin manifest that the original logic was comparing string representations of checksum bytes to hex encodings, which doesn't quite work.
I fixed an existing test to catch this issue, and added a test for the case where a plugin is missing files listed in the manifest.