Skip to content

Potential problem with CACAO Layout Extension #43

@JonasCir

Description

@JonasCir

Hi,
thank you for creating this project!

I am using the latest version (1.3.0) of this tool.

After reading the CACAO Layout Extension Version 1.0, I found the following, potential issues.

Please take a look at the following minimal example I created by connecting the start with the end node and exporting it with the coordinate/layout extension:

Click to expand
{
  "type": "playbook",
  "spec_version": "cacao-2.0",
  "id": "playbook--1d4ad07c-abf3-4013-93f6-6326183f4b38",
  "name": "Playbook Name",
  "description": "Playbook Description",
  "created_by": "identity--e6d6ec0d-16ff-444d-869c-8404e111617e",
  "created": "2025-04-14T15:40:16.533Z",
  "modified": "2025-04-14T15:40:16.533Z",
  "revoked": false,
  "workflow_start": "start--f3fe4015-0190-404a-a3f2-9fc162b8f1ce",
  "workflow": {
    "start--f3fe4015-0190-404a-a3f2-9fc162b8f1ce": {
      "on_completion": "end--1e3abbe6-96cb-4d24-ac39-1fdbfc35aee4",
      "step_extensions": {
        "extension-definition--418ee24c-9cb1-46d9-afa5-309e01aabc7f": {
          "type": "coordinates",
          "x": 300,
          "y": 574,
          "width": 60,
          "height": 40,
          "outgoing_connections": [
            {
              "type": "on-completion",
              "x": [
                360,
                440
              ],
              "y": [
                594,
                594
        }
      },
      "type": "start"
    },
    "end--1e3abbe6-96cb-4d24-ac39-1fdbfc35aee4": {
      "step_extensions": {
        "extension-definition--418ee24c-9cb1-46d9-afa5-309e01aabc7f": {
          "type": "coordinates",
          "x": 440,
          "y": 574,
          "width": 60,
          "height": 40
        }
      },
      "type": "end"
    }
  },
  "extension_definitions": {
    "extension-definition--418ee24c-9cb1-46d9-afa5-309e01aabc7f": {
      "type": "extension-definition",
      "name": "coordinates extension",
      "description": "Coordinates extension for CACAO constructs for visualization purposes.",
      "created_by": "identity--5abe695c-7bd5-4c31-8824-2528696cdbf1",
      "schema": "https://raw.githubusercontent.com/cyentific-rni/cacao-coordinates-extension/main/schemas/coordinates.json",
      "version": "1.0.0"
    }
  }
}

Here are the things that I think need fixing:

  • The extension_definitionssection should contain the Layout Extension Definition as described in Section 5 and not reference the old schema in cyentific-rni/cacao-coordinates-extension
  • The playbook_extension object should be set with
{
"extension-definition--418ee24c-9cb1-46d9-afa5-309e01aabc7f": {
  "type": "layout",
    "canvas": {
    "width": "SOME_WIDTH",
    "height": "SOME_HEIGHT"
    }
  }
}

which is missing in the minimal example

  • The example in Appendix A contains the following for step_extensions:
"type": "layout",
"coordinates": {
  "x": 690,
  "y": 440,
 }

while in the minimal example above we have:

{
  "type": "coordinates",
  "x": 440,
  "y": 574,
  "width": 60,
  "height": 40
}

From my understanding coordinates should be a dedicated key and not the value of type

  • the export popup should not read Export with the coordinates extension but Export with the layout extension for consistent naming

I don't know if these points are valid, but I want to make sure this is looked into.

Thank you and

Kind regards,
Jonas

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingcacao-v2

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions