Conversation
This following change in the runtime now causes this analyzer to complain about some Debug.Assert calls which doesn't make sense. https://github.com/dotnet/core/blob/main/release-notes/9.0/preview/preview7/libraries.md#debugassert-now-reports-assert-condition-by-default https://rules.sonarsource.com/csharp/RSPEC-3236/
|
Can we have a basic Lock polyfill to save on the #ifdefs? e.g. #if !NET9_0_OR_GREATER
namespace Renci.SshNet.Common;
internal sealed class Lock
{
public bool TryEnter() => Monitor.TryEnter(this);
public void Exit() => Monitor.Exit(this);
} |
|
Makes sense, pushed. |
|
@mus65, you'll also want to update global.json. |
test/Renci.SshNet.AotCompatibilityTestApp/Renci.SshNet.AotCompatibilityTestApp.csproj
Show resolved
Hide resolved
test/Renci.SshNet.IntegrationBenchmarks/Renci.SshNet.IntegrationBenchmarks.csproj
Show resolved
Hide resolved
test/Renci.SshNet.IntegrationTests/Renci.SshNet.IntegrationTests.csproj
Outdated
Show resolved
Hide resolved
|
@Rob-Hague, are planning on merging this before the release of .NET 9.0? In theory, there may even be API changes - I'm thinking of the Lock class - between now and the release. It's highly unlikely though. |
|
@drieseng @Rob-Hague I updated global.json . I had to reference RC1 explicitly though, so I have to change it when final is released. I left it a draft because it's still preview and wouldn't expect it to be merged before .NET 9 final. RC1 is already released, so I wouldn't expect any more API changes. |
|
Yeah, we will merge once .NET 9 is released Newer targets can be used on appveyor with apt-get, as in the opposite of #1352 |
Co-authored-by: Rob Hague <rob.hague00@gmail.com>
for some reason this happens starting with .NET 9.0 RC2:
/home/mus/git/SSH.NET/test/Renci.SshNet.IntegrationTests/Renci.SshNet.IntegrationTests.csproj : error NU1605:
Warning As Error: Detected package downgrade: BouncyCastle.Cryptography from 2.4.0 to 2.3.1. Reference the package directly from the project to select a different version.
Renci.SshNet.IntegrationTests -> SSH.NET 1.0.0 -> BouncyCastle.Cryptography (>= 2.4.0)
Renci.SshNet.IntegrationTests -> Testcontainers 3.10.0 -> BouncyCastle.Cryptography (>= 2.3.1)
|
This is now only blocked by AppVeyor not supporting .NET 9. apt-get is not going work either because the dotnet9 package is not available in Ubuntu 22.04 (see https://launchpad.net/ubuntu/+source/dotnet9 ). @Rob-Hague has there been any thought about moving to GitHub actions? |
|
I seem to remember @WojciechNagorski trying it but I can't find a PR so may be imagining |
|
Feel free to give a go though |
I had to disable a SonarSource analyzer and made use of the new
Locktype, see separate Commits.CI is expected to fail because of missing .NET 9 binaries in AppVeyor. Build and tests pass locally.
Can be merged when .NET 9 final is released and AppVeyor supports it.