Coder Social home page Coder Social logo

Comments (9)

fabpot avatar fabpot commented on July 18, 2024

Have you tried to composer update? It should work after that.

from goutte.

enygma avatar enygma commented on July 18, 2024

Yep, even did a fresh install (wiped out the vendor/ and composer.lock) and reinstalled. Did an "update" just for good measure, but it's still the same:

PHP Fatal error: Class 'Goutte\Client' not found in /www/htdocs/testing-examples/app/vendor/behat/mink/src/Behat/Mink/Driver/Goutte/Client.php on line 13

In that file it has:

use Goutte\Client as BaseClient; and class Client extends BaseClient { .... }

The namespace in the compsoer/autoload_namespaces.php is still:

'Goutte' => $vendorDir . '/fabpot/goutte/src/',

from goutte.

enygma avatar enygma commented on July 18, 2024

Yeah, something's broken with how the composer stuff is implemented now. I changed my lock file to this:

{ "package": "fabpot/goutte", "version": "master-dev", "source-reference": "5ecceb7c28a428fb93f283982cc4f5edfd96630b" },

Pointing to the last commit before the recent updates and, after running a composer install it works correctly after that. (The Behat run succeeds)

from goutte.

fabpot avatar fabpot commented on July 18, 2024

That's weird. I've just cloned Goutte and the run composer.phar install and here is the content of my vendor/composer/autoload_namespaces.php:

<?php

// autoload_namespace.php generated by Composer

$vendorDir = dirname(__DIR__);
$baseDir = dirname($vendorDir);

return array(
    'Symfony\\Component\\Process' => $vendorDir . '/symfony/process/',
    'Symfony\\Component\\Finder' => $vendorDir . '/symfony/finder/',
    'Symfony\\Component\\EventDispatcher' => $vendorDir . '/symfony/event-dispatcher/',
    'Symfony\\Component\\DomCrawler' => $vendorDir . '/symfony/dom-crawler/',
    'Symfony\\Component\\CssSelector' => $vendorDir . '/symfony/css-selector/',
    'Symfony\\Component\\BrowserKit' => $vendorDir . '/symfony/browser-kit/',
    'Guzzle\\Tests' => $vendorDir . '/guzzle/guzzle/tests/',
    'Guzzle' => $vendorDir . '/guzzle/guzzle/src/',
    'Goutte' => $baseDir . '/.',
);

from goutte.

enygma avatar enygma commented on July 18, 2024

here's my composer.json I'm pulling from: https://gist.github.com/2704264

Not sure why it would be different, though...

from goutte.

stof avatar stof commented on July 18, 2024

@enygma Behat was defining a package for Goutte previously as it was not supporting Composer directly. But the behat package definition is still referencing the old structure. This is probably the reason why you have some issues

from goutte.

enygma avatar enygma commented on July 18, 2024

Ah that makes sense...I guess I see a pull request in my future heh
On May 15, 2012 4:46 PM, "Christophe Coevoet" <
[email protected]>
wrote:

@enygma Behat was defining a package for Goutte previously as it was not
supporting Composer directly. But the behat package definition is still
referencing the old structure. This is probably the reason why you have
some issues


Reply to this email directly or view it on GitHub:
#47 (comment)

from goutte.

fabpot avatar fabpot commented on July 18, 2024

closing this issue as this seems to be related to Behat.

from goutte.

enygma avatar enygma commented on July 18, 2024

just so there'll be a record here - this has been updated for the Behat side: https://github.com/Behat/Mink/pull/247#issuecomment-5783326

from goutte.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.