Murano PL blank error message with arg format error

Bug #1620148 reported by Mark Endrei
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Murano
Invalid
Undecided
Unassigned
Mitaka
Won't Fix
Low
Valerii Kovalchuk
Newton
Invalid
Undecided
Unassigned

Bug Description

Hello,

I get the following blank dashboard error message when deploying an app with a Murano PL class that has more than one method argument without the hyphen:

2016-09-04 04:42:55 — Action deploy is scheduled
2016-09-04 04:42:57 — Deployment finished with errors
2016-09-04 04:42:57 —

It can be reproduced with the following example method:

...
  print:
    Arguments:
      message:
        Contract: $.string().notNull()
      message2:
        Contract: $.string().notNull()
    Body:
      - $._environment.reporter.report($this, format('{0},{1}',$message,$message2))
...

A descriptive message would make it easier to debug this syntax error, especially because one argument without hyphen is fine, eg.

  print:
    Arguments:
      message:
        Contract: $.string().notNull()
    Body:
      - $._environment.reporter.report($this, $message))

Thanks, Mark

Revision history for this message
Mark Endrei (markendr) wrote :

We are on Mitaka

tamil vanan (tamilhce)
Changed in murano:
assignee: nobody → tamil vanan (tamilhce)
Revision history for this message
Valerii Kovalchuk (vakovalchuk) wrote :

I've added your method to my app and deployment gives me the following log:
2016-09-06 13:50:47 — Action deploy is scheduled
2016-09-06 13:50:52 — Invalid arguments declaration
2016-09-06 13:50:52 — Deployment finished with errors

So the error message is not blank.

Can you share your application code somehow to examine it?

Changed in murano:
status: New → Incomplete
Revision history for this message
Valerii Kovalchuk (vakovalchuk) wrote :

I'm using murano from master though. Will try it on mitaka

Revision history for this message
Mark Endrei (markendr) wrote :

I added the method above to the ApacheHTTPServer package from the app catalog to repeat/confirm the problem on mitaka. Please find attached.

Great if it is already fixed in master

Cheers, Mark

tamil vanan (tamilhce)
Changed in murano:
assignee: tamil vanan (tamilhce) → nobody
Revision history for this message
Valerii Kovalchuk (vakovalchuk) wrote :

@Mark: the bug was fixed in master by the patch https://review.openstack.org/#/c/310055/7/murano/dsl/murano_method.py

Unfortunately the fix cannot be backported to stable/mitaka branch, because it was done as a part of the feature. You can fix it yourself by applying the following lines from the patch above (lines 92-94 in murano_method.py file):

if not isinstance(record, dict) or len(record) > 1:
    raise exceptions.DslSyntaxError(
        'Invalid arguments declaration')

instead of the empty ValueError in mitaka

Revision history for this message
Mark Endrei (markendr) wrote :

@Valerii: thanks for confirming it is fixed in master, and for the fix details. I will raise with our operations team to see if they want to patch.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.