Skip to content

Commit aa50688

Browse files
authored
.Net: Added missing KernelFunction attribute to DownloadFileAsync in SessionsPythonPlugin (#11215)
### Description <!-- Describe your changes, the overall approach, the underlying design. These notes will help understanding how your code works. Thanks! --> Added missing KernelFunction attribute to DownloadFileAsync in SessionsPythonPlugin ### Contribution Checklist <!-- Before submitting this PR, please make sure: --> - [x] The code builds clean without any errors or warnings - [x] The PR follows the [SK Contribution Guidelines](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md) and the [pre-submission formatting script](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md#development-scripts) raises no violations - [x] All unit tests pass, and I have added new tests where possible - [x] I didn't break anyone 😄
1 parent 0d4ee20 commit aa50688

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

dotnet/src/Plugins/Plugins.Core/CodeInterpreter/SessionsPythonPlugin.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ public SessionsPythonPlugin(
4747

4848
this._settings = settings;
4949

50-
// Ensure the endpoint won't change by reference
50+
// Ensure the endpoint won't change by reference
5151
this._poolManagementEndpoint = GetBaseEndpoint(settings.Endpoint);
5252

5353
this._authTokenProvider = authTokenProvider;
@@ -184,7 +184,7 @@ public async Task<SessionsRemoteFileMetadata> UploadFileAsync(
184184
/// <param name="remoteFilePath"> The path to download the file from, relative to `/mnt/data`. </param>
185185
/// <param name="localFilePath"> The path to save the downloaded file to. If not provided won't save it in the disk.</param>
186186
/// <returns> The data of the downloaded file as byte array. </returns>
187-
[Description("Downloads a file from the current Session ID.")]
187+
[KernelFunction, Description("Downloads a file from the current Session ID.")]
188188
public async Task<byte[]> DownloadFileAsync(
189189
[Description("The path to download the file from, relative to `/mnt/data`.")] string remoteFilePath,
190190
[Description("The path to save the downloaded file to. If not provided won't save it in the disk.")] string? localFilePath = null)

0 commit comments

Comments
 (0)