test1545: disable deprecation warnings#12444
Closed
vszakats wants to merge 1 commit intocurl:masterfrom
Closed
Conversation
This was referenced Dec 2, 2023
This was referenced Dec 20, 2023
vszakats
added a commit
that referenced
this pull request
Dec 21, 2023
PowerShell works (after a steep development curve), but one property of it stuck and kept causing unresolvable usability issues: With `$ErrorActionPreference=Stop`, it does abort on failures, but shows only the first line of the error message. In `Continue` mode, it shows the full error message, but doesn't stop on all errors. Another issue is PowerShell considering any stderr output as if the command failed (this has been improved in 7.2 (2021-Nov), but fixed versions aren't running in CI and will not be for a long time in all test images.) Thus, we're going with bash. Also: - use `-j2` with autotools tests, making them finish 5-15 minutes per job faster. - omit `POSIX_PATH_PREFIX`. - use `WINDIR`. - prefer forward slashes. Follow-up to: 75078a4 #11999 Ref: #12444 Fixes #12560 Closes #12572
vszakats
added a commit
to vszakats/curl
that referenced
this pull request
Sep 5, 2024
vszakats
added a commit
that referenced
this pull request
Sep 20, 2024
Suppress deprecation warnings the closest to the deprecated code, using `CURL_IGNORE_DEPRECATION()`. Then drop build-specific suppressions, and file-wide ones. The latter is not compatible with Unity mode. Also replace manual suppressions with a macro to apply to all compilers with deprecation warning support. Also enable deprecation warnings for clang. - curl/curl.h: enable deprecation warnings for clang. - docs/examples: stop setting `CURL_DISABLE_DEPRECATION` with autotools. Suppression moved to C-level earlier. Syncs with cmake. Follow-up to 5fc61a3 #14123 - tests/http/clients: stop setting `CURL_DISABLE_DEPRECATION` in autotools. If it becomes necessary in the future, it can be done in C via the macro. Syncs with cmake. - lib1545: stop setting `CURL_DISABLE_DEPRECATION` in autotools. Drop guard from test source. Follow-up to 0f10360 #12444 - libtest, unit: replace `CURL_DISABLE_DEPRECATION` with `CURL_IGNORE_DEPRECATION()`. - docs/examples: replace pragmas with `CURL_IGNORE_DEPRECATION()`. Closes #14789
pps83
pushed a commit
to pps83/curl
that referenced
this pull request
Apr 26, 2025
Suppress deprecation warnings the closest to the deprecated code, using `CURL_IGNORE_DEPRECATION()`. Then drop build-specific suppressions, and file-wide ones. The latter is not compatible with Unity mode. Also replace manual suppressions with a macro to apply to all compilers with deprecation warning support. Also enable deprecation warnings for clang. - curl/curl.h: enable deprecation warnings for clang. - docs/examples: stop setting `CURL_DISABLE_DEPRECATION` with autotools. Suppression moved to C-level earlier. Syncs with cmake. Follow-up to 5fc61a3 curl#14123 - tests/http/clients: stop setting `CURL_DISABLE_DEPRECATION` in autotools. If it becomes necessary in the future, it can be done in C via the macro. Syncs with cmake. - lib1545: stop setting `CURL_DISABLE_DEPRECATION` in autotools. Drop guard from test source. Follow-up to 0f10360 curl#12444 - libtest, unit: replace `CURL_DISABLE_DEPRECATION` with `CURL_IGNORE_DEPRECATION()`. - docs/examples: replace pragmas with `CURL_IGNORE_DEPRECATION()`. Closes curl#14789
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes:
https://ci.appveyor.com/project/curlorg/curl/builds/48631551/job/bhx74e0i66yrp6pk#L1205
Same with details:
https://ci.appveyor.com/project/curlorg/curl/builds/48662893/job/ol8a78q9gmilb6wt#L1263
Follow-up to 07a3cd8 #12421
Fixes #12445
Closes #12444
https://ci.appveyor.com/project/curlorg/curl/builds/48662115/job/oaos4h0nf8nvwvrp#L1183
What is the way to tell PowerShell to show the full error and stop?
The current
$ErrorActionPreference = 'Stop'inappveyor.ymlclearly stops but hides the error.Continue(the default) shows the error but won't stop. UsingContinueand the trick used byGHA make the script abort when running
curl(with exit code 0):https://ci.appveyor.com/project/curlorg/curl/builds/48663318/job/jx1glcllralaujpp#L445
likely because it writes to stderr, which is considered an error by PowerShell versions
offered in CI.