chore: 修复图表示例基础图表打不开的问题 (#7282) #6078
Annotations
10 errors and 11 warnings
|
__tests__/integration/spec-static.spec.ts > Charts > [Canvas]: haleChoroplethWorld:
__tests__/integration/spec-static.spec.ts#L25
Error: mismatch /Users/runner/work/G2/G2/__tests__/integration/snapshots/static/haleChoroplethWorld
Difference 1 at line 1108:
Expected✅: <path fill="none" stroke="rgba(255,255,255,1)" d="m345.682 223.643-.261-.354-.142-.146-.11-.054-.325-.058-.757-.081-.078.019-.318.07-.397.088-.336.085-.361.093-.31-.37-.357-.416-.366-.471-.277-.366-.134-.213-.244-.278-.18-.135-.068-.069-.149-.746-.075-.685.019-.514.027-.717.026-.717.026-.718.025-.714.025-.719.024-.719.023-.72.023-.721.011-.35.385 0 .432 0 .457 0 .498 0 .492 0 .499 0 .348 0 .09-.004.109-.023.009-.071-.133-.354.017-.125.044-.242.067-.206.087-.274.011-.159-.044-.523.016-.293.027-.305.027-.289-.018-.199.027-.11.053-.156.03-.176.032-.078-.004-.07-.026-.129-.015-.297-.025-.411-.028-.294.06.016.126.028.056.144.032.161.084.007.22.094.075.133.039.282-.034.145-.076.117.069.101.149.071.085-.024.259-.191.097-.035.134-.036.122-.05.334-.086.182-.039.104-.071.072 0 .053.055-.054.199-.024.18.056.336.043.157.104.113.077.058.08.122.181-.024.386.172.118.078.166.082.113.027.407.059.149.043.275.055.222.007.164-.023.11-.051.068-.054.031-.043.054-.168.097-.364.034-.105.086-.051.109-.035.059.059.058.402.294.363.097.305.069.257.064.074.111.086.191.035.168.008.342.188.277.148.2.105.087.082.061.133.032.105.05.265.057.211.107.042.095.016.09.144.068.125.131.312.093.21.027.21.115.137.159.058.15.008.087-.063.22-.105.174-.124.121-.043.071.027.051.086.022.167.002.094.117.085.085-.035.041-.101.002-.051.019-.455.017-.394.016-.37.018-.452.016-.394.013-.324.014-.339-.079.019-.099.078-.223.008-.087.058-.027.09.007.113 0 .153-.033.074-.097.027-.142-.059-.25-.078-.208-.046-.142-.207-.199-.309-.127-.156-.312-.32-.052-.066-.097-.149-.075-.257-.036-.168-.031-.129-.042-.188.088-.289.134-.552.092-.399.052-.293.173-.301.021-.267-.055-.344.024-.192.021-.482.025-.407.006-.196-.032-.345-.097-.384-.22-.53.003-.114.149-.125.223-.22.113-.13.138-.184.063-.094.134-.24.083-.192.037-.247-.054-.24.123-.047.413-.083.45-.09.481-.098.48-.098.469-.098.419-.087.292-.059.044.165.077.271.104.201.122.172.106.106.071.032.46-.012.16.106.141.137.03.208.093.13.1.102.042.012.073-.024.127-.004.114.047.053.044 0 .176.028.079.156.027.157.016.153.118.163.019.192.051.086.126.195.133.244.114.177.133.095.059.004.063.038.114.046.078.002.122.02.109.071.028.055.008.057-.079.072 0 .077.051.025.13.061.172.092.118.069.113-.032.208-.049.192.126.184.174.18.046.079.002.262.027.09.112.219.055.145-.01.086-.342.435-.104.043-.098.023-.094.09-.051.09.016.051.03.149.063.235.066.164-.069.203-.141.348-.061.031-.023.266.038.094.057.078.016.18-.004.246-.015.195-.106.508.131.437.046.051.204 0 .029.039-.054.125-.09.128-.057.067-.265.148-.38.168-.086.159-.058.23.035.137.045.078-.028.202-.04.211.004.167-.025.148-.051.074-.077.222-.089.226-.07.101-.096.109-.148.09-.002.043.163.105.038.07.01.05-.038.047-.034.066.075.07.087.058.082.148.068.21.02.07.017.031.03.004.055-.031.108-.117.074-.038.081.163-.367.159-.19.082-.546.241-.477.21-.122.039-.251.104-.123.063-.428.182-.178.089-.149.09-.354.136-.335.128-.366.132-.408.147-.233.105-.154.093-.368.182-.02.047 0 .124.035.26.077.236.065.136.03.349.014.306m40.524-91.244.252.571.327.533.261.293.282.399.4.369.177.124.669.26.364.094.493.094.363.2.113.011.16-.056.129.004.358.275.133.26.155.136.15.215.11.227.316.348.252.389.236.288.197.178.268.072.223.079.052.194.014.253-.013.186-.141.364-.014.224-.164.369-.152.619-.086.141-.344.319-.228.389-.245.67-.164.664-.072.213-.201.046-.138-.019-.097-.065.012-.179-.004-.206-.12.023-.107.042-.188.5-.113.217.006.279-.025.359-.052.329-.013.279.02.157.125.387.054.395.071.237.07.284-.108.088-.101.042-.399.031-.404.092-.342.165-.2.165-.236.365-.065.934-.234.396-.175.08-.448.035-.618.108-.215.096-.307.57-.01.181.085.131.039.142-.016.135-.134.363-.152.262-.465.166-.188-.096-.166-.051-.317-.007-.505.065-.165.193-.284.139-.253.212-.51.082-.335.166-.797.397-.204.174-.176.221-.124.27-.063.48.117.437.015.233-.201.154-.193.113-.206.17-.134.043-.102.135-.117.097-.445.245-.498.193-.788.229-.296.248-.268.171-.432.051-.574.236-.314.187-.389.31-.082.097-.055.226-.11.198-.227.322-.174.164-.119.007
|
|
__tests__/integration/spec-static.spec.ts > Charts > [Canvas]: unemploymentChoropleth:
__tests__/integration/spec-static.spec.ts#L25
Error: mismatch /Users/runner/work/G2/G2/__tests__/integration/snapshots/static/unemploymentChoropleth
There are too many differencies, only show 3 of them.
Difference 1 at line 2:
Expected✅: <defs>
Actual❌: <g>
Difference 2 at line 3:
Expected✅: <linearGradient id="c" x1="0" x2="179.92" y1="6" y2="6" gradientUnits="userSpaceOnUse">
Actual❌: <g fill="none">
Difference 3 at line 4:
Expected✅: <stop offset="0" stop-color="rgba(255,255,217,1)"/>
Actual❌: <g fill="none" class="view">
❯ __tests__/integration/spec-static.spec.ts:25:9
|
|
__tests__/integration/spec-static.spec.ts > Charts > [Canvas]: airportsPointChoropleth:
__tests__/integration/spec-static.spec.ts#L25
Error: mismatch /Users/runner/work/G2/G2/__tests__/integration/snapshots/static/airportsPointChoropleth
There are too many differencies, only show 3 of them.
Difference 1 at line 21:
Expected✅: <path fill="rgba(211,211,211,1)" stroke="rgba(255,255,255,1)" d="m14.609 396.209-.449-1.207-.634-.658.055-.178.738.683.484 1.233Zm12.874 3.061.016-.657.395.093-.086.406Zm.616.008-.134-.327.264-.177Zm.65-.158-.323-.332.344.008Zm-5.824-.842-.425-.536.515-.066-.52-.934.16-.122.675.191-.01.325.679.428-.496-.039Zm2.143.225-.471-.292-.891-.227 1.283.116.259-.09.199-.485.286.08-.51.97Zm-11.439-5.56.003-.401.326.31Zm11.988 6.361-.008-.357.425-.144.021-.435.42.182.212-.751.64.093-.441.642.483.066-.052.532-.259-.159-.261.258-.796-.019.129-.391Zm-9.022-4.943-.262-.361.115-.272.518-.006.235.369Zm12.051 4.115-.255-.556.517-.042Zm-18.36-6.656-.164-.428.629-.15.301.105.489-.487.257.173-.554.401-.141.31-.349-.254Zm25.648 8.74-.465-.392-.449.025-.48-.519.449.012 1.435.713.497.029.626.262-.568-.014-.939-.209Zm2.998-.224-.222-.103.234-.396.418-.09.332.402Zm-7.512-1.089-.069-.162.794-.087.285.183.806-.03.972-.351-.3-.306.192-.259.539-.039.309.696-.323.262-.321-.135.133.562-.899-.163-.161.264-.412-.273-.256.143-1.02-.38Zm-29.659-14.443-.012-.2-.635-.41 1.068-.005-.223.711Zm42.463 15.534.046-.467.573-.142-.043.46Zm3.275-.324-.324-.336-.354.097.005-.326.828.054Zm-46.772-17.867-.22-.485.135-.269-.365-.13.158-.245-.435-.237.653-.073.703.564.438.121-.006.425.344.145-.238.422-.383-.053-.21-.331Zm48.601 18.011 1.176-.976.005-.351.65-.413.696.219-.192-.363.158-.383.612-.414.664-.042.569.358-.277.575-1.333.405-.722.752-.861.356Zm8.884-2.376-.207-.433.595-.217-.058.371Zm-4.456 1.374-.368-.441.412-.268.278.117.378-.265.394.263.158-.317.647-.016-.171-.492.466 0-.067-.396.967.068-.8-.284-.328-.422.298-.412.572-.193.598-.019.184.321-.183.576 1.074-.524.173.282-1.282.799.796-.179.055.48-.669.045-.578.692-.334-.202-.681.136Zm7.982-2.492-.456-.191.798-.091Zm-2.341-.253-.436-.128-.121-.396.449-.398.607.473.114.271Zm.939-.18-.185-.792.569-.063-.225.357.342.075Zm8.297.011-.56-.463.144-.182.489.245Zm81.505-9.633-.696-.628.552.072Zm-80.402 7.57-.268-.307.332-.437.23.137Zm83.605-9.186-.516-.281.535-.455.262.411Zm-90.268 10.328-.519-.214-.095-.888.654-.196.561-.939.392-.212.445.204 1.085-.483.988.076.369 1.514.388-.067.093.405-.807-.216-.011.287-.482.155-.568-.22-.784-.041-.74.309-.3.437Zm14.518-.867.206-.476.151.318Zm-6.167-1.154-.356-.565.678.257Zm78.067-7.672-.379-.055.087-.328-.324-.235.11-.257.611.571Zm-72.36 8.328.22-.281-.014-.535.214.364Zm72.89-6.886-.306-.012-1.24-.877-.378-.659-.16-.652.206-.153.804.983.11.335.634.324Zm2.452-2.472-.183-.137.114-.619-.343-.506.826.232.141.601Zm-77.028 10.036.527-1.006.069-.546.416.274-.277.46-.587.501Zm72.207-9.476-.283.042-.148-.524.246-.157.377.284Zm-72.328 7.649-.479-.403.503-.162Zm-1.369.463.05-1.051.333-.306.219.154.411.976-.211.249-.59-.368Zm77.919-9.14-.301-.212-.424-1.017.662.279Zm-4.986 1.1-.214-.192-.018-.636.425.09-.224.257Zm-71.002 6.993-.452-.363.513.02Zm70.943-7.916-.243-.03.128-.427.36.269Zm-.735.181.153-.447.305-.188-.081.511Zm1.156-.42-.359-.299.249-.265Zm-.778-.979-.558-.263.292-.35.659.109Zm-58.269 8.128-.395-.31.526-.368Zm58.84-8.706-.305-.195-.04-.406.292.158Zm-2.679.593-.118-.483.4-.064Zm8.79.255-.4-.222-.368.068.214-.849-.12-.079-.36.933-.967-.445.282-.865-.285-.055-.294-.93.422-.129-.231-.255.749-.631.7.478.645.798.28 1.745Zm-7.473-1.05-.323-.167.232-.848.45-.406.364-.047.195.606-.225-.016Zm3.455-1.187-.489-.586-.515.204-.387-.683.264-.198.004-.466.45-.027.025.491.473-.084.506.279-.192.35.346.336Zm-1.611.027-.004-.012.118-.099.768.285.615.48.115.555.375-.035.316.423.525.253-.968-.177-.356-.212.203.547.356-.185.856.445.315.408-.339.364.445-.054.07-.424.264.469-.122.939.324-.292.256.563.15.919-.753.148-.111-.542-.823-.567.062.338-.534-1.01-.237.214-.821-.373-.797.19-.05-.47.583.006-.199-.454-.349.054-.038-.805-.455.381-.347-.103-.014-.422.349-.67-.36-.238-.448-1.171-.838.123-.329-.411-.02-.375.481.014.589-.238.653.571.129.671Zm-.189-1.03-.644-.295.118-.639.529-.202.396.206.068.563Zm1.793-.352-.
|
|
__tests__/integration/spec-interaction.spec.ts > Interactions > [Interaction]: unemploymentChoropleth:
__tests__/plots/interaction/utils.ts#L42
TypeError: Cannot read properties of undefined (reading 'dispatchEvent')
❯ changeState __tests__/plots/interaction/utils.ts:42:15
❯ __tests__/integration/spec-interaction.spec.ts:66:17
|
|
__tests__/integration/spec-animation.spec.ts > Animations > [Animation]: populationIntervalRoseKeyframe:
__tests__/integration/spec-animation.spec.ts#L97
Error: Test timed out in 100000ms.
If this is a long-running test, pass a timeout value as the last argument or configure it globally with "testTimeout".
❯ __tests__/integration/spec-animation.spec.ts:97:5
|
|
Unhandled error:
src/utils/selection.ts#L77
TypeError: Cannot read properties of null (reading 'ownerDocument')
❯ select src/utils/selection.ts:77:5
❯ selectG2Elements src/interaction/utils.ts:38:8
❯ tooltip src/interaction/tooltip.ts:18438:47
❯ interaction src/interaction/tooltip.ts:18879:12
❯ plot src/runtime/plot.ts:566:5
This error originated in "__tests__/integration/spec-static.spec.ts" test file. It doesn't mean the error was thrown inside the file itself, but while it was running.
The latest test that might've caused the error is "[Canvas]: helixBasic". It might mean one of the following:
- The error was thrown, while Vitest was running this test.
- If the error occurred after the test had been completed, this was the last documented test before it was thrown.
|
|
Unhandled error:
__tests__/plots/static/london-tube-lines-geo.ts#L40
TypeError: Cannot read properties of undefined (reading 'split')
❯ text __tests__/plots/static/london-tube-lines-geo.ts:40:31
❯ src/encode/transform.ts:146:17
❯ columnOf src/runtime/mark.ts:175:18
❯ callbackfn src/runtime/transform.ts:193:37
❯ reduce src/utils/array.ts:22:8
❯ mapObject src/utils/array.ts:17:1
❯ extractColumns src/runtime/transform.ts:193:16
❯ applyMarkTransform src/runtime/mark.ts:1963:38
This error originated in "__tests__/integration/spec-static.spec.ts" test file. It doesn't mean the error was thrown inside the file itself, but while it was running.
The latest test that might've caused the error is "[Canvas]: londonTubeLineGeo". It might mean one of the following:
- The error was thrown, while Vitest was running this test.
- If the error occurred after the test had been completed, this was the last documented test before it was thrown.
|
|
Unhandled error:
src/mark/interval.ts#L25
TypeError: scale.getBandWidth is not a function
❯ bandWidth src/mark/interval.ts:25:11
❯ from src/mark/interval.ts:89:28
❯ calcPoints src/mark/interval.ts:87:8
❯ initializeState src/runtime/plot.ts:1278:1
❯ initializeView src/runtime/plot.ts:805:7
❯ plot src/runtime/plot.ts:302:5
This error originated in "__tests__/integration/spec-tooltip.spec.ts" test file. It doesn't mean the error was thrown inside the file itself, but while it was running.
The latest test that might've caused the error is "[Tooltip]: mockIntervalShared". It might mean one of the following:
- The error was thrown, while Vitest was running this test.
- If the error occurred after the test had been completed, this was the last documented test before it was thrown.
|
|
Unhandled error:
__tests__/plots/tooltip/london-tube-lines-geo.ts#L42
TypeError: Cannot read properties of undefined (reading 'split')
❯ text __tests__/plots/tooltip/london-tube-lines-geo.ts:42:31
❯ src/encode/transform.ts:146:17
❯ columnOf src/runtime/mark.ts:175:18
❯ callbackfn src/runtime/transform.ts:193:37
❯ reduce src/utils/array.ts:22:8
❯ mapObject src/utils/array.ts:17:1
❯ extractColumns src/runtime/transform.ts:193:16
❯ applyMarkTransform src/runtime/mark.ts:1963:38
This error originated in "__tests__/integration/spec-tooltip.spec.ts" test file. It doesn't mean the error was thrown inside the file itself, but while it was running.
The latest test that might've caused the error is "[Tooltip]: londonTubeLineGeo". It might mean one of the following:
- The error was thrown, while Vitest was running this test.
- If the error occurred after the test had been completed, this was the last documented test before it was thrown.
|
|
Unhandled error:
__tests__/integration/spec-animation.spec.ts#L114
Error: mismatch /Users/runner/work/G2/G2/__tests__/integration/snapshots/animation/population-interval-rose-keyframe/interval2-0
There are too many differencies, only show 3 of them.
Difference 1 at line 21:
Expected✅: <path fill="rgba(23,131,255,1)" fill-opacity=".95" stroke="rgba(23,131,255,1)" stroke-width="0" d="M185.738 142.355a41.681 41.681 0 0 1 15.106 3.519l-16.844 38.126Z" class="element"/>
Actual❌: <path fill="rgba(23,131,255,1)" fill-opacity=".95" stroke="rgba(23,131,255,1)" stroke-width="0" d="M1.738-41.645a41.681 41.681 0 0 1 15.106 3.519l-16.844 38.126Z" class="element"/>
Difference 2 at line 24:
Expected✅: <path fill="rgba(23,131,255,1)" fill-opacity=".95" stroke="rgba(23,131,255,1)" stroke-width="0" d="M205.605 140.153a48.88 48.88 0 0 1 14.535 10.935l-36.14 32.912Z" class="element"/>
Actual❌: <path fill="rgba(23,131,255,1)" fill-opacity=".95" stroke="rgba(23,131,255,1)" stroke-width="0" d="M21.605-43.847a48.88 48.88 0 0 1 14.535 10.935l-36.14 32.912Z" class="element"/>
Difference 3 at line 27:
Expected✅: <path fill="rgba(23,131,255,1)" fill-opacity=".95" stroke="rgba(23,131,255,1)" stroke-width="0" d="M228.374 146.861a57.865 57.865 0 0 1 10.506 18.795l-54.88 18.344Z" class="element"/>
Actual❌: <path fill="rgba(23,131,255,1)" fill-opacity=".95" stroke="rgba(23,131,255,1)" stroke-width="0" d="M44.374-37.139a57.865 57.865 0 0 1 10.506 18.795l-54.88 18.344Z" class="element"/>
❯ node_modules/.pnpm/@vitest+expect@3.2.4/node_modules/@vitest/expect/dist/index.js:1739:14
❯ runNextTicks node:internal/process/task_queues:65:5
❯ processTimers node:internal/timers:520:9
❯ asset __tests__/integration/spec-animation.spec.ts:114:11
❯ assetEach __tests__/integration/spec-animation.spec.ts:39:7
This error originated in "__tests__/integration/spec-animation.spec.ts" test file. It doesn't mean the error was thrown inside the file itself, but while it was running.
The latest test that might've caused the error is "[Animation]: populationIntervalRoseKeyframe". It might mean one of the following:
- The error was thrown, while Vitest was running this test.
- If the error occurred after the test had been completed, this was the last documented test before it was thrown.
|
|
build
Node.js 20 actions are deprecated. The following actions are running on Node.js 20 and may not work as expected: actions/checkout@v4, actions/setup-node@v4, actions/upload-artifact@v4. Actions will be forced to run with Node.js 24 by default starting June 2nd, 2026. Please check if updated versions of these actions are available that support Node.js 24. To opt into Node.js 24 now, set the FORCE_JAVASCRIPT_ACTIONS_TO_NODE24=true environment variable on the runner or in your workflow file. Once Node.js 24 becomes the default, you can temporarily opt out by setting ACTIONS_ALLOW_USE_UNSECURE_NODE_VERSION=true. For more information see: https://github.blog/changelog/2025-09-19-deprecation-of-node-20-on-github-actions-runners/
|
|
build:
__tests__/integration/chart-on-brush-filter.spec.ts#L10
`vitest` import should occur before import of `../../src`
|
|
build:
__tests__/integration/chart-on-brush-filter.spec.ts#L9
`node:path` import should occur before import of `../../src`
|
|
build:
__tests__/integration/chart-on-brush-filter.spec.ts#L8
`node:fs` import should occur before import of `../../src`
|
|
build:
__tests__/integration/api-chart-render-event.spec.ts#L9
`../../src` import should occur before import of `./utils/createNodeGCanvas`
|
|
build:
__tests__/integration/api-chart-on-text-click.spec.ts#L5
`../../src` import should occur before import of `./utils/createNodeGCanvas`
|
|
build:
__tests__/integration/api-chart-on-item-element.spec.ts#L9
`../../src` import should occur before import of `./utils/createNodeGCanvas`
|
|
build:
__tests__/integration/api-chart-on-component-click.spec.ts#L5
`../../src` import should occur before import of `./utils/createNodeGCanvas`
|
|
build:
__tests__/integration/api-chart-on-brush-filter.spec.ts#L10
`vitest` import should occur before import of `../../src`
|
|
build:
__tests__/integration/api-chart-on-brush-filter.spec.ts#L9
`node:path` import should occur before import of `../../src`
|
|
build:
__tests__/integration/api-chart-on-brush-filter.spec.ts#L8
`node:fs` import should occur before import of `../../src`
|