Skip to content
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

[BUG] Missing fields in timer object #858

Closed
pacorreia opened this issue Jun 7, 2021 · 1 comment · Fixed by Azure/azure-functions-python-library#110
Closed

[BUG] Missing fields in timer object #858

pacorreia opened this issue Jun 7, 2021 · 1 comment · Fixed by Azure/azure-functions-python-library#110
Assignees
Labels
investigating P2 [P2] items : Not ship blocking

Comments

@pacorreia
Copy link

Investigative information

Please provide the following:
  • Timestamp: Irrelevant
  • Function App name: local development
  • Function name(s) (as appropriate): local development
  • Core Tools version: 3.0.3442

Repro steps

Provide the steps required to reproduce the problem:
  1. Create and ordinary timer triggered function
  2. Declare entrypoint as usual:
    • def main(mytimer: func.TimerRequest) -> None:

Expected behavior

Provide a description of the expected behavior.

Content expect in mytimer object (sample):

{
    "schedule":{
    },
    "scheduleStatus": {
        "last":"2016-10-04T10:15:00+00:00",
        "lastUpdated":"2016-10-04T10:16:00+00:00",
        "next":"2016-10-04T10:20:00+00:00"
    },
    "isPastDue":false
}

Actual behavior

Provide a description of the actual behavior observed.

This the current behavior:
image

Only the flag past_due is present

Known workarounds

Provide a description of any known workarounds.

None

Contents of the requirements.txt file:

Provide the requirements.txt file to help us find out module related issues.
# Do not include azure-functions-worker as it may conflict with the Azure Functions platform

# Microsoft function app package
azure-functions

# AAD authetincation and blob storage packages
azure-identity
azure-storage-file-datalake

# Database access packages
sqlalchemy
pyodbc

# Packages for ETL
urllib3
pandas
fastparquet
xlrd

# Debug package
debugpy

# Logging
opencensus-ext-azure

Related information

Provide any related information
  • Links to source: Can't provide, corporate content
  • Bindings used
    • {
          "scriptFile": "__init__.py",
          "bindings": [
              {
                  "name": "functimer",
                  "authLevel": "function",
                  "direction": "in",
                  "type": "timerTrigger",
                  "schedule": "%COFFEE_STOCKS_SCHEDULE%",
                  "useMonitor": true
              }
          ]
      }
@vrdmr
Copy link
Member

vrdmr commented Jul 7, 2021

Verifying in TypeScript - It does have scheduleStatus field and we need to add this in the timer's implementation.

image

When looking at the Python datum - ScheduleStatus is not being passed. Need to verify this.

  data.value being passed - {'Schedule': {'AdjustForDST': True}, 'ScheduleStatus': None, 'IsPastDue': False}
  json.loads(data.value) - {"Schedule":{"AdjustForDST":true},"ScheduleStatus":null,"IsPastDue":false}
  trigger_metadata ['TimerTrigger'] - 7/7/2021 12:17:20 AM
[2021-07-07T07:17:20.011Z] Python timer trigger function ran at 2021-07-07T07:17:20.008287+00:00

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
investigating P2 [P2] items : Not ship blocking
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants