From 8c3c3f55612481e8f4d42190835159fcfc8d5a7e Mon Sep 17 00:00:00 2001 From: "string.Empty" Date: Sat, 24 Feb 2024 00:58:38 +0800 Subject: [PATCH] fix: Network error --- .github/workflows/cmake.yml | 37 +++++++++++++++++++++++++++++++++++-- Dice/Dice.cpp | 2 +- Dice/DiceMod.cpp | 3 +-- Dice/DiceNetwork.cpp | 4 ++-- 4 files changed, 39 insertions(+), 7 deletions(-) diff --git a/.github/workflows/cmake.yml b/.github/workflows/cmake.yml index bb0f5941..bdc05457 100644 --- a/.github/workflows/cmake.yml +++ b/.github/workflows/cmake.yml @@ -50,6 +50,15 @@ jobs: working-directory: ${{github.workspace}}/vcpkg run: bootstrap-vcpkg.bat + - name: Package Clear + uses: actions/delete-package-versions@v4 + with: + package-name: aws-c-s3_${{ matrix.triplet }} + package-type: nuget + min-versions-to-keep: 1 + token: ${{ secrets.GITHUB_TOKEN }} + + - name: 'Setup NuGet Credentials' shell: 'bash' # Replace with your organization name @@ -135,7 +144,15 @@ jobs: if: steps.cache.outputs.cache-hit != 'true' working-directory: ${{github.workspace}}/vcpkg run: ./bootstrap-vcpkg.sh - + + - name: Package Clear + uses: actions/delete-package-versions@v4 + with: + package-name: aws-c-s3_${{ matrix.triplet }} + package-type: nuget + min-versions-to-keep: 0 + token: ${{ secrets.GITHUB_TOKEN }} + - name: 'Setup NuGet Credentials' shell: 'bash' # Replace with your organization name @@ -241,6 +258,14 @@ jobs: working-directory: ${{github.workspace}}/vcpkg run: ./bootstrap-vcpkg.sh + - name: Package Clear + uses: actions/delete-package-versions@v4 + with: + package-name: aws-c-s3_${{ matrix.triplet }} + package-type: nuget + min-versions-to-keep: 0 + token: ${{ secrets.GITHUB_TOKEN }} + - name: 'Setup NuGet Credentials' shell: 'bash' # Replace with your organization name @@ -329,7 +354,15 @@ jobs: if: steps.cache.outputs.cache-hit != 'true' working-directory: ${{github.workspace}}/vcpkg run: ./bootstrap-vcpkg.sh - + + - name: Package Clear + uses: actions/delete-package-versions@v4 + with: + package-name: aws-c-s3_${{ matrix.triplet }}-static + package-type: nuget + min-versions-to-keep: 0 + token: ${{ secrets.GITHUB_TOKEN }} + - name: 'Setup NuGet Credentials' shell: 'bash' # Replace with your organization name diff --git a/Dice/Dice.cpp b/Dice/Dice.cpp index d2a54576..1db29d39 100644 --- a/Dice/Dice.cpp +++ b/Dice/Dice.cpp @@ -598,7 +598,7 @@ bool eve_GroupAdd(Chat& grp) { return true; } if (grp.is("协议无效"))return 0; - if (string selfIntro{ getMsg("strAddGroup", AnysTable{{"gid",fromGID}}) }; + if (string selfIntro{ getMsg("strAddGroup", AnysTable{AttrVars{{"gid",fromGID}}}) }; !selfIntro.empty()) { this_thread::sleep_for(2s); AddMsgToQueue(selfIntro, { 0,fromGID, 0 }); diff --git a/Dice/DiceMod.cpp b/Dice/DiceMod.cpp index 5e3bbb2a..59ef8591 100644 --- a/Dice/DiceMod.cpp +++ b/Dice/DiceMod.cpp @@ -1110,8 +1110,7 @@ void DiceModManager::build() { } if (!resLog.empty()) { resLog << "模块加载完毕√"; - Enabled ? console.log(getMsg("strSelfName") + "\n" + resLog.show("\n"), 1, printSTNow()) - : DD::debugLog(resLog.show("\n")); + console.log(getMsg("strSelfName") + "\n" + resLog.show("\n"), int(Enabled), printSTNow()); } isIniting = false; } diff --git a/Dice/DiceNetwork.cpp b/Dice/DiceNetwork.cpp index 5ee64655..e4ffd420 100644 --- a/Dice/DiceNetwork.cpp +++ b/Dice/DiceNetwork.cpp @@ -175,7 +175,7 @@ namespace Network } if (dwRetCode != 200) { - des = getMsg("strRequestRetCodeErr", AnysTable{ {"error", std::to_string(dwRetCode)} }); + des = getMsg("strRequestRetCodeErr", AnysTable{ AttrVars{{"error", std::to_string(dwRetCode)}}}); goto InternetClose; } DWORD preRcvCnt; @@ -319,7 +319,7 @@ namespace Network } if (dwRetCode != 200) { - des = getMsg("strRequestRetCodeErr", AnysTable{ {"error", std::to_string(dwRetCode)} }); + des = getMsg("strRequestRetCodeErr", AnysTable{ AttrVars{{"error", std::to_string(dwRetCode)} } }); InternetCloseHandle(hRequest); InternetCloseHandle(hConnect); InternetCloseHandle(hInternet);