Skip to content

Conversation

@Numpsy
Copy link
Contributor

@Numpsy Numpsy commented Oct 19, 2025

refs ionide/ionide-vscode-fsharp#2107

An attempt at making it return the projects inside their solution folders, rather than along side them, by making it work more like v0.68.0 did (I created the new unit test by writing the test in the 0.68.0 version on the assumption that's returning the strucuture that Ionide expected, then moving the test to the latest source and changing the code to match.)

Possibly this still needs more tests adding (maybe both a sln and a slnx file to make sure they behave the same, and maybe multipe layers of nested subfolders rather than just one)

I also haven't tested this within Ionide yet - just the unit tests so far.

)
|> Seq.map parseFolder

// 'SolutionItems' contains all of SolutionFolders and SolutionProjects, so only include things that aren't in those to avoid duplication
Copy link
Contributor Author

@Numpsy Numpsy Oct 19, 2025

Choose a reason for hiding this comment

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

When testing I noticed that some solution items are being returned twice here, which didn't seem right (note the duplicated guids in the results, with different Kinds)

image

Looks to be because 'SolutionItems' contains all the folders and so the existing logic will include any root level folders as 'Unknown' as well as including them as folders

@Numpsy Numpsy force-pushed the nested_projects_2 branch from 954a2f9 to 335378d Compare October 26, 2025 11:21
@Numpsy
Copy link
Contributor Author

Numpsy commented Oct 26, 2025

Updated based on comments in ionide/ionide-vscode-fsharp#2109 about returning the solution folders before the solution level projects.

Still needs a bit more testing with the interaction between solution filters and folders (what should happen with folders that have all their contents filtered out etc)

@Numpsy
Copy link
Contributor Author

Numpsy commented Oct 26, 2025

Ionide currently displays the proj-info solution like this

image

and after this change that becomes

image

Visual Studio 2022 shows this for comparison:

image

@Numpsy
Copy link
Contributor Author

Numpsy commented Oct 26, 2025

Still needs a bit more testing with the interaction between solution filters and folders (what should happen with folders that have all their contents filtered out etc)

It looks like if you have

  • A solution with nested solution folders, with projects at each level
  • A solution filter that doesn't include the projects at the bottom of the folder tree

Then Visual Studio doesn't display the empty folders, but Ionide does,
Hoever, maybe this is a seperate bug, and I'm not sure if proj-info should filter out such folders here, or if something higher up should do it?

@Numpsy Numpsy changed the title Further tweaks to solution file parsing to better handle projects inside solution folders. Change solution file parsing to report the structure of folders/projects, rather than returning projects as a flat list Nov 16, 2025
@Numpsy
Copy link
Contributor Author

Numpsy commented Nov 16, 2025

Still needs a bit more testing with the interaction between solution filters and folders (what should happen with folders that have all their contents filtered out etc)

It looks like if you have

* A solution with nested solution folders, with projects at each level

* A solution filter that doesn't include the projects at the bottom of the folder tree

Then Visual Studio doesn't display the empty folders, but Ionide does, Hoever, maybe this is a seperate bug, and I'm not sure if proj-info should filter out such folders here, or if something higher up should do it?

Opened #242 just for the filtering question, to leave this one just for the folder structure changes

@Numpsy Numpsy marked this pull request as ready for review November 17, 2025 11:53
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.

1 participant