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

Fixes phpstan errors, set PHPStan to level 7 #1951

Merged
merged 10 commits into from
Jan 25, 2023

Conversation

michbeck
Copy link
Contributor

PHP Stan fixes for #1921

composer.json Outdated Show resolved Hide resolved
@dereuromark dereuromark changed the title Fixes phpstan errors Fixes phpstan errors, set PHPStan to level 7 Jan 24, 2023
src/Propel/Generator/Platform/SqlitePlatform.php Outdated Show resolved Hide resolved
src/Propel/Generator/Reverse/MssqlSchemaParser.php Outdated Show resolved Hide resolved
src/Propel/Generator/Reverse/OracleSchemaParser.php Outdated Show resolved Hide resolved
src/Propel/Generator/Util/QuickBuilder.php Outdated Show resolved Hide resolved
@codecov-commenter
Copy link

codecov-commenter commented Jan 25, 2023

Codecov Report

Base: 88.63% // Head: 88.56% // Decreases project coverage by -0.08% ⚠️

Coverage data is based on head (c7661af) compared to base (5531e13).
Patch coverage: 73.46% of modified lines in pull request are covered.

Additional details and impacted files
@@             Coverage Diff              @@
##             master    #1951      +/-   ##
============================================
- Coverage     88.63%   88.56%   -0.08%     
- Complexity     8019     8047      +28     
============================================
  Files           243      243              
  Lines         24549    24592      +43     
============================================
+ Hits          21759    21779      +20     
- Misses         2790     2813      +23     
Flag Coverage Δ
5-max 88.56% <73.46%> (-0.08%) ⬇️
7.4 88.56% <73.46%> (-0.08%) ⬇️
agnostic 67.30% <42.85%> (-0.10%) ⬇️
mysql 69.09% <55.78%> (-0.05%) ⬇️
pgsql 69.11% <50.34%> (-0.07%) ⬇️
sqlite 67.08% <49.65%> (-0.07%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
.../Propel/Generator/Builder/Om/AbstractOMBuilder.php 96.72% <0.00%> (ø)
src/Propel/Generator/Manager/ModelManager.php 96.55% <ø> (ø)
src/Propel/Generator/Platform/PgsqlPlatform.php 97.56% <ø> (ø)
src/Propel/Generator/Reverse/PgsqlSchemaParser.php 87.54% <0.00%> (ø)
...c/Propel/Runtime/Collection/CollectionIterator.php 52.50% <ø> (ø)
src/Propel/Runtime/Collection/ObjectCollection.php 97.04% <ø> (ø)
src/Propel/Runtime/Formatter/OnDemandFormatter.php 80.35% <0.00%> (-1.47%) ⬇️
src/Propel/Runtime/Map/DatabaseMap.php 96.34% <ø> (ø)
src/Propel/Runtime/Util/PropelConditionalProxy.php 100.00% <ø> (ø)
src/Propel/Generator/Platform/SqlitePlatform.php 92.96% <20.00%> (-1.11%) ⬇️
... and 29 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@dereuromark
Copy link
Contributor

@mringler This would then be the last PR merged for the release of new beta this week
Is this OK for you?

@dereuromark dereuromark added this to the 2.0.0 Beta milestone Jan 25, 2023
@dereuromark
Copy link
Contributor

Nice work!

Copy link
Contributor

@mringler mringler left a comment

Choose a reason for hiding this comment

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

Very nice! Seems like you are literally kicking the crap out of Propel.

src/Propel/Generator/Builder/Om/AbstractOMBuilder.php Outdated Show resolved Hide resolved
@@ -976,7 +976,7 @@ protected static function getRefRelatedBySuffix(ForeignKey $fk): string
$localColumnName = $localColumn->getPhpName();
$localTable = $fk->getTable();
if (!$localColumnName) {
throw new RuntimeException(sprintf('Could not fetch column: %s in table %s.', $localColumnName, $localTable->getName()));
throw new RuntimeException(sprintf('Could not fetch column of table %s.', $localTable->getName()));
Copy link
Contributor

Choose a reason for hiding this comment

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

Same as above, should the if move up?

src/Propel/Generator/Builder/Util/SchemaReader.php Outdated Show resolved Hide resolved
src/Propel/Generator/Builder/Util/SchemaReader.php Outdated Show resolved Hide resolved
src/Propel/Generator/Manager/MigrationManager.php Outdated Show resolved Hide resolved
src/Propel/Generator/Model/NameFactory.php Outdated Show resolved Hide resolved
src/Propel/Runtime/ActiveQuery/Criteria.php Outdated Show resolved Hide resolved
@mringler
Copy link
Contributor

@mringler This would then be the last PR merged for the release of new beta this week Is this OK for you?

Awesome!

@dereuromark
Copy link
Contributor

Also, only 981 errors more to go for level 8 then :P

@michbeck
Copy link
Contributor Author

Also, only 981 errors more to go for level 8 then :P

Is this a note to be a volunteer? :P

@dereuromark dereuromark merged commit a5caaae into propelorm:master Jan 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants