-
Notifications
You must be signed in to change notification settings - Fork 437
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Uncaught exception with latest version crashes container #4158
Comments
Thanks for reporting the issue. I am able to repro and see the same problem reported (running on a Mac (M3)), and we were not able to repro on Windows so it does seem to be an amd64 related issue. Interestingly, the last run I did threw a new exception:
Versions |
@somesylvie question about your scenario. Why are you installing core tools in the container? I was looking at the code you shared: And you should be able to run the application just fine without azure-function:
image: mcr.microsoft.com/azure-functions/node:4-node20
volumes:
- ./azure_functions:/home/site/wwwroot
ports:
- "7072:7071"
environment:
AzureWebJobsScriptRoot: /home/site/wwwroot
AzureFunctionsJobHost__Logging__Console__IsEnabled: true
AzureWebJobs.HttpExample.Disabled: "true"
AzureWebJobsStorage: DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://sftp-Azurite:10000/devstoreaccount1;QueueEndpoint=http://sftp-Azurite:10001/devstoreaccount1;TableEndpoint=http://sftp-Azurite:10002/devstoreaccount1; # pragma: allowlist secret
AZURE_STORAGE_CONNECTION_STRING: DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://sftp-Azurite:10000/devstoreaccount1;QueueEndpoint=http://sftp-Azurite:10001/devstoreaccount1; # pragma: allowlist secret
networks:
- sftp
depends_on:
azure-cli:
condition: service_completed_successfully
sftp-server:
condition: service_started Edit: If it's because of typescript, you can build via a Dockerfile i.e. FROM mcr.microsoft.com/azure-functions/node:4-node20
ENV AzureWebJobsScriptRoot=/home/site/wwwroot \
AzureFunctionsJobHost__Logging__Console__IsEnabled=true
COPY . /home/site/wwwroot
RUN cd /home/site/wwwroot && \
npm install && \
npm run build Updated service in compose: azure-function:
build:
context: .
dockerfile: ./azure_functions/Dockerfile |
@liliankasem it's been months since we set this all up so I don't remember the details of why it's set up the way it is, but without the whole command section or without just the core tools install, we get this error:
With the updated service and Dockerfile you suggested, we get these errors:
|
Hmm, for the second error that's my bad, the context should be the azure_functions folder:
I'm not sure about the first error though "Can't figure out which ctor to call" - will investigate this |
Hi @somesylvie - I found the resolution for your original docker-compose file. You need to add this environment variable: environment:
DOTNET_EnableWriteXorExecute: 0 I found the resolution here: dotnet/runtime#103063 (comment) It seems to be specifically related to docker containers running on arm64 mac. |
Version
4.0.6543 and 4.0.6594 (even though 6543 is the 'latest' on the NPM website, when we run
npm install -g azure-functions-core-tools
without specifying a version, we end up with the unlisted 6594)Description
When running an azure function docker container, we recently started to see this error, which then crashes the container:
terminate called after throwing an instance of 'PAL_SEHException'
Nothing in the Azure function or its configuration has changed recently. When we explicitly specify an older version of the core tools (such as
4.0.6280
), we don't have any issuesSteps to reproduce
Run the azure function via docker compose: https://github.com/CDCgov/reportstream-sftp-ingestion/blob/main/docker-compose.yml#L65
Note that the installed version of core tools is the unlisted 6594, though we see the
PAL_SEHException
with version 6543 as wellWe do not get the error if we change line 76 to
npm install -g [email protected]
This is happening for at least 3 engineers on my team, all on Mac (either M1 or M3)
The text was updated successfully, but these errors were encountered: