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 ๐Ÿ™‚