Skip to content
This repository was archived by the owner on Jun 25, 2026. It is now read-only.
This repository was archived by the owner on Jun 25, 2026. It is now read-only.

provision_new_vms_to_service: NoMethodError: undefined method `miq_request_tasks' for nil:NilClass #166

Description

@sigbjornaib

I have added a button pointing at "/ Service / Operations / Methods / provision_new_vms_to_service". When I use the button on a Service, I receive the following error message in the automate.log:

NoMethodError: undefined method `miq_request_tasks' for nil:NilClass

This occurs in the "create_provision_request_from_service_template_provision_task" function, when it is looking for "origional_vm_task = task.miq_request_tasks.first.miq_request_tasks.first".

The task var is:
task = $evm.vmdb('service_template_provision_task').find_by_destination_id(service.id)

The task is found, but there are no miq_request_tasks association with the task.

The Service I am using does have a VM attached to it. The Service and VM was provisioned using the code from RedHatConsulting_Satellite6 and RedHatConsulting_Utilities.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions