tenancy icon indicating copy to clipboard operation
tenancy copied to clipboard

[4.x] [WIP] Add phpstan to CI

Open abrardev99 opened this issue 1 year ago • 5 comments

Continues of PR https://github.com/archtechx/tenancy/pull/926

abrardev99 avatar Aug 30 '22 09:08 abrardev99

FYI you can create branches in this repo for simple PRs. It would work better because then I could check out this branch and easily make changes in it.

So now we'll keep this open until I tell you to merge master into your branch after I resolve the issues there.

stancl avatar Aug 30 '22 13:08 stancl

FYI you can create branches in this repo for simple PRs. It would work better because then I could check out this branch and easily make changes in it.

Sure. BTW, I think you can checkout out specific PR too.

abrardev99 avatar Aug 31 '22 05:08 abrardev99

That's with the GitHub CLI, right?

stancl avatar Aug 31 '22 15:08 stancl

That's with the GitHub CLI, right?

I think GitHub CLI can do that too, but I often use GitHub Desktop.

abrardev99 avatar Sep 01 '22 10:09 abrardev99

I see, I just use CLI git

stancl avatar Sep 01 '22 15:09 stancl

I see, I just use CLI git

not to derail the PR. but you can install git add-ons to checkout PR's then you don't have to leave git.

in git-extras you get git pr

https://github.com/tj/git-extras

more fun stuff on -> https://github.com/stevemao/awesome-git-addons

chrillep avatar Sep 25 '22 13:09 chrillep

I resolved many issues in master and all issues related to resource syncing in #915, so after that is merged there will be only 3 issues left:

 ------ ------------------------------------------------------- 
  Line   Middleware/InitializeTenancyByPath.php                 
 ------ ------------------------------------------------------- 
  55     Unreachable statement - code above always terminates.  
 ------ ------------------------------------------------------- 

 ------ ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- 
  Line   Tenancy.php                                                                                                                                                            
 ------ ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- 
  46     Cannot call method getTenantKey() on (Illuminate\Database\Eloquent\Model&Stancl\Tenancy\Contracts\Tenant)|null.                                                        
  55     Property Stancl\Tenancy\Tenancy::$tenant ((Illuminate\Database\Eloquent\Model&Stancl\Tenancy\Contracts\Tenant)|null) does not accept Stancl\Tenancy\Contracts\Tenant.  
 ------ ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- 

                                                                                                                        
 [ERROR] Found 3 errors                                                                                                 

These are a bit more difficult so I'll try to refactor the code to fix them.

stancl avatar Sep 29 '22 21:09 stancl

All phpstan issues are resolved 🚀 Thanks for working on the CI workflow!

stancl avatar Nov 08 '22 12:11 stancl