Skip to content
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

unstable test TestSortSpillDisk #37058

Closed
hawkingrei opened this issue Aug 11, 2022 · 5 comments · Fixed by #37272
Closed

unstable test TestSortSpillDisk #37058

hawkingrei opened this issue Aug 11, 2022 · 5 comments · Fixed by #37272
Assignees
Labels
component/test severity/major type/bug The issue is confirmed as a bug.

Comments

@hawkingrei
Copy link
Member

Bug Report

Please answer these questions before submitting your issue. Thanks!

1. Minimal reproduce step (Required)

     executor_pkg_test.go:525: 
        	Error Trace:	/home/jenkins/.tidb/tmp/04446c229c5a73c16deb3edddcb4db34/sandbox/processwrapper-sandbox/5182/execroot/__main__/bazel-out/k8-fastbuild/bin/executor/executor_test_/executor_test.runfiles/__main__/executor/executor_pkg_test.go:525
        	Error:      	"[%!s(*chunk.SortedRowContainer=&{0xc004cc2440 {{{0 0} 0 0 0 0} [{0 889} {0 2} {0 530} {0 971} {0 762} {0 234} {0 726} {0 226} {0 10} {0 890} {0 970} {0 813} {0 650} {0 537} {0 457} {0 612} {0 476} {0 1} {0 139} {0 802} {0 777} {0 935} {0 515} {0 701} {0 402} {0 697} {0 494} {0 667} {0 851} {0 471} {0 792} {0 768} {0 543} {0 28} {0 691} {0 306} {0 953} {0 232} {0 1002} {0 529} {0 954} {0 748} {0 963} {0 576} {0 580} {0 121} {0 347} {0 62} {0 926} {0 498} {0 203} {0 414} {0 641} {0 249} {0 352} {0 636} {0 329} {0 460} {0 259} {0 810} {0 365} {0 129} {0 68} {0 519} {0 547} {0 37} {0 566} {0 29} {0 581} {0 895} {0 807} {0 1000} {0 991} {0 1017} {0 784} {0 552} {0 675} {0 770} {0 551} {0 1021} {0 571} {0 270} {0 18} {0 658} {0 158} {0 33} {0 679} {0 643} {0 705} {0 434} {0 148} {0 92} {0 308} {0 839} {0 182} {0 677} {0 598} {0 413} {0 761} {0 572} {0 525} {0 177} {0 645} {0 1003} {0 314} {0 723} {0 657} {0 542} {0 740} {0 279} {0 526} {0 685} {0 805} {0 170} {0 45} {0 837} {0 562} {0 77} {0 71} {0 734} {0 315} {0 900} {0 759} {0 902} {0 42} {0 281} {0 65} {0 287} {0 125} {0 622} {0 653} {0 1023} {0 861} {0 297} {0 114} {0 625} {0 426} {0 140} {0 282} {0 618} {0 793} {0 79} {0 399} {0 268} {0 238} {0 938} {0 619} {0 772} {0 439} {0 127} {0 120} {0 795} {0 303} {0 797} {0 156} {0 714} {0 80} {0 370} {0 817} {0 680} {0 985} {0 992} {0 903} {0 698} {0 188} {0 760} {0 946} {0 796} {0 646} {0 422} {0 161} {0 349} {0 205} {0 5} {0 186} {0 428} {0 754} {0 769} {0 106} {0 731} {0 128} {0 108} {0 517} {0 321} {0 709} {0 534} {0 337} {0 633} {0 897} {0 9} {0 244} {0 257} {0 91} {0 54} {0 199} {0 702} {0 687} {0 666} {0 787} {0 737} {0 260} {0 206} {0 444} {0 266} {0 316} {0 896} {0 427} {0 119} {0 774} {0 113} {0 189} {0 809} {0 699} {0 175} {0 923} {0 322} {0 932} {0 955} {0 208} {0 290} {0 689} {0 38} {0 686} {0 781} {0 395} {0 660} {0 311} {0 507} {0 865} {0 845} {0 908} {0 74} {0 947} {0 326} {0 58} {0 236} {0 475} {0 210} {0 310} {0 359} {0 243} {0 67} {0 539} {0 659} {0 654} {0 21} {0 17} {0 235} {0 564} {0 52} {0 213} {0 263} {0 672} {0 753} {0 278} {0 163} {0 801} {0 972} {0 55} {0 745} {0 12} {0 133} {0 941} {0 78} {0 885} {0 973} {0 1008} {0 629} {0 959} {0 252} {0 878} {0 416} {0 144} {0 980} {0 3} {0 756} {0 704} {0 852} {0 184} {0 76} {0 607} {0 800} {0 869} {0 332} {0 450} {0 371} {0 51} {0 353} {0 883} {0 160} {0 925} {0 808} {0 25} {0 470} {0 536} {0 882} {0 396} {0 642} {0 823} {0 703} {0 178} {0 708} {0 710} {0 333} {0 820} {0 767} {0 558} {0 656} {0 201} {0 227} {0 811} {0 815} {0 318} {0 968} {0 305} {0 673} {0 918} {0 240} {0 647} {0 432} {0 61} {0 605} {0 93} {0 104} {0 940} {0 122} {0 690} {0 56} {0 88} {0 984} {0 228} {0 477} {0 392} {0 722} {0 669} {0 988} {0 999} {0 253} {0 44} {0 644} {0 949} {0 454} {0 492} {0 381} {0 521} {0 97} {0 328} {0 180} {0 688} {0 298} {0 154} {0 482} {0 627} {0 858} {0 342} {0 283} {0 937} {0 173} {0 401} {0 631} {0 105} {0 719} {0 406} {0 603} {0 738} {0 545} {0 978} {0 630} {0 24} {0 741} {0 596} {0 181} {0 390} {0 237} {0 150} {0 83} {0 969} {0 508} {0 443} {0 783} {0 324} {0 429} {0 533} {0 915} {0 375} {0 394} {0 280} {0 138} {0 788} {0 957} {0 323} {0 574} {0 613} {0 901} {0 518} {0 53} {0 484} {0 320} {0 1015} {0 115} {0 380} {0 694} {0 294} {0 348} {0 812} {0 284} {0 778} {0 63} {0 606} {0 499} {0 840} {0 611} {0 447} {0 41} {0 821} {0 496} {0 934} {0 81} {0 190} {0 765} {0 693} {0 943} {0 96} {0 779} {0 977} {0 90} {0 418} {0 489} {0 819} {0 389} {0 595} {0 273} {0 255} {0 168} {0 570} {0 835} {0 755} {0 829} {0 589} {0 600} {0 881} {0 397} {0 388} {0 480} {0 844} {0 455} {0 538} {0 933} {0 634} {0 610} {0 487} {0 931} {0 14} {0 435} {0 1013} {0 532} {0 209} {0 254} {0 939} {0 960} {0 187} {0 724} {0 300} {0 8} {0 214} {0 728} {0 727} {0 822} {0 904} {0 368} {0 587} {0 930} {0 440} {0 886} {0 695} {0 403} {0 664} {0 466} {0 149} {0 816} {0 438} {0 291} {0 109} {0 43} {0 712} {0 456} {0 509} {0 718} {0 586} {0 49} {0 857} {0 11} {0 130} {0 338} {0 505} {0 362} {0 147} {0 560} {0 1005} {0 69} {0 102} {0 410} {0 833} {0 929} {0 700} {0 369} {0 996} {0 632} {0 832} {0 132} {0 512} {0 951} {0 986} {0 107} {0 57} {0 501} {0 269} {0 50} {0 272} {0 377} {0 891} {0 70} {0 250} {0 245} {0 635} {0 191} {0 312} {0 528} {0 143} {0 826} {0 668} {0 998} {0 225} {0 987} {0 411} {0 568} {0 137} {0 841} {0 176} {0 373} {0 671} {0 899} {0 502} {0 486} {0 592} {0 828} {0 982} {0 0} {0 357} {0 421} {0 994} {0 73} {0 665} {0 846} {0 806} {0 22} {0 360} {0 786} {0 261} {0 19} {0 979} {0 437} {0 458} {0 872} {0 744} {0 917} {0 404} {0 152} {0 964} {0 34} {0 384} {0 725} {0 780} {0 336} {0 924} {0 609} {0 112} {0 192} {0 331} {0 277} {0 674} {0 569} {0 155} {0 614} {0 623} {0 317} {0 211} {0 59} {0 874} {0 993} {0 393} {0 246} {0 407} {0 354} {0 448} {0 602} {0 720} {0 898} {0 424} {0 1004} {0 247} {0 84} {0 264} {0 289} {0 124} {0 468} {0 27} {0 798} {0 776} {0 836} {0 39} {0 742} {0 661} {0 827} {0 863} {0 441} {0 26} {0 374} {0 927} {0 853} {0 313} {0 193} {0 345} {0 873} {0 299} {0 465} {0 585} {0 966} {0 764} {0 340} {0 478} {0 684} {0 60} {0 553} {0 224} {0 713} {0 172} {0 555} {0 1019} {0 198} {0 216} {0 527} {0 490} {0 100} {0 550} {0 398} {0 376} {0 344} {0 86} {0 503} {0 975} {0 561} {0 66} {0 791} {0 843} {0 378} {0 400} {0 588} {0 1022} {0 222} {0 617} {0 136} {0 637} {0 335} {0 854} {0 436} {0 604} {0 481} {0 594} {0 583} {0 1010} {0 593} {0 111} {0 242} {0 597} {0 608} {0 212} {0 662} {0 474} {0 258} {0 554} {0 31} {0 167} {0 567} {0 706} {0 577} {0 752} {0 639} {0 799} {0 919} {0 663} {0 40} {0 464} {0 965} {0 847} {0 451} {0 848} {0 256} {0 591} {0 692} {0 871} {0 830} {0 301} {0 563} {0 880} {0 217} {0 782} {0 849} {0 343} {0 952} {0 990} {0 911} {0 110} {0 241} {0 292} {0 356} {0 142} {0 599} {0 856} {0 153} {0 989} {0 215} {0 251} {0 721} {0 157} {0 944} {0 655} {0 275} {0 7} {0 866} {0 72} {0 135} {0 233} {0 46} {0 601} {0 749} {0 131} {0 838} {0 194} {0 334} {0 707} {0 351} {0 638} {0 875} {0 773} {0 118} {0 524} {0 936} {0 877} {0 165} {0 462} {0 350} {0 85} {0 459} {0 103} {0 166} {0 488} {0 239} {0 6} {0 546} {0 579} {0 945} {0 366} {0 757} {0 355} {0 134} {0 20} {0 463} {0 513} {0 420} {0 183} {0 1012} {0 549} {0 859} {0 293} {0 1007} {0 405} {0 995} {0 649} {0 274} {0 285} {0 162} {0 804} {0 506} {0 126} {0 824} {0 367} {0 98} {0 117} {0 556} {0 408} {0 648} {0 446} {0 683} {0 35} {0 855} {0 974} {0 309} {0 950} {0 763} {0 1018} {0 327} {0 483} {0 123} {0 479} {0 1016} {0 473} {0 296} {0 385} {0 747} {0 302} {0 179} {0 711} {0 794} {0 730} {0 910} {0 141} {0 736} {0 860} {0 383} {0 746} {0 453} {0 758} {0 906} {0 95} {0 976} {0 573} {0 729} {0 23} {0 146} {0 30} {0 433} {0 196} {0 803} {0 733} {0 682} {0 785} {0 116} {0 540} {0 615} {0 1009} {0 151} {0 442} {0 497} {0 164} {0 842} {0 445} {0 565} {0 958} {0 997} {0 361} {0 510} {0 626} {0 516} {0 670} {0 387} {0 276} {0 223} {0 621} {0 452} {0 412} {0 640} {0 467} {0 909} {0 578} {0 582} {0 409} {0 101} {0 87} {0 174} {0 265} {0 339} {0 295} {0 1001} {0 514} {0 307} {0 16} {0 750} {0 94} {0 364} {0 716} {0 867} {0 48} {0 557} {0 732} {0 218} {0 905} {0 916} {0 382} {0 495} {0 862} {0 771} {0 204} {0 913} {0 230} {0 678} {0 99} {0 267} {0 696} {0 921} {0 864} {0 922} {0 341} {0 197} {0 472} {0 379} {0 330} {0 372} {0 616} {0 876} {0 346} {0 1020} {0 928} {0 430} {0 219} {0 200} {0 814} {0 145} {0 531} {0 893} {0 914} {0 64} {0 171} {0 469} {0 892} {0 47} {0 231} {0 423} {0 717} {0 4} {0 207} {0 221} {0 735} {0 751} {0 850} {0 907} {0 766} {0 262} {0 202} {0 504} {0 544} {0 870} {0 789} {0 1011} {0 229} {0 981} {0 879} {0 319} {0 491} {0 825} {0 13} {0 590} {0 790} {0 431} {0 548} {0 888} {0 32} {0 36} {0 449} {0 286} {0 415} {0 248} {0 920} {0 961} {0 948} {0 956} {0 220} {0 288} {0 831} {0 1006} {0 743} {0 82} {0 983} {0 818} {0 967} {0 493} {0 417} {0 271} {0 15} {0 419} {0 894} {0 523} {0 834} {0 391} {0 620} {0 1014} {0 159} {0 169} {0 962} {0 624} {0 887} {0 520} {0 775} {0 185} {0 461} {0 75} {0 89} {0 425} {0 325} {0 584} {0 304} {0 868} {0 511} {0 652} {0 575} {0 535} {0 676} {0 884} {0 522} {0 195} {0 485} {0 559} {0 651} {0 912} {0 500} {0 942} {0 541} {0 628} {0 715} {0 363} {0 386} {0 358} {0 681} {0 739}]} [false false] [0 1] [0x23ca9e0 0x23ca9e0] 0xc00371cee0 0xc0020a7320}) %!s(*chunk.SortedRowContainer=&{0xc00389d580 {{{0 0} 0 0 0 0} [{0 260} {0 477} {0 239} {0 620} {0 816} {0 488} {0 247} {0 304} {0 1001} {0 449} {0 521} {0 645} {0 560} {0 951} {0 637} {0 921} {0 706} {0 633} {0 615} {0 515} {0 453} {0 61} {0 461} {0 383} {0 132} {0 715} {0 863} {0 355} {0 913} {0 707} {0 214} {0 887} {0 875} {0 716} {0 254} {0 758} {0 870} {0 204} {0 772} {0 53} {0 556} {0 704} {0 219} {0 475} {0 205} {0 724} {0 610} {0 591} {0 663} {0 808} {0 458} {0 59} {0 837} {0 150} {0 907} {0 891} {0 672} {0 798} {0 530} {0 767} {0 840} {0 256} {0 95} {0 966} {0 793} {0 901} {0 413} {0 934} {0 486} {0 469} {0 107} {0 8} {0 801} {0 471} {0 340} {0 848} {0 421} {0 50} {0 407} {0 1015} {0 1} {0 371} {0 437} {0 464} {0 563} {0 743} {0 269} {0 769} {0 79} {0 225} {0 17} {0 871} {0 263} {0 778} {0 502} {0 44} {0 114} {0 16} {0 452} {0 653} {0 491} {0 478} {0 428} {0 180} {0 104} {0 274} {0 373} {0 822} {0 1011} {0 216} {0 54} {0 446} {0 358} {0 536} {0 467} {0 234} {0 337} {0 868} {0 805} {0 409} {0 852} {0 1008} {0 638} {0 414} {0 903} {0 443} {0 534} {0 194} {0 92} {0 117} {0 357} {0 911} {0 1022} {0 215} {0 198} {0 182} {0 1003} {0 924} {0 193} {0 85} {0 202} {0 593} {0 240} {0 12} {0 971} {0 980} {0 479} {0 89} {0 503} {0 149} {0 195} {0 869} {0 11} {0 115} {0 686} {0 273} {0 200} {0 779} {0 127} {0 523} {0 1019} {0 284} {0 310} {0 722} {0 473} {0 510} {0 424} {0 245} {0 323} {0 255} {0 100} {0 504} {0 411} {0 442} {0 91} {0 573} {0 969} {0 94} {0 141} {0 2} {0 846} {0 339} {0 755} {0 518} {0 346} {0 855} {0 546} {0 516} {0 390} {0 119} {0 341} {0 662} {0 551} {0 317} {0 780} {0 894} {0 71} {0 734} {0 412} {0 669} {0 303} {0 15} {0 380} {0 131} {0 817} {0 975} {0 241} {0 529} {0 401} {0 709} {0 905} {0 166} {0 463} {0 230} {0 410} {0 312} {0 116} {0 535} {0 611} {0 588} {0 28} {0 941} {0 281} {0 1016} {0 554} {0 299} {0 399} {0 713} {0 774} {0 726} {0 818} {0 910} {0 897} {0 422} {0 671} {0 519} {0 705} {0 249} {0 583} {0 500} {0 927} {0 886} {0 270} {0 748} {0 673} {0 338} {0 585} {0 118} {0 937} {0 395} {0 570} {0 675} {0 367} {0 997} {0 782} {0 352} {0 888} {0 429} {0 93} {0 906} {0 956} {0 955} {0 348} {0 931} {0 616} {0 973} {0 388} {0 970} {0 9} {0 465} {0 398} {0 128} {0 648} {0 861} {0 809} {0 658} {0 10} {0 167} {0 210} {0 963} {0 430} {0 433} {0 545} {0 733} {0 212} {0 176} {0 78} {0 668} {0 209} {0 181} {0 766} {0 938} {0 31} {0 288} {0 344} {0 47} {0 145} {0 602} {0 394} {0 925} {0 32} {0 374} {0 745} {0 844} {0 511} {0 701} {0 853} {0 351} {0 48} {0 168} {0 681} {0 550} {0 296} {0 945} {0 231} {0 807} {0 400} {0 850} {0 63} {0 325} {0 582} {0 134} {0 788} {0 457} {0 272} {0 185} {0 67} {0 233} {0 363} {0 276} {0 729} {0 484} {0 14} {0 702} {0 842} {0 285} {0 797} {0 170} {0 978} {0 33} {0 562} {0 834} {0 499} {0 952} {0 804} {0 587} {0 29} {0 474} {0 38} {0 922} {0 295} {0 789} {0 814} {0 914} {0 915} {0 542} {0 619} {0 520} {0 427} {0 148} {0 961} {0 725} {0 359} {0 277} {0 839} {0 763} {0 967} {0 1010} {0 244} {0 845} {0 140} {0 890} {0 208} {0 1004} {0 944} {0 160} {0 26} {0 111} {0 264} {0 802} {0 641} {0 883} {0 578} {0 909} {0 642} {0 659} {0 483} {0 35} {0 757} {0 872} {0 415} {0 661} {0 1021} {0 485} {0 810} {0 993} {0 68} {0 865} {0 717} {0 940} {0 450} {0 525} {0 123} {0 7} {0 364} {0 392} {0 73} {0 294} {0 537} {0 624} {0 760} {0 996} {0 354} {0 20} {0 396} {0 252} {0 39} {0 775} {0 298} {0 468} {0 229} {0 5} {0 280} {0 238} {0 58} {0 923} {0 55} {0 1023} {0 267} {0 992} {0 164} {0 169} {0 920} {0 25} {0 466} {0 553} {0 306} {0 878} {0 253} {0 605} {0 823} {0 990} {0 904} {0 129} {0 959} {0 1000} {0 96} {0 785} {0 565} {0 806} {0 106} {0 946} {0 331} {0 143} {0 995} {0 381} {0 423} {0 750} {0 950} {0 493} {0 313} {0 677} {0 752} {0 899} {0 408} {0 948} {0 601} {0 456} {0 739} {0 985} {0 786} {0 349} {0 498} {0 333} {0 773} {0 783} {0 335} {0 282} {0 795} {0 983} {0 438} {0 347} {0 226} {0 419} {0 496} {0 130} {0 470} {0 826} {0 300} {0 320} {0 856} {0 581} {0 819} {0 988} {0 235} {0 738} {0 943} {0 664} {0 445} {0 173} {0 1018} {0 568} {0 652} {0 34} {0 833} {0 854} {0 680} {0 685} {0 595} {0 405} {0 770} {0 246} {0 512} {0 592} {0 431} {0 487} {0 279} {0 984} {0 836} {0 13} {0 991} {0 197} {0 171} {0 262} {0 604} {0 1009} {0 1006} {0 190} {0 885} {0 708} {0 432} {0 460} {0 777} {0 908} {0 506} {0 646} {0 1007} {0 97} {0 629} {0 929} {0 857} {0 391} {0 135} {0 972} {0 436} {0 900} {0 177} {0 426} {0 81} {0 586} {0 251} {0 674} {0 577} {0 756} {0 425} {0 732} {0 237} {0 77} {0 626} {0 928} {0 76} {0 541} {0 336} {0 634} {0 608} {0 362} {0 912} {0 974} {0 792} {0 505} {0 41} {0 175} {0 382} {0 949} {0 548} {0 88} {0 617} {0 737} {0 24} {0 594} {0 459} {0 497} {0 830} {0 867} {0 606} {0 27} {0 1002} {0 873} {0 939} {0 776} {0 157} {0 884} {0 711} {0 196} {0 397} {0 265} {0 287} {0 640} {0 589} {0 136} {0 621} {0 137} {0 162} {0 379} {0 690} {0 21} {0 30} {0 614} {0 820} {0 18} {0 957} {0 790} {0 404} {0 696} {0 223} {0 51} {0 742} {0 559} {0 612} {0 261} {0 989} {0 821} {0 60} {0 103} {0 649} {0 305} {0 676} {0 133} {0 700} {0 723} {0 513} {0 87} {0 849} {0 841} {0 462} {0 712} {0 384} {0 679} {0 603} {0 947} {0 366} {0 596} {0 172} {0 444} {0 692} {0 138} {0 151} {0 228} {0 112} {0 236} {0 360} {0 6} {0 101} {0 999} {0 259} {0 561} {0 490} {0 329} {0 372} {0 628} {0 385} {0 191} {0 566} {0 316} {0 220} {0 882} {0 40} {0 441} {0 199} {0 472} {0 417} {0 514} {0 736} {0 803} {0 321} {0 356} {0 584} {0 23} {0 102} {0 691} {0 327} {0 328} {0 386} {0 636} {0 494} {0 509} {0 979} {0 547} {0 227} {0 1013} {0 727} {0 744} {0 881} {0 831} {0 622} {0 942} {0 319} {0 224} {0 105} {0 375} {0 699} {0 693} {0 165} {0 120} {0 892} {0 522} {0 302} {0 728} {0 953} {0 232} {0 52} {0 507} {0 455} {0 72} {0 186} {0 144} {0 631} {0 828} {0 37} {0 345} {0 543} {0 764} {0 293} {0 189} {0 598} {0 936} {0 98} {0 156} {0 124} {0 932} {0 720} {0 916} {0 643} {0 710} {0 678} {0 765} {0 694} {0 832} {0 301} {0 315} {0 297} {0 370} {0 657} {0 418} {0 555} {0 19} {0 613} {0 976} {0 747} {0 703} {0 730} {0 184} {0 152} {0 876} {0 567} {0 99} {0 815} {0 960} {0 268} {0 714} {0 600} {0 314} {0 217} {0 571} {0 741} {0 322} {0 698} {0 889} {0 393} {0 49} {0 749} {0 330} {0 684} {0 86} {0 376} {0 768} {0 90} {0 126} {0 781} {0 654} {0 527} {0 110} {0 896} {0 740} {0 80} {0 650} {0 243} {0 919} {0 965} {0 851} {0 719} {0 609} {0 838} {0 188} {0 813} {0 731} {0 877} {0 389} {0 517} {0 332} {0 508} {0 994} {0 977} {0 825} {0 139} {0 440} {0 787} {0 539} {0 289} {0 403} {0 599} {0 533} {0 656} {0 860} {0 207} {0 574} {0 283} {0 683} {0 607} {0 862} {0 187} {0 580} {0 318} {0 62} {0 448} {0 954} {0 898} {0 632} {0 635} {0 644} {0 794} {0 540} {0 576} {0 968} {0 1020} {0 926} {0 866} {0 524} {0 858} {0 666} {0 538} {0 759} {0 286} {0 754} {0 958} {0 893} {0 762} {0 630} {0 242} {0 158} {0 531} {0 65} {0 751} {0 311} {0 964} {0 290} {0 695} {0 201} {0 159} {0 161} {0 799} {0 564} {0 353} {0 627} {0 482} {0 378} {0 981} {0 665} {0 753} {0 179} {0 147} {0 1005} {0 183} {0 569} {0 918} {0 69} {0 70} {0 1014} {0 812} {0 365} {0 266} {0 257} {0 447} {0 526} {0 74} {0 108} {0 43} {0 986} {0 56} {0 434} {0 0} {0 402} {0 575} {0 784} {0 122} {0 75} {0 811} {0 350} {0 22} {0 250} {0 42} {0 113} {0 146} {0 387} {0 689} {0 248} {0 476} {0 142} {0 435} {0 618} {0 625} {0 368} {0 258} {0 718} {0 552} {0 935} {0 45} {0 275} {0 46} {0 218} {0 155} {0 655} {0 902} {0 827} {0 492} {0 796} {0 874} {0 153} {0 109} {0 292} {0 278} {0 864} {0 82} {0 771} {0 451} {0 721} {0 687} {0 843} {0 998} {0 735} {0 291} {0 800} {0 377} {0 962} {0 930} {0 879} {0 1017} {0 163} {0 3} {0 495} {0 982} {0 933} {0 406} {0 660} {0 154} {0 213} {0 489} {0 667} {0 670} {0 66} {0 178} {0 761} {0 528} {0 544} {0 791} {0 222} {0 439} {0 334} {0 651} {0 697} {0 639} {0 83} {0 420} {0 597} {0 84} {0 688} {0 342} {0 579} {0 572} {0 211} {0 847} {0 501} {0 824} {0 57} {0 987} {0 480} {0 557} {0 206} {0 308} {0 416} {0 746} {0 549} {0 64} {0 647} {0 307} {0 880} {0 125} {0 590} {0 623} {0 859} {0 4} {0 174} {0 361} {0 221} {0 1012} {0 481} {0 532} {0 192} {0 203} {0 454} {0 324} {0 835} {0 895} {0 917} {0 829} {0 36} {0 558} {0 343} {0 309} {0 121} {0 326} {0 271} {0 369} {0 682}]} [false false] [0 1] [0x23ca9e0 0x23ca9e0] 0xc004e57f20 0xc0063ed9e0})]" should have 1 item(s), but has 2
        	Test:       	TestSortSpillDisk
--- FAIL: TestSortSpillDisk (0.08s) 

https://prow.pingcap.net/view/gs/pingcapprow/logs/bazel_test_tidb/1557686819372404736

2. What did you expect to see? (Required)

3. What did you see instead (Required)

4. What is your TiDB version? (Required)

@hawkingrei hawkingrei added type/bug The issue is confirmed as a bug. component/test labels Aug 11, 2022
@ti-chi-bot ti-chi-bot added may-affects-4.0 This bug maybe affects 4.0.x versions. may-affects-5.0 This bug maybe affects 5.0.x versions. may-affects-5.1 This bug maybe affects 5.1.x versions. may-affects-5.2 This bug maybe affects 5.2.x versions. may-affects-5.3 This bug maybe affects 5.3.x versions. may-affects-5.4 This bug maybe affects 5.4.x versions. may-affects-6.0 may-affects-6.1 may-affects-6.2 labels Aug 12, 2022
@ChenPeng2013 ChenPeng2013 removed may-affects-4.0 This bug maybe affects 4.0.x versions. may-affects-5.1 This bug maybe affects 5.1.x versions. may-affects-5.2 This bug maybe affects 5.2.x versions. may-affects-5.3 This bug maybe affects 5.3.x versions. may-affects-5.4 This bug maybe affects 5.4.x versions. may-affects-5.0 This bug maybe affects 5.0.x versions. may-affects-6.0 may-affects-6.1 may-affects-6.2 labels Aug 12, 2022
@YangKeao YangKeao self-assigned this Aug 16, 2022
@YangKeao
Copy link
Member

I think I have found the reason why this test is unstable (and it seems to be a bug), but I'm not sure how to fix it. There are many unstable assertions in this test:

  1. Test 2 partitions and all data in disk.

This test will fail, in the following situation:

next -> add -> memory exceeds ->         -> add  -> memory exceeds, but it's spilling, so do nothing
                              -> sort                                                                -> spill

Then it will have two partitions, with the second one in memory

  1. Test only 1 partition but spill disk.

Nearly the same reason, it could have one or two partitions, and we cannot tell whether the second one is in the memory or disk.

While I was trying to fix this problem, I have one question:

Why is only rootExceed triggered?

The rootExceed doesn't have information about the child row containers, so it cannot spill the data tracked by child memory tracker 🤔 (which caused the first problem. The newly created row container is attached, but not spilled finally.)

@YangKeao
Copy link
Member

Why is only rootExceed triggered?
The rootExceed doesn't have information about the child row containers, so it cannot spill the data tracked by child memory tracker thinking (which caused the first problem. The newly created row container is attached, but not spilled finally.)

I'll take a look at the fallback route.

@D3Hunter
Copy link
Contributor

D3Hunter commented Nov 8, 2023

this case fail again

=== RUN   TestSortSpillDisk
[2023/11/08 11:22:07.772 +08:00] [INFO] [row_container.go:436] ["memory exceeds quota, spill to disk now."] [consumed=8192] [quota=1]
    executor_pkg_test.go:346: 
        	Error Trace:	pkg/executor/executor_pkg_test.go:346
        	Error:      	Not equal: 
        	            	expected: true
        	            	actual  : false
        	Test:       	TestSortSpillDisk
--- FAIL: TestSortSpillDisk (0.01s)

https://do.pingcap.net/jenkins/blue/organizations/jenkins/pingcap%2Ftidb%2Fghpr_unit_test/detail/ghpr_unit_test/37019/pipeline/

@hawkingrei
Copy link
Member Author

@xzhangxian1008
Copy link
Contributor

This pr refactors sort spill, the issue may have been fixed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/test severity/major type/bug The issue is confirmed as a bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants