What are the Slack Archives?

It’s a history of our time together in the Slack Community! There’s a ton of knowledge in here, so feel free to search through the archives for a possible answer to your question.

Because this space is not active, you won’t be able to create a new post or comment here. If you have a question or want to start a discussion about something, head over to our categories and pick one to post in! You can always refer back to a post from Slack Archives if needed; just copy the link to use it as a reference..

Hi folks, is it possible to use debugger on vendor/spryker/modules code? I am using a XDebug with Ph

U025NDD2QNA
U025NDD2QNA Posts: 42 πŸ§‘πŸ»β€πŸš€ - Cadet

Hi folks, is it possible to use debugger on vendor/spryker/modules code? I am using a XDebug with PhpStorm ide.

Comments

  • Alberto Reyer
    Alberto Reyer Lead Spryker Solution Architect / Technical Director Posts: 690 πŸͺ - Explorer

    Sure, set a breakpoint in your IDE and debug it like you do with your project code.

  • U025NDD2QNA
    U025NDD2QNA Posts: 42 πŸ§‘πŸ»β€πŸš€ - Cadet

    I can reach the public/Yves/index.php breakpoint.

    But putting it anywhere inside the vendor/spryker/module/phpclass does not yield the same result

  • U025NDD2QNA
    U025NDD2QNA Posts: 42 πŸ§‘πŸ»β€πŸš€ - Cadet

    I’m putting a breakpoint on Glue Controller class. and makign the request through Postman

  • Andriy Netseplyayev
    Andriy Netseplyayev Domain Lead Solution Architecture Sprykee Posts: 519 πŸ§‘πŸ»β€πŸš€ - Cadet

    @U025NDD2QNA once you’re in the index.php endpoint - try to use β€œgo into” button to get deeper. Does PHPStorm offer you to β€œconfigure path mappings” in the debug window? (https://documentation.spryker.com/docs/configuring-debugging-in-docker#configuring-servers)

  • U025NDD2QNA
    U025NDD2QNA Posts: 42 πŸ§‘πŸ»β€πŸš€ - Cadet

    thanks Andriy. I was able to get into YvesBootstrap php class.

    But when I make any http request to access Glue controller method, I dont get access to it.

  • Andriy Netseplyayev
    Andriy Netseplyayev Domain Lead Solution Architecture Sprykee Posts: 519 πŸ§‘πŸ»β€πŸš€ - Cadet

    Okay, did you pass the right Cookie with the request?

  • Andriy Netseplyayev
    Andriy Netseplyayev Domain Lead Solution Architecture Sprykee Posts: 519 πŸ§‘πŸ»β€πŸš€ - Cadet

    I mean, as I understand you use Postman - so you need to add a cookie from there

  • Andriy Netseplyayev
    Andriy Netseplyayev Domain Lead Solution Architecture Sprykee Posts: 519 πŸ§‘πŸ»β€πŸš€ - Cadet

    and so you can β€œbreak at first line” in PHPStorm to be sure

  • U025NDD2QNA
    U025NDD2QNA Posts: 42 πŸ§‘πŸ»β€πŸš€ - Cadet

    ah thanks Andriy! it worked πŸ™‚