We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 29597 ☆ A M B ☆
    • 350 Posts
    Hello all I am working on my Flexibility package and when running build.transport.php I get the following errors.

    I would really love some help with this. I would not like to waste to much time finding these errors.
    See error log and transport code as attachment.

    [2011-12-12 10:15:57] (INFO @ /flexibility/_build/build.transport.php)
    
    Created new transport package with signature: flexibility-2.0.1-beta1
    
    [2011-12-12 10:15:57] (INFO @ /flexibility/_build/build.transport.php)
    
    Registered package namespace as: flexibility
    
    [2011-12-12 10:15:57] (INFO @ /flexibility/_build/build.transport.php)
    
    Packaged namespace "flexibility" into package.
    
    [2011-12-12 10:15:57] (INFO @ /flexibility/_build/build.transport.php)
    
    Adding in snippets.
    
    [2011-12-12 10:15:57] (INFO @ /flexibility/_build/build.transport.php)
    
    Adding in property sets.
    
    [2011-12-12 10:15:57] (INFO @ /flexibility/_build/build.transport.php)
    
    Adding in chunks.
    
    [2011-12-12 10:15:57] (INFO @ /flexibility/_build/build.transport.php)
    
    Adding in templates.
    
    [2011-12-12 10:15:57] (INFO @ /flexibility/_build/build.transport.php)
    
    Adding in Template Variables.
    
    [2011-12-12 10:15:57] (INFO @ /flexibility/_build/build.transport.php)
    
    Adding in Plugins.
    
    [2011-12-12 10:15:57] (INFO @ /flexibility/_build/build.transport.php)
    
    Adding in Script Resolver.
    
    [2011-12-12 10:15:57] (INFO @ /flexibility/_build/build.transport.php)
    
    Adding in subpackages.
    
    [2011-12-12 10:15:57] (ERROR @ /flexibility/_build/build.transport.php)
    
    Source file /home/anyscreen/domains/anyscreensize.com/public_html/flexibility/assets/components/flexibility is missing or /home/anyscreen/domains/anyscreensize.com/public_html/flexibility/core/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/2/ is not writable
    
    [2011-12-12 10:17:23] (ERROR @ /home/anyscreen/domains/anyscreensize.com/public_html/flexibility/core/xpdo/cache/xpdocachemanager.class.php : 345)
    
    PHP warning: is_dir() [function.is-dir]: open_basedir restriction in effect. File(/home/anyscreen/domains/anyscreensize.com/public_html/flexibility/core/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory//037306497a828091e240b883c3361fd7/1/flexibility/elements/snippets/) is not within the allowed path(s): (/home/anyscreen/:/tmp:/var/tmp:/usr/local/lib/php/)
    
    [2011-12-12 10:17:23] (ERROR @ /home/anyscreen/domains/anyscreensize.com/public_html/flexibility/core/xpdo/cache/xpdocachemanager.class.php : 268)
    
    PHP warning: is_dir() [function.is-dir]: open_basedir restriction in effect. File(/home/anyscreen/domains/anyscreensize.com/public_html/flexibility/core/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/1/flexibility/elements/snippets) is not within the allowed path(s): (/home/anyscreen/:/tmp:/var/tmp:/usr/local/lib/php/)
    
    [2011-12-12 10:17:23] (ERROR @ /home/anyscreen/domains/anyscreensize.com/public_html/flexibility/core/xpdo/cache/xpdocachemanager.class.php : 348)
    
    PHP warning: is_dir() [function.is-dir]: open_basedir restriction in effect. File(/home/anyscreen/domains/anyscreensize.com/public_html/flexibility/core/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/1/flexibility/elements/snippets) is not within the allowed path(s): (/home/anyscreen/:/tmp:/var/tmp:/usr/local/lib/php/)
    
    [2011-12-12 10:17:23] (ERROR @ /flexibility/_build/build.transport.php)
    
    Could not create target directory /home/anyscreen/domains/anyscreensize.com/public_html/flexibility/core/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/1/flexibility/elements/snippets
    
    [2011-12-12 10:17:23] (ERROR @ /flexibility/_build/build.transport.php)
    
    Could not copy directory /home/anyscreen/domains/anyscreensize.com/public_html/flexibility/core/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/1/flexibility/elements/snippets to /home/anyscreen/domains/anyscreensize.com/public_html/flexibility/core/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/1/flexibility/elements/snippets
    
    [2011-12-12 10:17:23] (ERROR @ /flexibility/_build/build.transport.php)
    
    Could not copy directory /home/anyscreen/domains/anyscreensize.com/public_html/flexibility/core/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/packages/flexibility-2.0.1-beta1/modCategory/037306497a828091e240b883c3361fd7/4/p

    This question has been answered by BobRay. See the first response.

    [ed. note: ThaClown last edited this post 14 years, 9 months ago.]
      MODX Ambassador (NL) | Responsive web design specialist, developer & speaker
      DESIGNfromWITHIN, MPThemes and Any Screen Size
      Follow me on Twitter | Read my blog | My code on GitHub
      • 24865
      • 289 Posts
      open_basedir usually point to a script going out of the root folder (that being /home/) to switch to another user. Most likely you're trying to build your package in another site on the same FTP. Perhaps you copied the transporter from another site?

      I'd also advice to output in ECHO (setLogTarget) if you're not doing that already. wink
        @MarkGHErnst

        Developer at Adwise Internetmarketing, the Netherlands.
        • 29597 ☆ A M B ☆
        • 350 Posts
        Thx,
        I changed the root in build.transport.php to:
        $root = '/home/anyscreen/domains/anyscreensize.com/public_html/flexibility/';
        

        Is this the right path (it is the base php path to my Flexibility site where the _build, assets and core folders are located)?

        Could you explain a bit more on do the ECHO (setLogTarget) part?
          MODX Ambassador (NL) | Responsive web design specialist, developer & speaker
          DESIGNfromWITHIN, MPThemes and Any Screen Size
          Follow me on Twitter | Read my blog | My code on GitHub
          • 24865
          • 289 Posts
          Depends on how you use the transporter. What the transporter usually does, at least in my case, is build a package and then store it in my MODX package folder (since you use a xPDOTransport provided with your MODX installation). You can thus use the MODX_CORE_PATH as a viable root for your builder.

          Usually I enter something around the lines of this;
          $root = dirname(dirname(__FILE__)).'/';
          $sources= array (
              'root' => $root,
              'build' => $root .'_build/',
              'resolvers' => $root . '_build/resolvers/',
              'data' => $root . '_build/data/',
              'source_core' => $root.'core/components/cmp',
              'lexicon' => $root . 'core/components/cmp/lexicon/',
              'documents' => $root.'core/components/cmp/documents/',
          );


          Trust me, it will require a bit of debugging to get it right. Unfortunately, you're alone on that one since each installation is different due to the base path and all.

          And the setLogTarget is something you can call with modx ($modx->setLogTarget). Usually it points to FILE, whereas you can read the errors in the backend of MODX. In this case, that's totally useless since it isn't MODX making errors. You simply change the word FILE to ECHO, which outputs it on screen when you enter $modx->log(1, 'Hi!');

          Oh and yes, it has to point to the ROOT of your site, where all your MODX folders are located (assets, core, manager, index.php, .htaccess)
            @MarkGHErnst

            Developer at Adwise Internetmarketing, the Netherlands.
          • discuss.answer
            • 3749
            • 24,544 Posts
            You might want to try the MyComponent add-on, which serves as a shell for building transport packages (or at least look at its code). It gets installed when you install the GetMyComponent package.

            There's a tutorial here: http://bobsguides.com/mycomponent-tutorial.html
              Did I help you? Buy me a beer
              Get my Book: MODX:The Official Guide
              MODX info for everyone: http://bobsguides.com/modx.html
              My MODX Extras
              Bob's Guides is now hosted at A2 MODX Hosting
              • 24865
              • 289 Posts
              True true, and don't forget to correctly enter your modx_workspace (package folder), since otherwise the xPDOTransport can't build it. Make sure it's writeable, too.
                @MarkGHErnst

                Developer at Adwise Internetmarketing, the Netherlands.
                • 29597 ☆ A M B ☆
                • 350 Posts
                Thanks you guys, will do a fresh start from the MyComponent example.
                  MODX Ambassador (NL) | Responsive web design specialist, developer & speaker
                  DESIGNfromWITHIN, MPThemes and Any Screen Size
                  Follow me on Twitter | Read my blog | My code on GitHub