Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bump for doctrine orm 2 -> 3, dbal 3 -> 4 through roave psr container #283

Merged
merged 5 commits into from
Jun 17, 2024

Conversation

cPintiuta
Copy link
Member

No description provided.

Copy link

github-actions bot commented Jun 12, 2024

Qodana for PHP

82 new problems were found

Inspection name Severity Problems
Undefined method 🔶 Warning 62
Undefined class 🔶 Warning 12
Undefined namespace 🔶 Warning 8

💡 Qodana analysis was run in the pull request mode: only the changed files were checked
☁️ View the detailed Qodana report

Contact Qodana team

Contact us at [email protected]

Copy link
Member

@alexmerlin alexmerlin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any idea why the uuid column has moved towards the end of the table, before the created column?
I guess Doctrine3 treats differently an entity when it extends another entity.

…gning AbstractEntity as MappedSuperclass for doctrine
@cPintiuta
Copy link
Member Author

Any idea why the uuid column has moved towards the end of the table, before the created column? I guess Doctrine3 treats differently an entity when it extends another entity.

Yes, because those columns comes from AbstractEntity, we need to declare this class with MappedSuperclass attribute, and if we want the uuid to appear first and timestamps last, we need to split them.

@cPintiuta
Copy link
Member Author

cPintiuta commented Jun 13, 2024

@alexmerlin The problem from github actions is dot-data-fixtures who request doctrine/data-fixtures ^1.5. support for orm 3 and dbal 4 was added from 1.7.
We need to disquss how we aproach this to be sure that it works for api v4 and v5.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the good: updated should get updated when the entity gets updated.
the bad: updated should stay null at entity creation.
@arhimede correct me if I'm wrong.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is not a tragedy if at the creation time, created and updated fields have the samr value
if this simplify the code, we should keep it that way

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Second tought (or so)

We should not use ilogical stuff in database.
So at creation time, should be null the updated field

@alexmerlin alexmerlin linked an issue Jun 14, 2024 that may be closed by this pull request
@arhimede arhimede merged commit 33f5edf into 5.0 Jun 17, 2024
21 checks passed
@alexmerlin alexmerlin deleted the issue-264 branch June 17, 2024 11:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement doctrine 3
3 participants