From f1dc153caf9d84cd1d0056e52286cc0163e3f4d3 Mon Sep 17 00:00:00 2001 From: Jordan Dominion Date: Sat, 21 Oct 2023 00:34:28 -0400 Subject: [PATCH 1/3] Create global.json to lock .NET version (#1517) This fixes builds failing when .NET 8 is installed. --- global.json | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 global.json diff --git a/global.json b/global.json new file mode 100644 index 00000000000..22dfd864b4c --- /dev/null +++ b/global.json @@ -0,0 +1,6 @@ +{ + "sdk": { + "version": "7.0.0", + "rollForward": "latestFeature" + } +} From fab769776dada6b9bcad546094d78c604049e0e9 Mon Sep 17 00:00:00 2001 From: Jordan Dominion Date: Sat, 21 Oct 2023 01:38:56 -0400 Subject: [PATCH 2/3] Add Byond.TopicSender dependency to packaging (#1518) --- OpenDreamPackageTool/ServerPackaging.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/OpenDreamPackageTool/ServerPackaging.cs b/OpenDreamPackageTool/ServerPackaging.cs index fa0a810c8c4..0181c1ea28c 100644 --- a/OpenDreamPackageTool/ServerPackaging.cs +++ b/OpenDreamPackageTool/ServerPackaging.cs @@ -34,6 +34,7 @@ public static class ServerPackaging { "OpenDreamShared", "OpenDreamRuntime", "Byond.TopicSender", + "Microsoft.Extensions.Logging.Abstractions", // dep of Byond.TopicSender "DMCompiler" }; @@ -43,6 +44,7 @@ public static class ServerPackaging { "OpenDreamShared", "OpenDreamRuntime", "Byond.TopicSender", + "Microsoft.Extensions.Logging.Abstractions", // dep of Byond.TopicSender "DMCompiler" }; From f684cf33cd11977d2724924baf22a4320e27081d Mon Sep 17 00:00:00 2001 From: ike709 Date: Fri, 20 Oct 2023 23:48:29 -0700 Subject: [PATCH 3/3] Remove all unnecessary `using` directives (#1512) * Remove all unnecessary `using` directives * debug usings --------- Co-authored-by: ike709 --- Content.IntegrationTests/ContentIntegrationTest.cs | 2 -- Content.IntegrationTests/GameTests.cs | 4 ---- Content.IntegrationTests/SetupCompileDM.cs | 1 - Content.Tests/DMTests.cs | 1 - DMCompiler/Compiler/DM/DMAST.cs | 2 -- DMCompiler/Compiler/DM/DMASTHelper.cs | 1 - DMCompiler/Compiler/DMPreprocessor/DMPreprocessor.cs | 1 - DMCompiler/Compiler/DMPreprocessor/DMPreprocessorParser.cs | 3 --- DMDisassembler/DMProc.cs | 1 - OpenDreamClient/Input/ContextMenu/ContextMenuItem.xaml.cs | 2 -- OpenDreamClient/Input/ContextMenu/VerbMenuPopup.xaml.cs | 1 - OpenDreamClient/Interface/Controls/ControlButton.cs | 3 +-- OpenDreamClient/Interface/Controls/ControlInput.cs | 3 +-- OpenDreamClient/Interface/Controls/ControlWindow.cs | 3 +-- OpenDreamClient/Interface/DebugWindows/MacrosWindow.cs | 3 +-- OpenDreamClient/Interface/DreamInterfaceManager.cs | 2 -- OpenDreamClient/Interface/InterfaceMacro.cs | 3 +-- OpenDreamClient/Interface/InterfaceMenu.cs | 3 +-- OpenDreamClient/Rendering/ClientImagesSystem.cs | 2 -- OpenDreamRuntime/Input/DreamCommandSystem.cs | 3 +-- OpenDreamRuntime/LocalHostConGroup.cs | 2 ++ .../Procs/DebugAdapter/Protocol/ExceptionBreakMode.cs | 2 -- .../Procs/DebugAdapter/Protocol/RequestStackTrace.cs | 1 - OpenDreamRuntime/Procs/DreamEnumerators.cs | 1 - OpenDreamRuntime/Procs/Native/DreamProcNativeHelpers.cs | 3 +-- OpenDreamRuntime/Rendering/ServerClientImagesSystem.cs | 3 --- OpenDreamShared/Dream/Procs/ProcAttributes.cs | 1 - OpenDreamShared/Network/Messages/MsgLoadInterface.cs | 3 +-- OpenDreamShared/Rendering/SharedClientImagesSystem.cs | 3 +-- OpenDreamShared/SharedOpenDreamIoC.cs | 3 --- 30 files changed, 12 insertions(+), 54 deletions(-) diff --git a/Content.IntegrationTests/ContentIntegrationTest.cs b/Content.IntegrationTests/ContentIntegrationTest.cs index 4f8e8def138..8ae4dce6213 100644 --- a/Content.IntegrationTests/ContentIntegrationTest.cs +++ b/Content.IntegrationTests/ContentIntegrationTest.cs @@ -1,13 +1,11 @@ using System; using System.Threading.Tasks; using OpenDreamClient; -using OpenDreamServer; using OpenDreamShared; using NUnit.Framework; using OpenDreamClient.Interface; using OpenDreamRuntime; using Robust.Client; -using Robust.Client.WebView; using Robust.Server; using Robust.Shared.ContentPack; using Robust.Shared.IoC; diff --git a/Content.IntegrationTests/GameTests.cs b/Content.IntegrationTests/GameTests.cs index 471cccdd824..2f2319afba7 100644 --- a/Content.IntegrationTests/GameTests.cs +++ b/Content.IntegrationTests/GameTests.cs @@ -1,10 +1,6 @@ -using System.Diagnostics; using System.Threading.Tasks; using NUnit.Framework; using OpenDreamRuntime; -using Robust.Server.Player; -using Robust.Shared.IoC; -using Robust.Shared.Network; namespace Content.IntegrationTests { [TestFixture] diff --git a/Content.IntegrationTests/SetupCompileDM.cs b/Content.IntegrationTests/SetupCompileDM.cs index bfb942a1a96..f9ec1f91599 100644 --- a/Content.IntegrationTests/SetupCompileDM.cs +++ b/Content.IntegrationTests/SetupCompileDM.cs @@ -1,7 +1,6 @@ using System; using System.IO; using NUnit.Framework; -using NUnit.Framework.Internal; // This it outside of any namespace so it affects the whole assembly. [SetUpFixture] diff --git a/Content.Tests/DMTests.cs b/Content.Tests/DMTests.cs index ef1fdd853bd..6723dde4ba3 100644 --- a/Content.Tests/DMTests.cs +++ b/Content.Tests/DMTests.cs @@ -5,7 +5,6 @@ using NUnit.Framework; using OpenDreamRuntime; using OpenDreamRuntime.Objects; -using OpenDreamRuntime.Procs; using OpenDreamRuntime.Rendering; using OpenDreamShared.Rendering; using Robust.Shared.Asynchronous; diff --git a/DMCompiler/Compiler/DM/DMAST.cs b/DMCompiler/Compiler/DM/DMAST.cs index b60eb9a1bee..9ddaadd6263 100644 --- a/DMCompiler/Compiler/DM/DMAST.cs +++ b/DMCompiler/Compiler/DM/DMAST.cs @@ -1,10 +1,8 @@ using System; using System.Collections.Generic; -using JetBrains.Annotations; using System.Linq; using OpenDreamShared.Compiler; using OpenDreamShared.Dream; -using OpenDreamShared.Dream.Procs; namespace DMCompiler.Compiler.DM { public interface DMASTVisitor : ASTVisitor { diff --git a/DMCompiler/Compiler/DM/DMASTHelper.cs b/DMCompiler/Compiler/DM/DMASTHelper.cs index ee463cff5f0..a37890f7340 100644 --- a/DMCompiler/Compiler/DM/DMASTHelper.cs +++ b/DMCompiler/Compiler/DM/DMASTHelper.cs @@ -5,7 +5,6 @@ using System.Collections.Generic; using System.Reflection; using OpenDreamShared.Dream; -using OpenDreamShared.Dream.Procs; using OpenDreamShared.Compiler; namespace DMCompiler.Compiler.DM { diff --git a/DMCompiler/Compiler/DMPreprocessor/DMPreprocessor.cs b/DMCompiler/Compiler/DMPreprocessor/DMPreprocessor.cs index f5c7c487825..08b8a2bcf0c 100644 --- a/DMCompiler/Compiler/DMPreprocessor/DMPreprocessor.cs +++ b/DMCompiler/Compiler/DMPreprocessor/DMPreprocessor.cs @@ -3,7 +3,6 @@ using System.Collections.Generic; using System.IO; using System.Linq; -using System.Text; using DMCompiler.Compiler.DM; using OpenDreamShared.Compiler; using Robust.Shared.Utility; diff --git a/DMCompiler/Compiler/DMPreprocessor/DMPreprocessorParser.cs b/DMCompiler/Compiler/DMPreprocessor/DMPreprocessorParser.cs index 61bcec149af..a0f40efa270 100644 --- a/DMCompiler/Compiler/DMPreprocessor/DMPreprocessorParser.cs +++ b/DMCompiler/Compiler/DMPreprocessor/DMPreprocessorParser.cs @@ -1,11 +1,8 @@ using DMCompiler.Compiler.DM; -using DMCompiler.DM; using OpenDreamShared.Compiler; using System; using System.Collections.Generic; using System.Linq; -using System.Text; -using System.Threading.Tasks; #nullable enable namespace DMCompiler.Compiler.DMPreprocessor { diff --git a/DMDisassembler/DMProc.cs b/DMDisassembler/DMProc.cs index eede3e94bfc..4cea3718e4b 100644 --- a/DMDisassembler/DMProc.cs +++ b/DMDisassembler/DMProc.cs @@ -1,5 +1,4 @@ using OpenDreamRuntime.Procs; -using OpenDreamShared.Dream.Procs; using OpenDreamShared.Json; using System; using System.Collections.Generic; diff --git a/OpenDreamClient/Input/ContextMenu/ContextMenuItem.xaml.cs b/OpenDreamClient/Input/ContextMenu/ContextMenuItem.xaml.cs index 431bab21e2f..f3cd6feb5cb 100644 --- a/OpenDreamClient/Input/ContextMenu/ContextMenuItem.xaml.cs +++ b/OpenDreamClient/Input/ContextMenu/ContextMenuItem.xaml.cs @@ -1,6 +1,4 @@ -using JetBrains.Annotations; using OpenDreamClient.Rendering; -using OpenDreamShared.Dream; using Robust.Client.AutoGenerated; using Robust.Client.Graphics; using Robust.Client.UserInterface; diff --git a/OpenDreamClient/Input/ContextMenu/VerbMenuPopup.xaml.cs b/OpenDreamClient/Input/ContextMenu/VerbMenuPopup.xaml.cs index ee331fbdc80..9e33a069688 100644 --- a/OpenDreamClient/Input/ContextMenu/VerbMenuPopup.xaml.cs +++ b/OpenDreamClient/Input/ContextMenu/VerbMenuPopup.xaml.cs @@ -1,4 +1,3 @@ -using JetBrains.Annotations; using Robust.Client.AutoGenerated; using Robust.Client.UserInterface.Controls; using Robust.Client.UserInterface.XAML; diff --git a/OpenDreamClient/Interface/Controls/ControlButton.cs b/OpenDreamClient/Interface/Controls/ControlButton.cs index 36f1f5f4847..d2f7687dcc0 100644 --- a/OpenDreamClient/Interface/Controls/ControlButton.cs +++ b/OpenDreamClient/Interface/Controls/ControlButton.cs @@ -1,5 +1,4 @@ -using OpenDreamClient.Input; -using OpenDreamClient.Interface.Descriptors; +using OpenDreamClient.Interface.Descriptors; using Robust.Client.UserInterface; using Robust.Client.UserInterface.Controls; diff --git a/OpenDreamClient/Interface/Controls/ControlInput.cs b/OpenDreamClient/Interface/Controls/ControlInput.cs index 8059555dfb2..e31fb2f0f9b 100644 --- a/OpenDreamClient/Interface/Controls/ControlInput.cs +++ b/OpenDreamClient/Interface/Controls/ControlInput.cs @@ -1,5 +1,4 @@ -using OpenDreamClient.Input; -using OpenDreamClient.Interface.Descriptors; +using OpenDreamClient.Interface.Descriptors; using Robust.Client.UserInterface; using Robust.Client.UserInterface.Controls; diff --git a/OpenDreamClient/Interface/Controls/ControlWindow.cs b/OpenDreamClient/Interface/Controls/ControlWindow.cs index 378f7caaa6e..65060b8b6aa 100644 --- a/OpenDreamClient/Interface/Controls/ControlWindow.cs +++ b/OpenDreamClient/Interface/Controls/ControlWindow.cs @@ -1,5 +1,4 @@ -using OpenDreamClient.Input; -using OpenDreamClient.Interface.Descriptors; +using OpenDreamClient.Interface.Descriptors; using Robust.Client.Graphics; using Robust.Client.UserInterface; using Robust.Client.UserInterface.Controls; diff --git a/OpenDreamClient/Interface/DebugWindows/MacrosWindow.cs b/OpenDreamClient/Interface/DebugWindows/MacrosWindow.cs index 5c5974fa2e6..e859eb2e41e 100644 --- a/OpenDreamClient/Interface/DebugWindows/MacrosWindow.cs +++ b/OpenDreamClient/Interface/DebugWindows/MacrosWindow.cs @@ -1,5 +1,4 @@ -using OpenDreamClient.Input; -using OpenDreamClient.Interface.Prompts; +using OpenDreamClient.Interface.Prompts; using Robust.Client.UserInterface.Controls; using Robust.Shared.Console; diff --git a/OpenDreamClient/Interface/DreamInterfaceManager.cs b/OpenDreamClient/Interface/DreamInterfaceManager.cs index 6110be3052a..3e59616f718 100644 --- a/OpenDreamClient/Interface/DreamInterfaceManager.cs +++ b/OpenDreamClient/Interface/DreamInterfaceManager.cs @@ -1,9 +1,7 @@ using System.IO; using System.Text; using OpenDreamShared.Compiler; -using OpenDreamShared.Dream.Procs; using OpenDreamShared.Network.Messages; -using OpenDreamClient.Input; using OpenDreamClient.Interface.Controls; using OpenDreamClient.Interface.Descriptors; using OpenDreamClient.Interface.DMF; diff --git a/OpenDreamClient/Interface/InterfaceMacro.cs b/OpenDreamClient/Interface/InterfaceMacro.cs index b3f4044ca05..cd579909f0c 100644 --- a/OpenDreamClient/Interface/InterfaceMacro.cs +++ b/OpenDreamClient/Interface/InterfaceMacro.cs @@ -1,5 +1,4 @@ -using OpenDreamClient.Input; -using OpenDreamClient.Interface.Descriptors; +using OpenDreamClient.Interface.Descriptors; using Robust.Client.Input; using Robust.Client.UserInterface; using Robust.Shared.Input; diff --git a/OpenDreamClient/Interface/InterfaceMenu.cs b/OpenDreamClient/Interface/InterfaceMenu.cs index 86caf747458..2105bec6c5b 100644 --- a/OpenDreamClient/Interface/InterfaceMenu.cs +++ b/OpenDreamClient/Interface/InterfaceMenu.cs @@ -1,5 +1,4 @@ -using OpenDreamClient.Input; -using OpenDreamClient.Interface.Descriptors; +using OpenDreamClient.Interface.Descriptors; using Robust.Client.UserInterface.Controls; using Robust.Shared.Serialization.Manager; diff --git a/OpenDreamClient/Rendering/ClientImagesSystem.cs b/OpenDreamClient/Rendering/ClientImagesSystem.cs index 24d8579d6fd..7f3c89a357d 100644 --- a/OpenDreamClient/Rendering/ClientImagesSystem.cs +++ b/OpenDreamClient/Rendering/ClientImagesSystem.cs @@ -1,6 +1,4 @@ using System.Diagnostics.CodeAnalysis; -using System.Linq; -using OpenDreamShared.Dream; using OpenDreamShared.Rendering; using Vector3 = Robust.Shared.Maths.Vector3; diff --git a/OpenDreamRuntime/Input/DreamCommandSystem.cs b/OpenDreamRuntime/Input/DreamCommandSystem.cs index b7b63d4b089..e5dbf776b2d 100644 --- a/OpenDreamRuntime/Input/DreamCommandSystem.cs +++ b/OpenDreamRuntime/Input/DreamCommandSystem.cs @@ -1,5 +1,4 @@ -using OpenDreamShared.Input; -using OpenDreamShared.Network.Messages; +using OpenDreamShared.Network.Messages; using Robust.Server.Player; using Robust.Shared.Network; diff --git a/OpenDreamRuntime/LocalHostConGroup.cs b/OpenDreamRuntime/LocalHostConGroup.cs index 30ae05fcc5c..6b911768123 100644 --- a/OpenDreamRuntime/LocalHostConGroup.cs +++ b/OpenDreamRuntime/LocalHostConGroup.cs @@ -1,3 +1,4 @@ +#if DEBUG using Robust.Server.Console; using Robust.Server.Player; using System.Net; @@ -5,6 +6,7 @@ using Robust.Shared.Players; using Robust.Shared.Toolshed; using Robust.Shared.Toolshed.Errors; +#endif namespace OpenDreamRuntime { #if DEBUG diff --git a/OpenDreamRuntime/Procs/DebugAdapter/Protocol/ExceptionBreakMode.cs b/OpenDreamRuntime/Procs/DebugAdapter/Protocol/ExceptionBreakMode.cs index d7570a88c8a..e50bfc92d29 100644 --- a/OpenDreamRuntime/Procs/DebugAdapter/Protocol/ExceptionBreakMode.cs +++ b/OpenDreamRuntime/Procs/DebugAdapter/Protocol/ExceptionBreakMode.cs @@ -1,5 +1,3 @@ -using System.Text.Json.Serialization; - namespace OpenDreamRuntime.Procs.DebugAdapter.Protocol; public enum ExceptionBreakMode { diff --git a/OpenDreamRuntime/Procs/DebugAdapter/Protocol/RequestStackTrace.cs b/OpenDreamRuntime/Procs/DebugAdapter/Protocol/RequestStackTrace.cs index 5505e67b3d0..995fef7e523 100644 --- a/OpenDreamRuntime/Procs/DebugAdapter/Protocol/RequestStackTrace.cs +++ b/OpenDreamRuntime/Procs/DebugAdapter/Protocol/RequestStackTrace.cs @@ -1,4 +1,3 @@ -using System.Linq; using System.Text.Json.Serialization; namespace OpenDreamRuntime.Procs.DebugAdapter.Protocol; diff --git a/OpenDreamRuntime/Procs/DreamEnumerators.cs b/OpenDreamRuntime/Procs/DreamEnumerators.cs index 38b424e6409..d4177d819ee 100644 --- a/OpenDreamRuntime/Procs/DreamEnumerators.cs +++ b/OpenDreamRuntime/Procs/DreamEnumerators.cs @@ -1,5 +1,4 @@ using OpenDreamRuntime.Objects; -using OpenDreamShared.Dream.Procs; namespace OpenDreamRuntime.Procs { public interface IDreamValueEnumerator { diff --git a/OpenDreamRuntime/Procs/Native/DreamProcNativeHelpers.cs b/OpenDreamRuntime/Procs/Native/DreamProcNativeHelpers.cs index 8cf81688055..ecbda5ff091 100644 --- a/OpenDreamRuntime/Procs/Native/DreamProcNativeHelpers.cs +++ b/OpenDreamRuntime/Procs/Native/DreamProcNativeHelpers.cs @@ -1,5 +1,4 @@ -using System.Runtime.CompilerServices; -using OpenDreamRuntime.Objects; +using OpenDreamRuntime.Objects; using OpenDreamShared.Dream; using System.Text.RegularExpressions; using OpenDreamRuntime.Objects.Types; diff --git a/OpenDreamRuntime/Rendering/ServerClientImagesSystem.cs b/OpenDreamRuntime/Rendering/ServerClientImagesSystem.cs index 95b312d8759..5da3babaf09 100644 --- a/OpenDreamRuntime/Rendering/ServerClientImagesSystem.cs +++ b/OpenDreamRuntime/Rendering/ServerClientImagesSystem.cs @@ -1,8 +1,5 @@ using OpenDreamRuntime.Objects.Types; using OpenDreamShared.Rendering; -using OpenDreamShared.Dream; -using Robust.Server.GameStates; -using Robust.Server.Player; using OpenDreamRuntime.Objects; using Vector3 = Robust.Shared.Maths.Vector3; diff --git a/OpenDreamShared/Dream/Procs/ProcAttributes.cs b/OpenDreamShared/Dream/Procs/ProcAttributes.cs index ab91d39c50f..18435063d59 100644 --- a/OpenDreamShared/Dream/Procs/ProcAttributes.cs +++ b/OpenDreamShared/Dream/Procs/ProcAttributes.cs @@ -1,5 +1,4 @@ using System; -using System.ComponentModel; namespace OpenDreamShared.Dream.Procs; diff --git a/OpenDreamShared/Network/Messages/MsgLoadInterface.cs b/OpenDreamShared/Network/Messages/MsgLoadInterface.cs index a25ea3cd20a..9d34a9d41da 100644 --- a/OpenDreamShared/Network/Messages/MsgLoadInterface.cs +++ b/OpenDreamShared/Network/Messages/MsgLoadInterface.cs @@ -1,5 +1,4 @@ -using System; -using Lidgren.Network; +using Lidgren.Network; using Robust.Shared.Network; using Robust.Shared.Serialization; diff --git a/OpenDreamShared/Rendering/SharedClientImagesSystem.cs b/OpenDreamShared/Rendering/SharedClientImagesSystem.cs index eb709f4f37d..c1505ad822d 100644 --- a/OpenDreamShared/Rendering/SharedClientImagesSystem.cs +++ b/OpenDreamShared/Rendering/SharedClientImagesSystem.cs @@ -1,5 +1,4 @@ -using OpenDreamShared.Dream; -using Robust.Shared.Analyzers; +using Robust.Shared.Analyzers; using Robust.Shared.GameObjects; using Robust.Shared.Maths; using Robust.Shared.Serialization; diff --git a/OpenDreamShared/SharedOpenDreamIoC.cs b/OpenDreamShared/SharedOpenDreamIoC.cs index 09438ff4872..82c6934b59e 100644 --- a/OpenDreamShared/SharedOpenDreamIoC.cs +++ b/OpenDreamShared/SharedOpenDreamIoC.cs @@ -1,6 +1,3 @@ -using System; -using Robust.Shared.ContentPack; - namespace OpenDreamShared { public static class SharedOpenDreamIoC { public static void Register() {