Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to use autoload files from other projects? #29

Closed
helderco opened this issue Jun 7, 2015 · 4 comments
Closed

How to use autoload files from other projects? #29

helderco opened this issue Jun 7, 2015 · 4 comments

Comments

@helderco
Copy link

helderco commented Jun 7, 2015

I'm trying to install drupal/webprofiler, which has the following composer.json:

{
    "name": "drupal/webprofiler",
    "description": "",
    "type": "drupal-webprofiler",
    "license": "GPL-2.0+",
    "require": {
        "symfony/stopwatch": "2.4.*"
    },
    "autoload": {
        "files": [
            "vendor/symfony/stopwatch/Symfony/Component/Stopwatch/Stopwatch.php"
        ]
    }
}

This gives me a fatal error, because composer is trying to find that file in a vendor folder inside that module. How should this be fixed, so that files is looking for files in the root vendor folder?

@webflo
Copy link
Member

webflo commented Jun 7, 2015

The fix should be in drupal/webprofiler itself. Because its not allowed to require files from other libraries via composers autoload feature.

@webflo
Copy link
Member

webflo commented Jun 7, 2015

We had a similar issue in core and resolved it in https://www.drupal.org/node/2468499.

@helderco
Copy link
Author

helderco commented Jun 8, 2015

Yeah, I don't even understand why they're requiring that file when it should be autoloaded already.

I'll work it out on their issue queue, thanks.

@helderco helderco closed this as completed Jun 8, 2015
@webflo
Copy link
Member

webflo commented Jun 8, 2015

Thanks!

g3r4 pushed a commit to Bixal/drupal-project that referenced this issue May 6, 2019
)

Feature/WIOA-293 content sync

Approved-by: Gerardo Maldonado <gerardo.maldonado@bixal.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants