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..

So I'm having an issue where my installation is not regenerating the transfer objects. when I run `

U049953K1LJ
U049953K1LJ Posts: 14 🧑🏻‍🚀 - Cadet
edited January 2023 in Help

So I'm having an issue where my installation is not regenerating the transfer objects. when I run docker/sdk cli console transfer:generate it ends up throwing an exception saying:

Error - Exception: Class 'Generated\Shared\Transfer\MonitoringTransactionEventTransfer' not found in /data/vendor/spryker/monitoring/src/Spryker/Zed/Monitoring/Business/EventHandler/EventHandler.php (97)

I can tell you the src/Generated directory does not exist anymore because I deleted it while diagnosing this issue, assuming it would just be regenerated. Initially, the src/Generated/Shared/Transfer directory was empty, but I don't recall if that was something I did or something that happened on its own somehow.

Does anyone know what command I should run to make Spryker regenerate that src/Generated directory and the Transfer directory contents?

Comments

  • Ok this was something related to an update of propel at Spryker
    so I assume that you have this file data/cache/propel/generated-conf/loadDatabase.php
    so deleted and then run docker/sdk cli console propel:model:build
    then docker/sdk cli console transfer:generate
    this issue was faced before while I worked at Spryker
    so forgive me if I missed something
    https://github.com/spryker/propel-orm/releases/tag/1.16.0

  • U049953K1LJ
    U049953K1LJ Posts: 14 🧑🏻‍🚀 - Cadet

    @U04CLCFNB9T Thanks for the idea, but it seems that my composer is pulling in spryker/propel-orm v1.14.1, is that still susceptible to the issue?

    I did not have the file you mentioned, but I did have src/Orm/Propel/generated-conf/loadDatabase.php which seems to be getting recreated when I run various console commands.

    Running docker/sdk cli console propel:model:build after deleting the file I mentioned also causes the same error exception I saw initially. I get the same result when running the transfer:generate command.

    If I try to force a newer propel-orm (like >=1.16.0) in composer.json, I get errors from docker/sdk cli composer update saying:

    spryker/propel-orm[1.16.0, ..., 1.17.0] require propel/propel 2.0.0-beta2 -> satisfiable by propel/propel[2.0.0-beta2] from composer repo (<https://repo.packagist.org>) but propel/propel[dev-complexity-reduction-database-model, ..., dev-php74, 2.0.0-alpha1, ..., 2.0.x-dev (alias of dev-master)] from vcs repo (github <https://github.com/spryker/Propel2.git>) has higher repository priority. The packages from the higher priority repository do not match your constraint and are therefore not installable. That repository is canonical so the lower priority repo's packages are not installable. See <https://getcomposer.org/repoprio> for details and assistance.
    

    Any other ideas?

  • Do you have the latest version of your demo-shop??

  • Unknown
    edited January 2023

    this is my current version of spryker/propel-orm
    which has the propel/propel 2.0.0-beta2
    at this version of propel/propel the *Map.php classes have big changes
    for example check src/Orm/Zed/Acl/Persistence/Map/SpyAclGroupTableMap::initialize()
    you will see that your version of this function does not have a return type hint