Uploaded image for project: 'Qbs ("Cubes")'
  1. Qbs ("Cubes")
  2. QBS-1335

Regression: Cannot access module properties in setupBuildEnvironment anymore

    XMLWordPrintable

Details

    • Bug
    • Resolution: Invalid
    • Not Evaluated
    • None
    • 1.11.0
    • None
    • Qbs 1.11.0, QtCreator 4.6.0, Windows 10

    Description

      Accessing a module property in setupBuildEnvironment (and setupRunEnvironment) is not possible anymore. The example below used to work in Qbs 1.10 and before:

      import qbs 1.0
      Module {
          property int a: 42
          setupBuildEnvironment: {
              console.info(a)
          }
      }

      Now with Qbs 1.11.0 an Error running setupBuildEnvironment script for product 'prod': ReferenceError: Can't find variable: a is thrown in line 6 when trying to build

      import qbs 1.0
      
      Product {
          Depends { name: "mod" }
      }

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            kandeler Christian Kandeler
            thomas.epting Thomas Epting
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes