Skip to content

Conversation

@cartermp
Copy link
Contributor

It was bothering me that there were live code paths in the FSharp.LanguageService project necessary for .NET Core SDK-based project support. I moved those code paths into the FSharp.Editor project, keeping the old one intact and modifying a few things to disambiguate types. We still have a bundle of spaghetti for project references, but at least this is one less set of code paths in FSharp.Language which won't be executed on peoples' machines.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I have no idea what this is, but it was added.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I don't think any of this is necessary. After commenting this out, it builds, and the VSIX that I installed into my VS appears to work.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I have no clue why the full version and stuff was specified, but this was just through right-click > add reference.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think I figured out how to deal with this

@cartermp cartermp changed the title [WIP] Move ProjectSitesAndFiles to FSharp.Editor Move ProjectSitesAndFiles to FSharp.Editor Dec 13, 2017
@cartermp
Copy link
Contributor Author

cartermp commented Dec 13, 2017

Assuming this passes CI, I think this is ready. I'm still manually testing it, but the following seems to work just like the current tools:

  • project creation
  • project to project references
  • adding files and script files
  • ordering in the project
  • editor behavior with all of the above

So I don't think I missed anything. Still, it would be nice to have at least another person try this out.

@cartermp
Copy link
Contributor Author

All of the above testing also works for .NET Core SDK projects.

@KevinRansom
Copy link
Contributor

Is the purpose of this to eliminate the Language Service dll? If yes, how much work is needed to complete that? or can we just delete it all now?

@cartermp
Copy link
Contributor Author

cartermp commented Dec 13, 2017

This is a step in that direction, yes. I'm currently looking to do that right now, and there are a few more things which would need moving over. The File System completion logic in LanguageService.Base (ported from Roslyn) is currently blocking removal of dependencies on LanguageService.dll and LanguageService.Base.dll.

@KevinRansom
Copy link
Contributor

When do you plan on completing it? Christmas, VS 15.6, 2020, or the heat death of the Sun :-) ?
And are we certain that the FSharp.Editor dll is the right home for this ?

Kevin

@cartermp
Copy link
Contributor Author

cartermp commented Dec 13, 2017

Probably by christmas, but I made this PR as-is so that it can be merged if I can't get it decoupled in time.

And yes, FSharp.Editor is the right location for now. Once we are no longer referencing these projects which are basically just dead code paths, we can start to migrate tests over to no longer use those code paths. Then, finally, we can delete the dead code. It's a long-term effort that I want to personally start addressing. This is one of the steps in that process.

@cartermp
Copy link
Contributor Author

And as it turns out, there was just one tiny thing to move over from the FSharp.LanguageService project. Dependency on it is now gone!

@cartermp
Copy link
Contributor Author

This is ready, but as always, I welcome any additional testing.

Copy link
Contributor

@KevinRansom KevinRansom left a comment

Choose a reason for hiding this comment

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

Looks good.

@cartermp cartermp changed the title Move ProjectSitesAndFiles to FSharp.Editor Move ProjectSitesAndFiles to FSharp.Editor and remove dependency on FSharp.LanguageService Dec 14, 2017
<Name>FSharp.Core</Name>
</ProjectReference>
<ProjectReference Include="$(FSharpSourcesRoot)\..\vsintegration\src\FSharp.LanguageService\FSharp.LanguageService.fsproj">
<!-- <ProjectReference Include="$(FSharpSourcesRoot)\..\vsintegration\src\FSharp.LanguageService\FSharp.LanguageService.fsproj">
Copy link
Contributor

@dsyme dsyme Dec 15, 2017

Choose a reason for hiding this comment

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

just delete this

Copy link
Contributor Author

Choose a reason for hiding this comment

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

whoops, forgot that.

@cartermp cartermp changed the title Move ProjectSitesAndFiles to FSharp.Editor and remove dependency on FSharp.LanguageService Remove dependency on FSharp.LanguageService Dec 16, 2017
@cartermp cartermp merged commit 351d06b into dotnet:master Dec 17, 2017
@cartermp cartermp deleted the move-projectsitesandfiles branch December 17, 2017 00:16
@TIHan
Copy link
Contributor

TIHan commented Dec 17, 2017

@cartermp This completely breaks legacy projects from having any tooling. What is your plan for fixing that bit?

@cartermp cartermp restored the move-projectsitesandfiles branch December 17, 2017 05:44
@cartermp
Copy link
Contributor Author

Alright I've gaslit myself:

  • Found the .NET Framework project I used to test this against
  • Source files are plaintext as of this change, even if I re-add the reference to the old project
  • Script files are fine
  • .NET Core SDK-based files are fine

And yet I spent at least 30 minutes on a built VSIX of this PR verifying that nothing was broken for both project flavors.

Time to revert this and wonder what the hell is going on in this untested code

nosami pushed a commit to xamarin/visualfsharp that referenced this pull request Jan 26, 2022
* Move ProjectSitesAndFiles to FSharp.Editor

* Remove commented out code

* Fix build that wasn't reported when running build.cmd

* Remove weird stuff and add the VSLang proj reference like it is in FSharp.LanguageService

* Remove dependency on FSharp.LanguageService

* remove commented out reference
nosami pushed a commit to xamarin/visualfsharp that referenced this pull request Jan 26, 2022
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.

4 participants