-
Notifications
You must be signed in to change notification settings - Fork 0
Cleanup phpstan baseline issues #308
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
base: develop
Are you sure you want to change the base?
Changes from all commits
a918d19
a87c372
46568d3
ab97436
034d11f
8745620
07962e6
46879ef
3257d79
55b61fd
42bc2bb
d2387ed
1a57db2
e88fed3
57b4c62
8e7187d
67acde1
afe5e53
549158f
7310f16
0ce5e1f
90d9e28
8ade5ff
d19f434
698f185
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,7 @@ | ||
| parameters: | ||
| level: 8 | ||
| paths: | ||
| - src | ||
| - tests | ||
| excludePaths: | ||
| - src/Kernel.php |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,41 @@ | ||
| <?php | ||
|
|
||
| declare(strict_types=1); | ||
|
|
||
| namespace DoctrineMigrations; | ||
|
|
||
| use Doctrine\DBAL\Schema\Schema; | ||
| use Doctrine\Migrations\AbstractMigration; | ||
|
|
||
| /** | ||
| * Auto-generated Migration: Please modify to your needs! | ||
| */ | ||
| final class Version20260517131038 extends AbstractMigration | ||
| { | ||
| public function getDescription(): string | ||
| { | ||
| return 'Make columns nullable on synced entities (issue/project/version/worklog) and on app-managed DateTime fields (project_billing period_start/end, service_agreement valid_from) to match PHP property types.'; | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't like the idea that Claude edited this file. Description is not filled out when doctrine generates it.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Claude only wrote the descriptions. |
||
| } | ||
|
|
||
| public function up(Schema $schema): void | ||
| { | ||
| // this up() migration is auto-generated, please modify it to your needs | ||
| $this->addSql('ALTER TABLE issue CHANGE name name VARCHAR(255) DEFAULT NULL, CHANGE project_tracker_id project_tracker_id VARCHAR(255) DEFAULT NULL, CHANGE project_tracker_key project_tracker_key VARCHAR(255) DEFAULT NULL, CHANGE link_to_issue link_to_issue VARCHAR(255) DEFAULT NULL'); | ||
| $this->addSql('ALTER TABLE project CHANGE name name VARCHAR(255) DEFAULT NULL, CHANGE project_tracker_project_url project_tracker_project_url VARCHAR(255) DEFAULT NULL, CHANGE project_tracker_key project_tracker_key VARCHAR(255) DEFAULT NULL'); | ||
| $this->addSql('ALTER TABLE project_billing CHANGE period_start period_start DATETIME DEFAULT NULL, CHANGE period_end period_end DATETIME DEFAULT NULL'); | ||
| $this->addSql('ALTER TABLE service_agreement CHANGE valid_from valid_from DATETIME DEFAULT NULL'); | ||
| $this->addSql('ALTER TABLE version CHANGE name name VARCHAR(255) DEFAULT NULL, CHANGE project_tracker_id project_tracker_id VARCHAR(255) DEFAULT NULL, CHANGE is_billable is_billable TINYINT(1) DEFAULT NULL'); | ||
| $this->addSql('ALTER TABLE worklog CHANGE worklog_id worklog_id INT DEFAULT NULL, CHANGE worker worker VARCHAR(255) DEFAULT NULL, CHANGE time_spent_seconds time_spent_seconds INT DEFAULT NULL, CHANGE started started DATETIME DEFAULT NULL, CHANGE project_tracker_issue_id project_tracker_issue_id VARCHAR(255) DEFAULT NULL'); | ||
| } | ||
|
|
||
| public function down(Schema $schema): void | ||
| { | ||
| // this down() migration is auto-generated, please modify it to your needs | ||
| $this->addSql('ALTER TABLE project CHANGE name name VARCHAR(255) NOT NULL, CHANGE project_tracker_project_url project_tracker_project_url VARCHAR(255) NOT NULL, CHANGE project_tracker_key project_tracker_key VARCHAR(255) NOT NULL'); | ||
| $this->addSql('ALTER TABLE worklog CHANGE worklog_id worklog_id INT NOT NULL, CHANGE worker worker VARCHAR(255) NOT NULL, CHANGE time_spent_seconds time_spent_seconds INT NOT NULL, CHANGE started started DATETIME NOT NULL, CHANGE project_tracker_issue_id project_tracker_issue_id VARCHAR(255) NOT NULL'); | ||
| $this->addSql('ALTER TABLE project_billing CHANGE period_start period_start DATETIME NOT NULL, CHANGE period_end period_end DATETIME NOT NULL'); | ||
| $this->addSql('ALTER TABLE version CHANGE name name VARCHAR(255) NOT NULL, CHANGE project_tracker_id project_tracker_id VARCHAR(255) NOT NULL, CHANGE is_billable is_billable TINYINT(1) NOT NULL'); | ||
| $this->addSql('ALTER TABLE service_agreement CHANGE valid_from valid_from DATETIME NOT NULL'); | ||
| $this->addSql('ALTER TABLE issue CHANGE name name VARCHAR(255) NOT NULL, CHANGE project_tracker_id project_tracker_id VARCHAR(255) NOT NULL, CHANGE project_tracker_key project_tracker_key VARCHAR(255) NOT NULL, CHANGE link_to_issue link_to_issue VARCHAR(255) NOT NULL'); | ||
| } | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,45 @@ | ||
| <?php | ||
|
|
||
| declare(strict_types=1); | ||
|
|
||
| namespace DoctrineMigrations; | ||
|
|
||
| use Doctrine\DBAL\Schema\Schema; | ||
| use Doctrine\Migrations\AbstractMigration; | ||
|
|
||
| /** | ||
| * Auto-generated Migration: Please modify to your needs! | ||
| */ | ||
| final class Version20260517151632 extends AbstractMigration | ||
| { | ||
| public function getDescription(): string | ||
| { | ||
| return 'Make ManyToOne foreign keys nullable on entities whose properties are typed nullable. Aligns DB schema with PHP property types; application/validation layer still enforces required-ness on app-managed entities.'; | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same as above.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Claude only wrote the descriptions. |
||
| } | ||
|
|
||
| public function up(Schema $schema): void | ||
| { | ||
| // this up() migration is auto-generated, please modify it to your needs | ||
| $this->addSql('ALTER TABLE cybersecurity_agreement CHANGE service_agreement_id service_agreement_id INT DEFAULT NULL'); | ||
| $this->addSql('ALTER TABLE invoice_entry CHANGE invoice_id invoice_id INT DEFAULT NULL'); | ||
| $this->addSql('ALTER TABLE issue_product CHANGE issue_id issue_id INT DEFAULT NULL, CHANGE product_id product_id INT DEFAULT NULL'); | ||
| $this->addSql('ALTER TABLE product CHANGE project_id project_id INT DEFAULT NULL'); | ||
| $this->addSql('ALTER TABLE project_billing CHANGE project_id project_id INT DEFAULT NULL'); | ||
| $this->addSql('ALTER TABLE service_agreement CHANGE project_id project_id INT DEFAULT NULL, CHANGE client_id client_id INT DEFAULT NULL, CHANGE project_lead_id project_lead_id INT DEFAULT NULL'); | ||
| $this->addSql('ALTER TABLE version CHANGE project_id project_id INT DEFAULT NULL'); | ||
| $this->addSql('ALTER TABLE worklog CHANGE issue_id issue_id INT DEFAULT NULL'); | ||
| } | ||
|
|
||
| public function down(Schema $schema): void | ||
| { | ||
| // this down() migration is auto-generated, please modify it to your needs | ||
| $this->addSql('ALTER TABLE invoice_entry CHANGE invoice_id invoice_id INT NOT NULL'); | ||
| $this->addSql('ALTER TABLE worklog CHANGE issue_id issue_id INT NOT NULL'); | ||
| $this->addSql('ALTER TABLE product CHANGE project_id project_id INT NOT NULL'); | ||
| $this->addSql('ALTER TABLE issue_product CHANGE issue_id issue_id INT NOT NULL, CHANGE product_id product_id INT NOT NULL'); | ||
| $this->addSql('ALTER TABLE project_billing CHANGE project_id project_id INT NOT NULL'); | ||
| $this->addSql('ALTER TABLE version CHANGE project_id project_id INT NOT NULL'); | ||
| $this->addSql('ALTER TABLE service_agreement CHANGE project_id project_id INT NOT NULL, CHANGE client_id client_id INT NOT NULL, CHANGE project_lead_id project_lead_id INT NOT NULL'); | ||
| $this->addSql('ALTER TABLE cybersecurity_agreement CHANGE service_agreement_id service_agreement_id INT NOT NULL'); | ||
| } | ||
| } | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I get that this is a big PR, but the size of this entry hurts my eyes, along with the overuse of backticks.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done :)