Skip to content

Commit a4db092

Browse files
TylerLeonhardtFrancisco-Gamino
authored andcommitted
Fix issue with proxies (#261)
* fix issue with proxies
1 parent 8c6fcbe commit a4db092

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/RequestProcessor.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,9 @@ internal StreamingMessage ProcessFunctionLoadRequest(StreamingMessage request)
159159
// Ideally, the initialization should happen when processing 'WorkerInitRequest', however, the 'WorkerInitRequest'
160160
// message doesn't provide information about the FunctionApp. That information is not available until the first
161161
// 'FunctionLoadRequest' comes in. Therefore, we run initialization here.
162-
if (!_isFunctionAppInitialized)
162+
// Also, we receive a FunctionLoadRequest when a proxy is configured. Proxies don't have the Metadata.Directory set
163+
// which would cause initialization issues with the PSModulePath. Since they don't have that set, we skip over them.
164+
if (!_isFunctionAppInitialized && !functionLoadRequest.Metadata.IsProxy)
163165
{
164166
try
165167
{

0 commit comments

Comments
 (0)