Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Jan 29, 2026

Description

The process_monitor executable project was missing from ntosebpfext.sln while its library and test projects were included, preventing process_monitor.exe from being built by msbuild ntosebpfext.sln. Additionally, initialize_repo.ps1 only ran nuget restore (for C++ projects) but not dotnet restore (required for .NET SDK-style projects).

Changes:

  • Added tools\process_monitor\process_monitor.csproj to solution under Tools folder with proper platform configurations
  • Added dotnet restore ntosebpfext.sln to initialize_repo.ps1 after the nuget restore step
  • Fixed process_monitor.csproj to include missing Import statement for $(SolutionDir)\ntosebpfext.props and explicit version 9.0.0 for Microsoft.Extensions.Logging.Console package reference to resolve CI build errors

Testing

No new tests needed. Verified project is correctly included in solution and can be restored via dotnet restore. CI builds now pass successfully.

Documentation

No documentation changes required.

Installation

No installer impact.

Original prompt

This section details on the original issue you should resolve

<issue_title>Add process_monitor project to solution and fix initialize_repo.ps1</issue_title>
<issue_description>## Summary

The process_monitor .NET project (tools/process_monitor/process_monitor.csproj) is not included in ntosebpfext.sln, so it doesn't get built when running msbuild ntosebpfext.sln. Additionally, scripts/initialize_repo.ps1 is missing a dotnet restore step needed for the .NET projects.

Current State

  1. Missing from solution: process_monitor.csproj exists but is not in ntosebpfext.sln

    • process_monitor.Library and process_monitor.Tests ARE in the solution
    • The main executable project is missing
  2. Missing dotnet restore: initialize_repo.ps1 runs nuget restore (for C++ projects) but not dotnet restore (needed for .NET SDK-style projects)

Proposed Changes

  1. Add process_monitor.csproj to ntosebpfext.sln under the Tools folder

  2. Add dotnet restore ntosebpfext.sln to scripts/initialize_repo.ps1 after the nuget restore step:
    \\powershell
    \ = @(
    "git submodule update --init --recursive",
    "cmake -G 'Visual Studio 17 2022' -S external\catch2 -B external\catch2\build -DBUILD_TESTING=OFF",
    "nuget restore ntosebpfext.sln",
    "dotnet restore ntosebpfext.sln", # Add this line
    ".\packages\eBPF-for-Windows.x64.1.0.0-rc1\build\native\bin\export_program_info.exe"
    )
    \\

Context

This was discovered while reviewing PR #292 - the documentation states that process_monitor.exe is generated by the msbuild command, but it currently is not.</issue_description>

Comments on the Issue (you are @copilot in this section)


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Co-authored-by: Alan-Jowett <20480683+Alan-Jowett@users.noreply.github.com>
Copilot AI changed the title [WIP] Add process_monitor project to solution and fix initialize_repo.ps1 Add process_monitor project to solution and fix initialize_repo.ps1 Jan 29, 2026
Copilot AI requested a review from Alan-Jowett January 29, 2026 18:55
@Alan-Jowett
Copy link
Member

@copilot the ci is failing

… package version

Co-authored-by: Alan-Jowett <20480683+Alan-Jowett@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Jan 29, 2026

@copilot the ci is failing

Fixed in commit 931eb91. The build was failing because process_monitor.csproj was missing:

  1. Import of $(SolutionDir)\ntosebpfext.props
  2. Explicit version for Microsoft.Extensions.Logging.Console package reference

These were causing the ConsoleFormatter type to not be found during compilation.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR ensures the process_monitor executable is built as part of the main solution and that repository initialization correctly restores .NET dependencies for SDK-style projects.

Changes:

  • Added tools\process_monitor\process_monitor.csproj to ntosebpfext.sln under the Tools solution folder with appropriate configuration/platform mappings.
  • Updated tools/process_monitor/process_monitor.csproj to import ntosebpfext.props and explicitly pin Microsoft.Extensions.Logging.Console to version 9.0.0, matching related projects.
  • Extended scripts/initialize_repo.ps1 to run dotnet restore ntosebpfext.sln after nuget restore to correctly restore SDK-style .NET projects.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
tools/process_monitor/process_monitor.csproj Aligns the executable project with shared build settings and pins logging dependency version for consistent restore/build.
scripts/initialize_repo.ps1 Ensures .NET SDK-style projects in the solution are restored during repo initialization.
ntosebpfext.sln Adds the process_monitor executable project under the Tools folder with consistent configuration and nesting metadata so it builds with the solution.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add process_monitor project to solution and fix initialize_repo.ps1

2 participants