Skip to content

Commit

Permalink
add proto and path checks
Browse files Browse the repository at this point in the history
  • Loading branch information
saranshsaini committed Sep 16, 2024
1 parent 0de7a6b commit 8a8a795
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
6 changes: 3 additions & 3 deletions CodeiumVS/LanguageServer/LanguageServer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -738,10 +738,10 @@ private async Task InitializeTrackedWorkspaceAsync()
{
try
{
string projectDir = Path.GetDirectoryName(project.FullName);
await _package.LogAsync($"Project Dir: {projectDir}");
if (!string.IsNullOrEmpty(projectDir))
if (!string.IsNullOrEmpty(project.FullName))
{
string projectDir = Path.GetDirectoryName(project.FullName);
await _package.LogAsync($"Project Dir: {projectDir}");
AddTrackedWorkspaceResponse response = await AddTrackedWorkspaceAsync(projectDir);
if (response != null)
{
Expand Down
5 changes: 5 additions & 0 deletions CodeiumVS/LanguageServer/Packets.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2981,6 +2981,11 @@ public enum StopReason
STOP_REASON_MIN_LOG_PROB = 4,
STOP_REASON_MAX_NEWLINES = 5,
STOP_REASON_EXIT_SCOPE = 6,
STOP_REASON_NONFINITE_LOGIT_OR_PROB = 7,
STOP_REASON_FIRST_NON_WHITESPACE_LINE = 8,
STOP_REASON_PARTIAL = 9,
STOP_REASON_FUNCTION_CALL = 10,
STOP_REASON_CONTENT_FILTER = 11,
}

[global::ProtoBuf.ProtoContract()]
Expand Down

0 comments on commit 8a8a795

Please sign in to comment.