Skip to content

Commit

Permalink
Merge pull request #110 from WildernessLabs/develop
Browse files Browse the repository at this point in the history
Merge to main for 2.0.0 release
  • Loading branch information
adrianstevens authored Jan 21, 2025
2 parents d7d6f7c + 60f94c8 commit 990fa72
Show file tree
Hide file tree
Showing 16 changed files with 305 additions and 167 deletions.
34 changes: 23 additions & 11 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: VSCode Extension
env:
IDE_TOOLS_RELEASE_VERSION: 1.9.7
IDE_TOOLS_RELEASE_VERSION: 2.0.0

on:
push:
Expand All @@ -18,46 +18,58 @@ jobs:

steps:
- name: Checkout current repo
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
path: main
submodules: true

- if: ${{ github.ref == 'refs/heads/main' }}
name: Checkout Meadow.CLI.Core side-by-side
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: WildernessLabs/Meadow.CLI
path: Meadow.CLI
ref: main

- if: ${{ github.ref != 'refs/heads/main' }}
name: Checkout Meadow.CLI.Core side-by-side
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: WildernessLabs/Meadow.CLI
path: Meadow.CLI
ref: develop

- name: Checkout Meadow.Contracts side-by-side
uses: actions/checkout@v4
with:
repository: WildernessLabs/Meadow.Contracts
path: Meadow.Contracts
ref: main

- name: Setup .NET 8.0.x
uses: actions/setup-dotnet@v3
uses: actions/setup-dotnet@v4
with:
dotnet-version: |
8.0.x
- name: Setup Nuget
uses: Nuget/setup-nuget@v1.0.5
uses: Nuget/setup-nuget@v2

- name: Setup Node.js 16
uses: actions/setup-node@v3
- name: Setup Node.js 20
uses: actions/setup-node@v4
with:
node-version: 16
node-version: 20

- name: Install vsce
run: |
npm i -g @vscode/vsce
npm i -g @vscode/debugprotocol
- name: Install FallBack Sources
run: |
nuget install Microsoft.SymbolStore -Version 1.0.411401 -FallbackSource "https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-tools/nuget/v3/index.json"
# May not be needed for now, but keeping it around nuget install Microsoft.FileFormats -Version 1.0.411401 -FallbackSource "https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-tools/nuget/v3/index.json"

- if: ${{ github.event_name == 'workflow_dispatch' }}
name: Update VSCode Version Numbers
run: |
Expand Down Expand Up @@ -93,14 +105,14 @@ jobs:
vsce package
- name: Upload VSIX Artifacts
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: VSCodeMeadow.vsix.${{ ENV.IDE_TOOLS_RELEASE_VERSION }}
path: 'main/*.vsix'

- name: Upload Binlog Artifacts
if: always()
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: BinLogs
path: '**/*.binlog'
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,7 @@ You can also use the following short-cut on:
### Prerequisites
- Install Python
- Install NPM
Then run the following commands on the command line, once NPM is installed
Expand Down
2 changes: 1 addition & 1 deletion externals/debugger-libs
Submodule debugger-libs updated 57 files
+7 −0 Directory.Build.props
+4 −1 Mono.Debugger.Soft/Mono.Debugger.Soft.csproj
+55 −5 Mono.Debugger.Soft/Mono.Debugger.Soft/AssemblyMirror.cs
+264 −110 Mono.Debugger.Soft/Mono.Debugger.Soft/Connection.cs
+0 −1 Mono.Debugger.Soft/Mono.Debugger.Soft/EncEvents.cs
+2 −2 Mono.Debugger.Soft/Mono.Debugger.Soft/EventRequest.cs
+5 −2 Mono.Debugger.Soft/Mono.Debugger.Soft/Location.cs
+67 −8 Mono.Debugger.Soft/Mono.Debugger.Soft/MethodMirror.cs
+1 −1 Mono.Debugger.Soft/Mono.Debugger.Soft/ModuleMirror.cs
+9 −4 Mono.Debugger.Soft/Mono.Debugger.Soft/ObjectMirror.cs
+6 −1 Mono.Debugger.Soft/Mono.Debugger.Soft/StackFrame.cs
+1 −1 Mono.Debugger.Soft/Mono.Debugger.Soft/StepEventRequest.cs
+10 −0 Mono.Debugger.Soft/Mono.Debugger.Soft/StructMirror.cs
+62 −20 Mono.Debugger.Soft/Mono.Debugger.Soft/TypeMirror.cs
+17 −3 Mono.Debugger.Soft/Mono.Debugger.Soft/VirtualMachine.cs
+3 −1 Mono.Debugger.Soft/Mono.Debugger.Soft/VirtualMachineManager.cs
+37 −0 Mono.Debugging.Soft/ArrayAdaptor.cs
+299 −0 Mono.Debugging.Soft/DebugSymbolsManager.cs
+3 −3 Mono.Debugging.Soft/Mono.Debugging.Soft.csproj
+75 −1 Mono.Debugging.Soft/PortablePdbData.cs
+9 −2 Mono.Debugging.Soft/SoftDebuggerAdaptor.cs
+85 −8 Mono.Debugging.Soft/SoftDebuggerBacktrace.cs
+347 −243 Mono.Debugging.Soft/SoftDebuggerSession.cs
+7 −0 Mono.Debugging.Soft/nuget.config
+133 −0 Mono.Debugging/Mono.Debugging.Client/Assembly.cs
+11 −0 Mono.Debugging/Mono.Debugging.Client/AssemblyEventArgs.cs
+7 −0 Mono.Debugging/Mono.Debugging.Client/Backtrace.cs
+2 −1 Mono.Debugging/Mono.Debugging.Client/BreakEvent.cs
+2 −0 Mono.Debugging/Mono.Debugging.Client/BreakEventInfo.cs
+3 −1 Mono.Debugging/Mono.Debugging.Client/Breakpoint.cs
+110 −78 Mono.Debugging/Mono.Debugging.Client/BreakpointStore.cs
+11 −0 Mono.Debugging/Mono.Debugging.Client/Catchpoint.cs
+136 −122 Mono.Debugging/Mono.Debugging.Client/DebuggerSession.cs
+23 −1 Mono.Debugging/Mono.Debugging.Client/DebuggerSessionOptions.cs
+50 −6 Mono.Debugging/Mono.Debugging.Client/FunctionBreakpoint.cs
+10 −2 Mono.Debugging/Mono.Debugging.Client/ProcessInfo.cs
+4 −2 Mono.Debugging/Mono.Debugging.Client/SourceLink.cs
+24 −4 Mono.Debugging/Mono.Debugging.Client/StackFrame.cs
+50 −609 Mono.Debugging/Mono.Debugging.Evaluation/LambdaBodyOutputVisitor.cs
+13 −14 Mono.Debugging/Mono.Debugging.Evaluation/NRefactoryExpressionEvaluator.cs
+364 −824 Mono.Debugging/Mono.Debugging.Evaluation/NRefactoryExpressionEvaluatorVisitor.cs
+34 −40 Mono.Debugging/Mono.Debugging.Evaluation/NRefactoryExpressionResolverVisitor.cs
+97 −67 Mono.Debugging/Mono.Debugging.Evaluation/NRefactoryExtensions.cs
+2 −1 Mono.Debugging/Mono.Debugging.Evaluation/RemoteFrameObject.cs
+9 −7 Mono.Debugging/Mono.Debugging.csproj
+1 −0 NuGet.config
+1 −1 UnitTests/Mono.Debugging.Tests/Shared/AdvancedEvaluationTests.cs
+61 −7 UnitTests/Mono.Debugging.Tests/Shared/BreakpointsAndSteppingTests.cs
+1 −1 UnitTests/Mono.Debugging.Tests/Shared/CodeCompletionTests.cs
+17 −5 UnitTests/Mono.Debugging.Tests/Shared/DebugTests.cs
+2 −2 UnitTests/Mono.Debugging.Tests/Shared/DebuggerSessionTests.cs
+1 −1 UnitTests/Mono.Debugging.Tests/Shared/EvaluationTests.cs
+1 −1 UnitTests/Mono.Debugging.Tests/Shared/StackFrameTests.cs
+24 −0 UnitTests/MonoDevelop.Debugger.Tests.TestApp/BreakpointsAndStepping.cs
+11 −0 UnitTests/MonoDevelop.Debugger.Tests.TestApp/Logging.cs
+1 −0 UnitTests/MonoDevelop.Debugger.Tests.TestApp/MonoDevelop.Debugger.Tests.TestApp.csproj
+2 −1 UnitTests/MonoDevelop.Debugger.Tests.TestAppCore/MonoDevelop.Debugger.Tests.TestAppCore.csproj
23 changes: 12 additions & 11 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 2 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "meadow",
"displayName": "VSCode Tools For Meadow",
"version": "1.9.7",
"version": "2.0.0",
"publisher": "WildernessLabs",
"description": "Build, Debug and Deploy Meadow applications",
"icon": "meadow.png",
Expand Down Expand Up @@ -56,14 +56,13 @@
"ts-loader": "^9.4.2",
"typescript": "^4.2.2",
"vscode-nls-dev": "^4.0.3",
"webpack": "^5.76.0",
"webpack": ">=5.94.0",
"webpack-cli": "^5.0.0"
},
"main": "./dist/extension",
"activationEvents": [
"onStartupFinished",
"onDebug",
"onCommand:extension.meadow.configureExceptions",
"onCommand:extension.meadow.startSession"
],
"contributes": {
Expand Down
49 changes: 35 additions & 14 deletions src/VSCodeMeadow.sln
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,6 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "debugger", "debugger", "{DD
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Meadow", "Meadow", "{639FE3D4-9D7F-4823-9911-48FE49C6998F}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Meadow.Hcom.6.0.0", "..\..\Meadow.CLI\Meadow.Hcom\Meadow.Hcom.6.0.0.csproj", "{5F0219BE-F626-4C90-89B0-202850AE43C5}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Meadow.CLI.Core.6.0.0", "..\..\Meadow.CLI\Meadow.CLI.Core\Meadow.CLI.Core.6.0.0.csproj", "{21E7E61E-D9CE-48E2-B1DA-52B5FC12015A}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "VSCodeMeadow", "csharp\VSCodeMeadow.csproj", "{D46A8779-DAE7-4B90-ACBA-08893A504193}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Mono.Debugging", "..\externals\debugger-libs\Mono.Debugging\Mono.Debugging.csproj", "{CD6FED13-1984-4491-97AB-1A4361E1F582}"
Expand All @@ -18,20 +14,22 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Mono.Debugger.Soft", "..\ex
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Mono.Debugging.Soft", "..\externals\debugger-libs\Mono.Debugging.Soft\Mono.Debugging.Soft.csproj", "{7592E68B-CE43-4433-8B5A-F7890BAA2ABC}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.HCom", "..\..\Meadow.CLI\Source\v2\Meadow.HCom\Meadow.HCom.csproj", "{7F1115C6-5081-4997-AC0F-789D95B5092C}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.Tooling.Core", "..\..\Meadow.CLI\Source\v2\Meadow.Tooling.Core\Meadow.Tooling.Core.csproj", "{AF35343B-B97C-4300-9EB4-DE753CADDC13}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.Linker", "..\..\Meadow.CLI\Source\v2\Meadow.Linker\Meadow.Linker.csproj", "{B11B8D26-FE98-4BD7-875E-D5A0801D3415}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.SoftwareManager", "..\..\Meadow.CLI\Source\v2\Meadow.SoftwareManager\Meadow.SoftwareManager.csproj", "{CC5D6AA6-F58A-4B8B-A514-988BCAEA21EE}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.Cloud.Client", "..\..\Meadow.CLI\Source\v2\Meadow.Cloud.Client\Meadow.Cloud.Client.csproj", "{7820644F-8B87-4864-81B4-A8CB5859A71C}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{5F0219BE-F626-4C90-89B0-202850AE43C5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{5F0219BE-F626-4C90-89B0-202850AE43C5}.Debug|Any CPU.Build.0 = Debug|Any CPU
{5F0219BE-F626-4C90-89B0-202850AE43C5}.Release|Any CPU.ActiveCfg = Release|Any CPU
{5F0219BE-F626-4C90-89B0-202850AE43C5}.Release|Any CPU.Build.0 = Release|Any CPU
{21E7E61E-D9CE-48E2-B1DA-52B5FC12015A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{21E7E61E-D9CE-48E2-B1DA-52B5FC12015A}.Debug|Any CPU.Build.0 = Debug|Any CPU
{21E7E61E-D9CE-48E2-B1DA-52B5FC12015A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{21E7E61E-D9CE-48E2-B1DA-52B5FC12015A}.Release|Any CPU.Build.0 = Release|Any CPU
{D46A8779-DAE7-4B90-ACBA-08893A504193}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{D46A8779-DAE7-4B90-ACBA-08893A504193}.Debug|Any CPU.Build.0 = Debug|Any CPU
{D46A8779-DAE7-4B90-ACBA-08893A504193}.Release|Any CPU.ActiveCfg = Release|Any CPU
Expand All @@ -48,16 +46,39 @@ Global
{7592E68B-CE43-4433-8B5A-F7890BAA2ABC}.Debug|Any CPU.Build.0 = Debug|Any CPU
{7592E68B-CE43-4433-8B5A-F7890BAA2ABC}.Release|Any CPU.ActiveCfg = Release|Any CPU
{7592E68B-CE43-4433-8B5A-F7890BAA2ABC}.Release|Any CPU.Build.0 = Release|Any CPU
{7F1115C6-5081-4997-AC0F-789D95B5092C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{7F1115C6-5081-4997-AC0F-789D95B5092C}.Debug|Any CPU.Build.0 = Debug|Any CPU
{7F1115C6-5081-4997-AC0F-789D95B5092C}.Release|Any CPU.ActiveCfg = Release|Any CPU
{7F1115C6-5081-4997-AC0F-789D95B5092C}.Release|Any CPU.Build.0 = Release|Any CPU
{AF35343B-B97C-4300-9EB4-DE753CADDC13}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{AF35343B-B97C-4300-9EB4-DE753CADDC13}.Debug|Any CPU.Build.0 = Debug|Any CPU
{AF35343B-B97C-4300-9EB4-DE753CADDC13}.Release|Any CPU.ActiveCfg = Release|Any CPU
{AF35343B-B97C-4300-9EB4-DE753CADDC13}.Release|Any CPU.Build.0 = Release|Any CPU
{B11B8D26-FE98-4BD7-875E-D5A0801D3415}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{B11B8D26-FE98-4BD7-875E-D5A0801D3415}.Debug|Any CPU.Build.0 = Debug|Any CPU
{B11B8D26-FE98-4BD7-875E-D5A0801D3415}.Release|Any CPU.ActiveCfg = Release|Any CPU
{B11B8D26-FE98-4BD7-875E-D5A0801D3415}.Release|Any CPU.Build.0 = Release|Any CPU
{CC5D6AA6-F58A-4B8B-A514-988BCAEA21EE}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{CC5D6AA6-F58A-4B8B-A514-988BCAEA21EE}.Debug|Any CPU.Build.0 = Debug|Any CPU
{CC5D6AA6-F58A-4B8B-A514-988BCAEA21EE}.Release|Any CPU.ActiveCfg = Release|Any CPU
{CC5D6AA6-F58A-4B8B-A514-988BCAEA21EE}.Release|Any CPU.Build.0 = Release|Any CPU
{7820644F-8B87-4864-81B4-A8CB5859A71C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{7820644F-8B87-4864-81B4-A8CB5859A71C}.Debug|Any CPU.Build.0 = Debug|Any CPU
{7820644F-8B87-4864-81B4-A8CB5859A71C}.Release|Any CPU.ActiveCfg = Release|Any CPU
{7820644F-8B87-4864-81B4-A8CB5859A71C}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{5F0219BE-F626-4C90-89B0-202850AE43C5} = {639FE3D4-9D7F-4823-9911-48FE49C6998F}
{21E7E61E-D9CE-48E2-B1DA-52B5FC12015A} = {639FE3D4-9D7F-4823-9911-48FE49C6998F}
{CD6FED13-1984-4491-97AB-1A4361E1F582} = {DD5D7FCB-5097-433E-8399-BB037883FB2F}
{8D8752AF-06C6-40CE-AA55-B454DD6808E1} = {DD5D7FCB-5097-433E-8399-BB037883FB2F}
{7592E68B-CE43-4433-8B5A-F7890BAA2ABC} = {DD5D7FCB-5097-433E-8399-BB037883FB2F}
{7F1115C6-5081-4997-AC0F-789D95B5092C} = {639FE3D4-9D7F-4823-9911-48FE49C6998F}
{AF35343B-B97C-4300-9EB4-DE753CADDC13} = {639FE3D4-9D7F-4823-9911-48FE49C6998F}
{B11B8D26-FE98-4BD7-875E-D5A0801D3415} = {639FE3D4-9D7F-4823-9911-48FE49C6998F}
{CC5D6AA6-F58A-4B8B-A514-988BCAEA21EE} = {639FE3D4-9D7F-4823-9911-48FE49C6998F}
{7820644F-8B87-4864-81B4-A8CB5859A71C} = {639FE3D4-9D7F-4823-9911-48FE49C6998F}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {C0062C7F-7F87-41DC-9A63-BE15C14E7A43}
Expand Down
10 changes: 10 additions & 0 deletions src/csharp/DebugSession.cs
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,16 @@ public MeadowOutputEvent(string outpt)
{ }
}

public class UpdateProgressBarEvent : Event
{
public UpdateProgressBarEvent(string fileName, uint percent)
: base("updateProgressBar", new {
filename = fileName,
percentage = percent
})
{
}
}
// ---- Response -------------------------------------------------------------------------

public class Capabilities : ResponseBody {
Expand Down
34 changes: 30 additions & 4 deletions src/csharp/Meadow/DebugSessionLogger.cs
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
using System;
using System.Threading.Tasks;
using Microsoft.Extensions.Logging;

namespace VsCodeMeadowUtil
{
public class DebugSessionLogger : ILogger
{
string previousFileName = string.Empty;
uint previousPercentage = 0;

public DebugSessionLogger(Action<string> callback)
{
Callback = callback;
Expand All @@ -20,13 +24,35 @@ public bool IsEnabled(LogLevel logLevel)
if (System.Diagnostics.Debugger.IsAttached)
return true;

return logLevel == LogLevel.Information;
return logLevel >= LogLevel.Information;
}

public void Log<TState>(LogLevel logLevel, EventId eventId, TState state, Exception exception, Func<TState, Exception, string> formatter)
{
if (logLevel == LogLevel.Information || logLevel == LogLevel.Error || logLevel == LogLevel.Warning)
Callback?.Invoke(formatter(state, exception)?.Trim());
if (IsEnabled(logLevel))
{
Callback?.Invoke(formatter(state, exception));
}
}

internal async Task ReportDeviceMessage(string source, string message)
{
this.LogInformation($"{source}: {message}");
}

internal async Task ReportFileProgress(string fileName, uint percentage)
{
if (percentage > 0
&& percentage > 99)
{
if (!previousFileName.Equals(fileName)
|| !previousPercentage.Equals(percentage))
{
this.LogInformation($"{percentage}% of '{fileName}' Sent");
previousFileName = fileName;
previousPercentage = percentage;
}
}
}
}
}
}
Loading

0 comments on commit 990fa72

Please sign in to comment.