Skip to content

Conversation

@hallvictoria
Copy link
Contributor

When defining a BlobTrigger using BlobSource.EVENT_GRID, the source value was not being resolved correctly, and the error below was being thrown. This is because the host was receiving EVENT_GRID as the source value, instead of the correct value "EventGrid". This changes what source is set to in the BlobTrigger decorator. If source is defined, source is set to the EVENT_GRID value. If source is not defined, source is set to null and is ignored.

@app.blob_trigger(arg_name="myblob",
                  path="mycontainer",
                  data_type=func.DataType.STRING,
                  source = func.BlobSource.EVENT_GRID,
                  connection="AzureWebJobsStorage") 
The 'blob_trigger' function is in error: Unable to configure binding 'myblob' of type 'blobTrigger'. This may indicate invalid function.json properties. Could not convert 'EVENT_GRID' to BlobTriggerSource. Error converting value "EVENT_GRID" to type 'Microsoft.Azure.WebJobs.BlobTriggerSource'. Path 'source', line 1, position 165. Requested value 'EVENT_GRID' was not found.

Fixes: Azure/azure-functions-python-worker#1582

guptaheena and others added 4 commits September 26, 2024 10:34
* mysql binding support

* fix linting

* Update __init__.py

* fix indentation

---------

Co-authored-by: wangbill <gggwang1993@gmail.com>
Co-authored-by: Gavin Aguiar <80794152+gavin-aguiar@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants