TwitterOAuth not loading

I am getting the error
Fatal error: Class 'TwitterOAuth' not found

after I upgraded to so I assume it is not being autoloaded. I assumed (probably incorectly) that is should be listed in

// autoload_files.php @generated by Composer
$vendorDir = dirname(dirname(__FILE__));
$baseDir = dirname($vendorDir);
return array(
    '0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => $vendorDir . '/symfony/polyfill-mbstring/bootstrap.php',
    '3b5531f8bb4716e1b6014ad7e734f545' => $vendorDir . '/illuminate/support/Illuminate/Support/helpers.php',
    'ef836782e1b8d747e78815386b148139' => $vendorDir . '/htmlawed/htmlawed/htmLawed.php',

But all I have is those three items.. which seems awfully skimpy.

Is there a place I have to manually add "kertz/twitteroauth" ?


View Replies:
ntisithoj replied on at Permalink Reply
I also see in my concrete/vendor/composer/autoload_classmap.php i have
'TwitterOAuth' => $vendorDir . '/kertz/twitteroauth/twitteroauth/twitteroauth.php'

which, of course, has the "class class TwitterOAuth {" so shouldn't that be enough for
$connection = new TwitterOAuth($PB_APP_KEY, $PB_APP_SECRET);

Korvin replied on at Permalink Reply
We removed that dependency since it wasn't ever actually used anywhere in the core . In hindsight, we should've been more considerate of people using it in the wild.

To fix, I'd suggest using composer to manage application dependencies. Navigate to /application and run:

composer require kertz/twitteroauth:dev-master -o

This will create the new directory /application/vendor and will fill it with the twitter oauth dependency. Now edit /application/bootstrap/autoload.php and add:

require_once __DIR__ . "/../vendor/autoload.php";

Hope that helps,
ntisithoj replied on at Permalink Reply
(NOTE! the problem I am mentioning in this post was fixed by running composer in the applications dir, as was suggested, but I was doing it in the concrete dir by accident)

I already did the composer thing

and my autoload looks like
if ([email protected]include(DIR_BASE_CORE . '/' . DIRNAME_VENDOR . '/autoload.php')) {
    die('Third party libraries not installed. Make sure that composer has required libraries in the concrete/ directory.');

which should be loading it, correct?

simply adding
require_once __DIR__ . "/../vendor/autoload.php";
(p.s. I had to add require_once __DIR__ . "/../../concrete/vendor/autoload.php"; for it to find the file)

to /application/bootstrap/autoload.php just gives me a blank white screen with no error messages :(
Korvin replied on at Permalink Reply
Please follow my directions exactly, the way you have done this will break your install in the future. The most important part is that the new vendor directory that contains this dependency is created in your /application directory so that your site can still be upgraded.

By changing it to point to your concrete directory, you are registering all of the previous versions composer dependencies. That means if we ever update something in the core for security purposes or new features, your site will either be insecure or broken.
ntisithoj replied on at Permalink Reply
Ah, yes... i totally overlooked that. thanks
Korvin replied on at Permalink Reply
Mind editing your previous post so that people don't stumble by this and apply the wrong change?