This week on the podcast, Eric, John, and Thomas are back to discuss file structure conventions in Laravel, refactoring, new PHP 8 stuff, and much more. * Developer discussions around super simple topics. Button progress. * https://wiki.php.net/rfc/shorter_attribute_syntax * Guy Who Reverse-Engineered TikTok Reveals The Scary Things He Learned, Advises People To Stay Away From It | Bored Panda * US Senators Introduce 'Lawful Access to Encrypted Data Act' — With Backdoor Mandate | News Bitcoin News * SaneBox | Dashboard * Welcome to HEY * Laravel Worldwide Meetup * Playing with TravisCI * Taylor Otwell 🏜 on Twitter: "I've made this PR as a first step to responding to this poll: https://t.co/NYUCFs5y51 ... If you have a "Models" directory all of the model generation commands (and other related commands) will 👏 just 👏 work." / Twitter
This week on the podcast, Eric, John, and Thomas are back to discuss file structure conventions in Laravel, refactoring, new PHP 8 stuff, and much more.
[0:00] That's awful might the worst the best my dad was like make me.
You are listening to the PHP ugly podcast and despite what the title may lead you to believe this is a podcast about the joys and challenges of being a professional PHP developer
your host are three passionate developers who make a living coding and who live stream every week to discuss coating projects work Tech and running a business
and now here are your hosts Eric Van Johnson Jon Congdon and Tom Right Out episode 1 97 of peace be okay I'm your host Erick.
And with me is Tom and John hey guys hello where's our intro oh my God how many times you gonna ask.
[0:55] Every time until you play it is that is that what gets you psyche is that what kitchen I still have that so where's that other intro I had like the it's about to get ugly here we go here's our other intro.
Yeah I can hear it hear nothing can you hear that because I don't have that going to loop back I forgot forgot about that professionals 197 then we have this dialed in by now,
not at all not even a chance not even a little bit
how's everybody doing good we have a we have a short week this week so everybody's kind of winding down you guys taking tomorrow off.
No I have I'm not taking off because I'm working on a project I have this little.
Flow going right now I've been doing a bunch of refactoring and I just don't want to wait until Monday to get back get started again.
[1:48] So I'm going to I'm going to work some tomorrow just to get this little piece done but I love coding man I guess what can I say if I wasn't doing I do have to do some coding on RSC PHP site I noticed there were a couple bugs on there.
So I need to I need to get on there and do do a little coating but I am taking tomorrow off and gonna hang out with the wife and kids go Pride go for a bike ride because we just got the kids new bikes and just,
kind of relaxed been a crazy week yeah I'm getting pretty excited because we have an internal project we've been working on for a while.
And it's getting really really close to like a Beta release and I'm,
I'm really excited I've made I'm proud of myself because I made a lot of compromises on this project but I'm happy where it's at I see a lot of potential in growth for it
but I'm excited something something's happening the Diego there that's ours something's happening to your dog is it okay,
answer your desk you keep banging on your desk.
I'm a happy guy man this is kind of young I'm not like one of these guys with the hands that have to wave around.
[3:05] In the air like you just don't care just not on your desk I worked over the weekend last weekend on a,
code quiz and I'm afraid I might have spent too much time on it.
I was it too much time because you couldn't figure it out or too much time because you were just having too much fun I was definitely having two knives definitely having too much fun.
[3:30] I you know they weren't very specific about what they were looking for outside of it needing tests and,
functional API and I just got into it and I made a view site and I did tdd and I wrote everything out as an API and I got Postman working with it and I have a postman collection for it and,
it's very pretty and works very nice and I submitted it to him
and then I decided Well you know I could do a little more to it too so I hop back on it and I got Travis CI working with it so I got the little Travis badge that says build successful or build failed or whatever,
and I can't understand Travis CI how they're making money like for the work until you for the work that it does.
[4:24] Because every time I pushed out to the master Branch it spun up to VMS compiled and built
and installed everything npm and composer and and then ran all my tests and
gave me responses it's you know had it has a database of a functional database that it writes its stuff into you can write information into I mean it's a full-on system.
[4:48] And it's two of them because it's seven point three and seven point two that I was testing so it does the whole test for both versions and it's got everything that I are using like a free tier something I'm using open source to your because the I wrote it.
To be just you know an MIT license thing it's not really anything
important but like it's doing so much work on this little tiny project every time I pushed out and they're not asking for like my credit card or anything I mean there's like a paid version but.
If you're working with open source it's totally free I mean that's that's their hook right I mean the.
You know I'm sure if it was a private repo you had to pay probably pay to use it and that's who they're going after you know they don't but even then it's a such a small amount it's like 50 bucks a month or something,
I'm just amazed at what to do if we're going to be promoting products on the show we need a we need a kickback,
well and then after I got it I'll working yeah so the the.
Lowest tier which is perfectly good for a business my size or your guys's size the sixty three bucks a month and.
It can do deployments to it has built-in deployments for cloud servers but then you can also do custom deployment scripts and it can.
[6:10] It's basically hosted Jenkins right yeah but it's better than Jenkins Jenkins took me forever to try and figure out and get working.
And this is just like oh yeah create a travesty animal that says I need my SQL and then run my program hmm like it's the it's so easy.
[6:29] So many of those Services out there right now to that do very similar things yeah there's scrutinize errs another one I looked at.
[6:38] That's what we use great dinosaur for a long time.
Everything we're still paying for it now I think we canceled it although I should check that I should check that out so it's just cool to.
Scrutinize their school because it also does code analysis and gives you a grade on your on your your code base so you can watch it change over time.
Yeah I got a 10 out of 10 on scrutinize ER it does a code coverage to a some Travis probably got something similar like that as well yeah.
[7:09] Well with Travis you don't get like a pretty badge for that Travis just gives you the one badge for passing or not passing hmm.
Hear all about the badges well yeah it's to be impressive it's for the GitHub repo so so when do you think you'll hear back from this potential.
Really no idea it's funny you mentioned Travis we actually ran into an issue with one of our projects though the one that we were working on with the new client we're moving forward with like to the next.
Thanks that so it's not so not long-term project but we're just kind of moving to the next step but you know
for our quick kind of deploys and and getting environment spun up for clients to look at I'd been using a combination of Forge,
to provision the servers on digital ocean for us and then on voir to handle the deployment,
the zero downtime deployment system.
Which I don't know in hindsight I'm not even sure why I didn't do that because I had actually written my own script that did it pretty well but.
This allows other team members to go in there and look at it and I don't have to worry about it so.
But we had always used it for one branch like the whatever the branch was that the client wanted to see is what we were what we use it for.
[8:39] Well this now that we're moving to the next stage with this client that we have we've created three environments you know the whole Dev staging production environment.
[8:50] Turns out imma blow your isn't smart enough to know how to deploy two separate environments.
[8:57] Look at this do you see this this is Curtis what I have to put.
Turn your volume up okay Frank thanks for the record my volume is where it's at because this is where these guys told me that to be so.
[9:12] Yeah I don't have to tell you man what issue were you having with on blur.
So I want to hear when you create a project you only have three ways to push to the project or to Auto deploy through on Voyager.
You can do a manual deploy which is you log into Envoy where you hit the deploy button.
[9:34] It will go and grab whatever branch is configured.
[9:39] And and deploy it so we have three projects set up a novel are one for each environment is staging and production.
[9:47] And and ceasing production Dev Dev staging production.
So they're all their separate projects because you have to set them up separately for deployments.
[10:00] So you can either manually deploy with a with hitting the deploy button you can do what's called a push to deploy which means whenever that environment whenever that branch is pushed to,
it will automatically deploy but.
[10:15] That is if you push to that Branch not if you merge into that Branch so if you open a PR and merge the branch that's not a push so you either have to push to the branch and it will auto deploy or.
You can add a web hook and every time every time you do a merge GitHub can fire that webhook.
The problem is that GitHub doesn't allow you to assign webhooks to branches it only lets you assign webhooks to the repo,
in actions within that repo but you can't you can't get granular to the branch.
[10:58] So we can set the re we can set up web hooks so that every time we merged to one of the branches,
it will deploy and we can actually set three webhooks for one for each project but then every time any of the branches get merged all the environments get get deployed which is how we discovered the problem actually
cuz I thought when I was looking I'm like okay so I'm very I must be smart enough to know.
That you know this repo has three webhooks three Envoy your web hooks in it.
And when it gets hit by that webhook it must see what branch triggered it,
and say okay this webhook is associated to to this one project so we'll deploy this one project
but but it's not because all three webhooks get hit in even in you know there's it's clearly not.
Sending the information of what is happening it just saying hey you know emerge happen in this repo so now it it sends all that data they're just saying oh I got a hit and let me
do my thing
I'm not looking at the payload it seems right so we basically turned it off for all the above all the projects and we're having to go in and manually manually deploy which is a little disappointing.
[12:22] So I'm going to be looking at something else I don't know.
I can recommend Travis CI I heard that's pretty good it gives you a cool little badge yeah you get badges you badges badges are awesome.
[12:37] I can tell tell you from burner uses Jenkins in a very similar fashion.
[12:43] So I think it's looking so as you emerge as soon as the emergence but the whole problem with that is your self hosting it you have to set it up you have to maintain it it's just such a pain in the ass I'm not losing to that.
Using something like Circle Ci or Travis CI scrutinize ER might be a better option yeah I'm probably going to look at doing something like that.
No I don't know man or um I'm sure on variable except pull requests,
I'm sure they will but you know why I'm sorry you know it's a paid product he lets it guys are already sending payment requests,
speaking of speaking of Taylor kind of speaking of Taylor I don't know probably for the first time in my coding career.
I I'm in the majority Taylor sent out a tweet on Monday asking how people.
Prefer their models in the app directory are do.
People crave bottles and I thought for sure that I was the minority I'm like yeah I still create the old models folder because it still makes the most sense to me I don't want to clutter my app folder with a bunch of models.
[14:04] Turns out I'm not so much a majority or minority as I thought I was eighty percent of the people said that they use at / models that.
To put all their models and so it was nice to see ya but Jesus did you see the follow-up to that I did not
what's your follow-up yeah so Taylor the fob was going to be Taylor just saying oh well
well no so follow-up part 1 was the tailor had already created and I believe merged the pull request for it
before the voting had ended there
and follow-up number two is he goes and asks people what do you do if you just have a class a normal class do you put that in the models directory now and everyone was like no you can put it in the app directory.
It's just that bottles don't belong in the app directory.
[14:54] What would you have a normal class for that wouldn't have some sort of categorization to well that's what people started I mean.
People started getting on his case about this question basically like what are you talking about what kind of class do not already have a folder for laravel has a folder for everything except models yeah and.
[15:15] He sort of took a beating in the comments on that one yeah not involved I closely that's interesting yeah I'm just saying you have to I mean occasionally I creep I create folders for helpers and traits but
and of course the whole repository pattern but again those are all folders I can't think of any time I would ever create a class,
I'm just throw it in the apps directory the apps folder itself right all right I might be but.
[15:44] Well anyways I think we're up to 720 now oh I need to I need to do some patching.
[15:53] You the patch took us I was Thursday that's supposed to go use the the last two weeks to upgrade my.
Five Dot whatever their of a lap to seven something and I just can't bring myself to do it.
Like you just don't you don't want to see the little birdie leave the nest I mean what the hell yeah it just seems like such a pain in the ass I'm thinking about just it is it all together.
[16:19] Not even using laravel this one and I got it over then another month down the road I gotta do the same thing was it didn't we they don't be then you'll be current and can just do a composer upgrade.
There is such a thing as called composer.
[16:36] I mean you try that try that in your existing project it might actually work although back and five routes weren't even in their own folder back then where are they,
the Bernie bot or whatever not Bernie but what is the Dependable lot and by yeah
we'll only go up to like five something is it wasn't probably won't do major releases because it doesn't it doesn't want to track backwards breaking changes for you so just as soon as everybody's following cimber and.
We'll go up to Major release that makes sense I would give it a shot I don't know what could it hurt.
My pride I don't have any the other problem is I don't have any tests around that code so my my goal for the past two weeks was upgrade laravel add tests.
[17:27] Some sort of CI around it but then he did none of that then other things happen you just.
[17:33] On phone calls for hours on end yeah that's always fun are we.
This week did Sprint planning for the next six weeks right and we got into discussions around a couple of topics where I was just turning my camera off I mean like.
Just shaking like what the like going crazy because in the time we had the discussion I could have written the code that needed to be written it was so frustrating.
[18:06] Such simple topics one of them is around.
[18:10] They want to change buttons in this piece of code and the mock-up they got from a designer showed this button.
With a green gradient switching to a checkbox which which is fine until you think well what if there's an error condition which in the current code base isn't handled at Oliver right now.
a some sort of representation that you click the button something is happening the industry standard is an Ajax spinny
bang right right yes Ajax spinner some sort of Three Dots and then product the product.
[18:56] Person got on it was like absolutely not that doesn't drive happiness so we want we want to Delight our customers sorry condo,
so I want this green box then everybody else is like okay but we can't do a progress indicator because we don't have this idea of any sort of progress so.
We're going to see this green bar go across the button.
But what happened it gets the end and then what we don't have a response I mean 99% of the time you click the button you move on you like you're not even going to see this animation.
The animation going to happen so fast you're not going to see it or we'll start it and stop it in those rare cases where you click the button and it takes two to three seconds because something else is happening how are you displaying the this progress bar what happens.
[19:44] Do you just show the check box and then it just sits there and you're waiting there was there's just no answers but at the same time it would be the whole idea around this.
Showing the boxes was being over-engineered it's like we're making an Ajax called just before you start the animation in the.
Call back the success or failure callback stop the animation it's not that hard
yeah I was actually just shit sharing with John actually Tom I was just sharing with Tom before you jumped on John that I've been spinning I spent most
I've today refactoring code that another developer had developed and,
it's just it was weird it was like one of these things where.
[20:32] Yeah I didn't stumble onto the code I knew that the project manager had somebody else working on a different section of the code but I had made a check I made a change that touched their code that would have been packed
impact of their code and I went in there and started looking at them like,
wait no this is not how I do any of this why why are they doing it like this I
I feel violated because because the project is like 90% of the code is code I wrote and there's a little bit that a couple of other developers Road
but I have I've never spoken to this other developer I'm not even sure who they are
I was like I was like hey yeah yeah I'm not happy with this this is not making me them very frustrated,
if you want to continue receive my services you're going to upgrade your staff there.
Yeah it's been it's I love coding I think I mentioned I'm not gonna get on that big ring and what else we got going on using good.
Nothing good I got I got a ton of things in my Trello board oh I did have something oh you know what I did.
I did run into I actually wanted your input on this Thomas again feel free to step in here so I have.
[21:56] I've been guilty of and I've used this on the last three or four projects it was this recent project I was working on where it really bit me in the ass.
So I read a lot of API consumption job so I'll hit an API I'll get information and I'll you know I'll.
Normalize the data whatever and I typically do stuff with it a lot of times I'll just dump it into the database which is what I'm doing on this project now and.
Because of the way the workflow setup I never know if the record I'm getting is a new record and established record what you know what it is so I have gotten so used to,
update or create so eloquent has this has this method you can update or create you say.
[22:49] Either create if you find the ID the this ID.
[22:56] Then update the record with with the following information if you don't find it then create the record and I've used this a ton
and works well I mean for that for that purpose that works really well what I've discovered is that
that doesn't work on pivot tables though so so these these records have coming in we're breaking them out and different tables down and we're creating these pivot tables so
again in laravel it's pretty simple when I do my update or create a create an object and then I say hey you know you know,
attach this this ID from this other table to this object and that gets put into the pivot table.
And that was I don't know why in my head I thought the pivot table would that that call that attach would automatically say oh yeah I already have this pair already have this definition in my,
my table I'm not going to create it again so it was it was attaching it twice.
Is putting two records on their present how many times around the job's done two three four times we know it was it was quite a few times yeah.
I'm surprised with the pivot table that it's not a unique key like it couldn't.
[24:22] Well I wish I could have made it I could have made a unique key combination in the migration and I did it because I didn't want it breaking.
On the import in and quite honestly I just assumed because and I'm still I still think about it was like okay what Edge case.
[24:40] Would you either a want that to happen the duplication or B1 a hard,
Bill they're like in my head I'm just thinking wouldn't what,
that case always be oh hey I already have this combination in my pivot table
there's no need for me to create it again and I'm not going to give you an error because it's what you wanted so you already have this this pivot record will just move on I don't think that's it I don't think that's a use case I think that,
that's just an incorrect usage well that's what wait what do you mean incorrect usage what I'm saying yeah it is I'm wondering if that would be a good.
Effort to do a PR for for laravel it sounds like it might be a bug for.
Creator insert or update or insert now because this is not even created to updated insert update and insert just creates the first record then he's made so let's do it to calls you're doing create or update and then attached.
[25:39] Right exactly so I understand user I do I create an object called user where I do create an update to the user table I do an object called
tags where do I create or update in the tags and users have tags so then I'll you know I'll I'll.
Do a user attach tag sort of call later,
there's a there's a workaround for this I actually I actually had to create an if statement that says hey if object contains,
yo whatever the relationship is don't do that that's how I had to do it so here's the thing about contains.
Good you need to know this everyone needs to know this contains queries the entire relationship and checks the resultant array set,
for a matching value Y is oh that's that's what I want though no but if I have if I have for example today,
user with 9 million records in a relationship and I want to see if it contains a number 30.
[26:45] Fetches all nine million into memory yeah I see what you're saying I mean that yeah that that would be a container with your problem of scale this connection it's a problem of.
Not understanding and not anticipating because people don't understand that it with eloquent everything else is so nicely implemented into my SQL contains is not part of my SQL.
It is a PHP in memory function and it should not be written The Way It Is Well it's how I worked around this because I couldn't think of any way any other way to do it.
[27:18] Without checking to see if the rate if the relationship are already exists right and then you know doing it so,
it works and in for the use case I'm using for the relationship.
All these relationships are pretty small like the most the relationship will have our two to five relationships.
So it's not it's not like anyone objects going to have in your scenario like a million relationships.
So that's what you think now good point it's a would say it's definitely something you have to keep in mind of what scale it said that that look at that attached and see if I can't figure out a better way of doing that.
The because I better way use case the better way for doing contains is you call the relationship as a method not as a magic property
and then you say we're in and you have the IDS you're looking for and then you count them you get a positive or you're going to true or false out of it well that's what contains gives you now though isn't it but contains dumps everything in the memory first and then checks the array.
For the ID if you do if you extend it as a query then you just further build out the query I mean yeah I could I could I could I could be very specific and do a DB.
Yo Colin Colin of that table and see if that if they key combination exists.
[28:39] Yeah so I mean yeah they're there that's really concerned I can do that.
But I still feel like I still feel like I can't think of a good reason why attached just wouldn't have that as its default Behavior.
Well attached attached creates the pivot record so I know but why would it create the pivot record it's the pivot record already exists.
I think it should check it should check to see hey does this pivot record exists no okay no no because that's sink I can attach 10 of the same thing to a user model oh shit I forgot about sink.
[29:15] But Steve you have to know all of the IDS that you want to sink otherwise it's good Delete all the other tasks right there's also a inspiring that I have that there's also an attached if doesn't exist I believe,
attach if missing have to look at that okay that would that would be cool if that's their attached attached if Miss attached if missing really.
[29:38] I saw something that not sink without detaching that's what it is.
There's a method called sink without detaching and you can add an ID at any time if the ID doesn't already exist.
[29:53] Bro there you go that's what you want that's probably 101 I'd sink makes more sense I always forget about sink sink is actually a better way of doing it anyways yeah but sink without detaching is the same as attached unique
or whatever you would want to call it alright more refactoring for me
I got refactoring to chores out the ying-yang man so I'm funny yeah that's a good one see that's why yeah that's why I bring it up man they use case here is if I go to the library and check out a book.
[30:26] My lot my history of books I've checked out ads that book if I return it and then a month later check it out again it's the same book I get the same attached but it's a different created at date so I have a actual log of the same book being checked out okay
yeah I reviews date,
I don't know about you but I'm I'm using created that updated that or even an ID on my pivot table I have I very much have to.
[30:53] So so then you're you're using soft deletes I assume on those attachments no.
[30:59] The doesn't make sense your example there it's not getting detached like let's say it was an event sourcing style log doesn't attach event a detach event or.
They checked in and checked out action I use pivot tables a ton.
Because I deal in digital content so when a user wants to favorite something that's an attachment,
when a user wants to I don't know view something added to a list send it to somebody else we everything we do is Pivot tables and and we have to display that data back to the user in the order that,
in the inverse order they added things say here's your actions so we have to use dates as well
that's fun and something fun happened over it happened over last week and then I got the results on Monday I guess I got a I got a phone call
my mom who is well in her 70s because I'm well in my 50s.
And you know she's my mother so do the math but she's well into her 70s and she has decided that.
She wants to finish her master's degree so I'm pretty sure she has a bachelor's.
[32:21] And this is something she's piecemealed together her entire life I remember when I was.
[32:26] And Elementary Middle School her going to make classes to get her either her her Associates or her bachelor's I forget but this has been a light lifelong effort for her and.
And she's getting close to getting her master's and she's in so her her kind of focus of study is Medical.
Medical stuff so she's been in the medical field for year ears.
Medical records mainly and she was in the class for medical technology.
And she was given an assignment and she was allowed to reach out to Industry professionals
for input on this assignment it was basically this okay you have five components of a medical workflow,
from when a patient checks into seeing a doctor to going to get labs to a patient checking out your all these components.
You know what sort of Technology.
[33:29] Would you put towards this so that you can track this patient and when the patient goes to check out the facility knows how much the bill the patient.
[33:41] And you know is this where your mom's been calling me so much.
[33:45] No she wanted another date with you she made okay I'm happy how much she enjoyed herself the last time you might be my dad I'm not sure the numbers don't lie but so she reached out to me because use if you're confused
listen to this I am to don't worry she knows she knows this is like my field so what do I do
man I hit her with like oh yeah okay so she's like okay so we already know who the patient is because a patient gets a medical ID so we don't have to worry about that I'm like ah yes but,
everything that happens to that patient every request that has to be fulfilled that for that patient you have to track for billing purposes how are you tracking that
she's like well I don't know we would just say this patient went and got lab work done I'm like yeah but how do you track that lab work,
so I'm like I hit her with uuids I hit her with State machines I am like okay so now you have the lab but that lab.
Everything has a state like
no is the blood being drawn is the blood being tested is that it's the test completed everything has a stink so you need a state machine and you need to know who's touching what and when so you needing head sourcing it's called again so now and they on story short he's out of the will now.
[34:59] She cause she calls me on Monday actually I think it's Tuesday she calls me she say hey yeah I just want to let you know
I got a hundred percent my instructor said she's never seen anything like this before I went above and beyond anything anybody else.
[35:16] She was so gimme she wasn't this is the best great I've ever got in my life this is fantastic
I've never I guess the instructor was like just showering her with with all these Praise of how well she thought about the process and play
the uuids that's how he gets people's like how do you know this this this lab belongs to this patient
you didn't you didn't do this correctly you have no way of connecting those two.
I'm like yeah you know hey it's what I do that's awful might the worst the best my dad was like make me.
Volcano for the science fair and I got a bee.
Just pour beer down it real fast and watch the phone where we're gonna do the whole baking soda that you just like just probably are there really quick just shaken up a little bit.
[36:14] It's experiments on the child responds to a quickly raised hand put a three-part,
foam core board display yeah I think that's the first time I actually feel like that's probably the first time my mom
like realizes I kind of know what I'm doing like I'm pretty good at what I do oh yeah I had an understanding she finally gave you her approval they've been seeking your entire life and now he's in the will.
Yeah that was fun I thought that was really fun so I told her I'm like I want I want I want the paper because she actually had a right all this up
but I want the paper I want it I want to see how you interpreted what I told you it's my grade that's my grade you gonna stick it on the fridge.
[37:06] No since he had a he had a positive mom story.
I'm going to give a negative Monster real quick just because I'm so annoying I want to boy I need a I need to get you've got the best best ones does it start with Facebook.
Yes literally stuff isn't that where they all start oh yeah absolutely.
So my mom posted a we have a BLM demonstration in our little city today sad face.
That's perfect so my sister responds a and what's wrong with that to which I follow up with awesome we took the boys through one in our town Enchanted,
it was a very moving experience for all of us so powerful.
[38:00] So you fed the troll yeah yeah yeah I assume she doesn't agree with that with the whole thing,
she does not sorry but the BLM upsets me all lives matter yep and she went on and on about some other things and I'm like.
You just don't you don't get it you don't understand I shared with Erica very personal story I mean I.
I shared it on my on my personal blog so it's not like it's private but I don't like my personal blog is I haven't posted it on.
I haven't posted on social media anywhere I just I got some stuff off my chest shared it with Eric but it just goes to show the the relationship there and it's
not good not good yeah yeah families are toughie you don't get to pick your family unfortunately you can pick your business partner but you can't pick your family.
Sometimes you regret that to you right straight for the throat,
I don't see anything I don't really I don't regret it I don't know he does the time
never okay that's something I couldn't I couldn't do this without you PHP no PHP no no PHP what about
what about what's bad news in PHP good news in PHP all right we've talked about Alpha One coming out
and an interesting thing happened today alpha-1 got another.
[39:26] Change added another RFC added to it so the next Alpha will not be backwards compatible with the previous Alpha hmm okay why is this good news I'm sorry what am I missing so the attributes.
Functionality heard was added the attribute functional that was added to PHP eight uses.
Double less than attribute double greater then
I did see I did see somebody post about that yeah so so a bunch of people are like well listen this that's a problem because
it's verbosity is too hard to read you don't know which way it should be written the nested attributes don't make sense
and it looks like generics which if you're in another language yeah that's generics that's true plus save it for generics when we finally get it exactly so the RFC,
came out to make it double at at at right that's us and it's just a leading at at it's not a closing at at.
And the RFC past 52 8 and is hugely successful and it's going to be an alpha 2.
[40:39] What are the eight why what eight and why did they vote against it what was the reasoning behind it.
Do you know what you don't get that from the votes I would have to look at internals I was just curious like what's the argument against that.
We had a we had a discussion about it today on it on a call in one of the developers has a very strong Java background it was upset that it was at at not just at.
Then he had explained well PHP uses at as error suppression so is already usage for it.
[41:12] You can't it would have been too confusing you know there's also.
Someone brought up foreign language keyboards where some things are harder to type than others Hey listen
Don't touch don't talk to me about hard to take keyboards okay if I can tape it on this you can tape it or whatever keyboard you're using in your country you just did it again though you just you just lift it up your keyboard and said this what you ended up having to cut an entire segment from last week's episode because of,
I can't like 20 minutes of our show last week John of you talking about your advantage too
Kinesis keyboard which I just lift it up and show to the camera and had I not said that this is a advantage to Kinesis keyboard so that people can
who were might be curious and listening to the audio podcast can look up the see what I'm talking about,
but we talked for like 20 minutes about your you abandoning your advantage to Kinesis keyboard last week and we never talked about,
the keyboard and you just you just showed it and in the camera to us yeah I'm like I'm listening to the podcast from like you know as I'm editing here like.
[42:24] You know what that doesn't really make a lot of sense does it so our podcast that ran about an hour and a half last week I cut down to like 50 minutes.
I haven't got back yet but I have to to try and make the transition next time easier I've been trying to force my fingers over a full key as I'm typing.
[42:48] Hmm that is so difficult my fingers are so programmed for the the cursor movement in them,
a certain way trying to move that off by a full key is just so I still I still hover on my keyboard.
Which is very uncomfortable with this Kinesis keyboard and I have to continuously stop
put my fingers back down and it's so comfortable when I'm in this position and when I'm typing and I've my typing has is it keeps getting better and better.
Every week I still have these Edge weird behaviors that I'm used to I'm still having to find certain key combinations.
That I don't actually remember but but for the most part like just general typing,
I'm so much nicer now it's so and I so happy so happy I'm of them user because it's life is so good for me,
yeah the Kinesis keyboard I'm I'm getting over the hump I'm getting over the hump so I'm happy because it go back to that PHP 8 I also heard I haven't gone and verified at all but,
there is a PHP a Docker container available so you can start testing now.
[44:06] I believe actually that the docker container is part of the build process for any version of PHP now there's a you can yeah so you can,
but what he's talking about is a it's a prebuilt Docker container with eight so what you're talking about Thomas if I'm not mistaken is if you want to contribute to the core there's actually a build system
that's the docker container that will build it from Source in allow you to run Docker and yes you're right with that was actually one of the topics
I don't know if I don't even remember if that made the article in PHP architecting that that was actually one of the topics we talked about when I talk about the maintain when I talked with the maintainers so I thought that.
[44:52] That Docker Hub got a push for a new Docker container when an official release was made and maybe I think that's that's what I think that's what John is referring to right but so that's so that heat the PHP a container
right but Thomas is is Bridging the two saying once they push PHP the new source that auto builds a new container and pushes it up to Docker hub.
Yeah I'll stop saying you're saying it's maintained by them and makes its available as soon as the code is available.
Yeah as soon as there's a pre-release or anything like that.
Well that's good to know but anyway jump you can start testing in your local environments now John I don't you talk about a an article you brought up this week because we talked I think last week or the week before how,
one of my kids have a little brush with tick tick tick tock
theme about a popular yeah and then John shared I think it was either share this article with me yeah yeah I shared it with you and I saw it on your,
on your telephone.
[45:59] I haven't gone too much in depth into what actually happened other than somebody took the time to reverse engineer what it is.
The Tick Tock app is doing and they are tracking so much information.
In the the I mean one of the key components to this for me is that in this is not unique to Tick Tock but
probably more severe with Tick Tock is these are not US based companies isn't it these not companies that fall under regulations in
and laws in The u.s. Tick-Tock is china-based right that I don't I didn't read I believe I believe
I believe it said it was it was trained abased and yeah I forget I forget all it's when that when I read this article and it'll be in the show notes is called guy who reverse-engineer Tick-Tock reveals the scary things he learned the vices people to stay away from it
I'll put this in the show notes but yeah it was I had to uninstall it because.
[47:03] One it's it's a Time sing just like Facebook and any other social media you just find yourself like scrolling endlessly through crap and then.
[47:12] I know this is all of a sudden my battery was just being drained so quick so.
I have an interesting input on this is Iowa's 14 added a feature that raised a lot of eyebrows.
With people and it's part of how this Tick Tock story broke iOS 14 has a little notification pop-up now when an app reads your clipboard that's interesting.
Some people installed iOS 14 and the notification pop-ups just wouldn't go away and I believe Tick-Tock was one of the apps that,
I was reading your clipboard every couple seconds no kidding yeah that's creepy that is scary.
Yeah that's good yeah that's that's gummy as hell I I want that an answer I want to take Android has that I've never not I've never seen that notification you would have to root your Android for that.
[48:13] I mean I can see certain applications would have what like like password applications that.
Will automatically delete the password from your clipboard after certain amount of time I can see you know legit use cases are yeah certain things should never be touched to clipboard yeah
writing writing to your clipboard should always be generally okay.
But reading from your clipboard should be a system operation there's no reason,
any app should just be reading your clipboard that's that's an out of a.
System call and yeah it's it scared a lot of people really fast and Tick-Tock came up in all of that
interesting I didn't want to hear that I mean I I don't I've never even installed it my.
When my kid had her little flirt with Fame on it I went to the website and and woodsy.
See I think is definitely see how it's one of those you know time leeches where you lose track of how long you've been looking at it but.
Yeah that's not for me not my world man you see I don't have to put Doom and Gloom up on the boards anymore because I just wait for.
[49:30] Do you guys to bring it up and I've already read everything about it,
I do what I do want to mention because we've had it on the board for last couple weeks actually the article we have on the board is is not even really relevant anymore but
people have asked why I haven't talked about it in quite frankly we keep forgetting to talk about it's just not that interesting.
But we have a Early Access to hey the new hey malar hey.com yeah the new way that the new way to manage email John did you had did you ever set up your account and use it.
I set it up but it's useless until I can have a custom domain I'm not going to start using my.
Hey.com email address I'm just not so you can't let the one of the limitations chance referring to as you can't send as so and go and just about every other email application you can send as.
And then associate with another email address that you typically have to do some sort of verification process for through and hey that cam doesn't have that right now.
[50:41] There are there are some features in.
But I saw on the video that I thought were very interesting they are workflows that you could Implement in any other mail client.
With with some sort of.
With folder structure tag structure some other discipline ders good filters here yeah but you have to be disciplined and doing it that.
[51:04] They are making kind of more automatic like that.
[51:09] That was one of my Hang-Ups with it I am a long time anybody who's listed the show knows I hate email.
And I won't.
[51:19] I won't checking like I'll go and a day or two and not even check email I think it's a terrible way to communicate now over the years I have actually built a very.
Solid work flow in my email system and we use Google we have a Google domain so we use Google by default and I do subscribe to a service it's not a cheap service
in the reason I subscribe to it is because of all these other services and I've tried a lot of them,
this one has worked best and I'm saying this and now I can't I can't remember the services called it's called saying box same box as a n e Bo X,
I signed up for seeing box a couple of years ago it actually implements a lot of the workflows that hey.com does
and it takes a little training I think I think it took me about a week or two to train the same folders but now in for a long time now
I know that when I go to my box when I go to when I go to Gmail if there's any if there's any emails in my inbox
I will I will read them I will read them right then and there and typically there's never more than.
[52:35] Three or four a day in my inbox I have F 3 folders I look at the inbox which will like I said has an average of three or four emails a day what's called a saying later,
box which is hey these are emails you probably want to look at you know within a day or two but you don't have to worry about and there's a saying news box which is just
hey here's all your newsletters here's all your blah blah blah eyes look at it whenever nothing in here should be time-sensitive and those three folders
I have changed my email experience for the last last year and a half in that methodology is pretty much what hey.com does so it's kind of a bulky you.
I am as much as I tried to train my hey.com.
[53:29] It really didn't work in the biggest thing you have to do is every email that comes in for the first time you have to explain to hey you know how you want to handle that an email from this address
That is just way too there's just too much training going on there I've seen box did it for me pretty quickly pretty easily
I didn't have a problem with it I don't even remember being that that intrusive but like I said it's been a couple years for me now but yeah to John's point you know.
[54:06] There are some other niceties somebody's asking if if it was just a glorified UI wrapper it has nothing to do with Gmail at all it isn't Zone.
Service that they are offering.
The whole stack thing they have gone was intriguing the you can quickly run through your mail and.
I'm going to reply later reply later so that at some point in time when you wanted to sit down and reply to all your email you can just do it real quick,
again all the stuff you can do.
[54:40] Some other discipline but there were there are a couple of UI things that I liked about it one thing I liked and again to your point you probably do it with tags as well but hey made it pretty simple is you could say.
Hey this email this e-mail this email even though they're separate emails even though they have separate subjects these are all related to the same
and so hey hey that cam would start to say okay here's another email for that project stag it's I'm having that with the latest project we have right now I've got so many emails with the client
that when I go to look for something I'm like clicking through all the emails where it'd be nice to.
Group them all together and be able to just kind of scroll through it is that just have a tag that's that's what I do with a lot of our projects I had our clients at least I'll typically have a DD DD /
- client - client name tag.
And I'll set up filters and say hey anything that comes from this domain it goes to this client you know add this point label to it and,
that makes it makes that process easier kind of the same thing but not exactly what he was doing.
[55:55] All right we've already spent too much time on that hey okay and we lost Thomas that's how it's got bored Tom's got bored as I am out of here man I'm sorry Thomas do we do b-boy you Thomas.
No but it just feels to me like somebody making a really nice paid go for app,
we moved on from here but I'm now you have me curious what I was gone for 5 seconds.
That's really that's all it takes in the show we feel he came in a car screaming came up with the Gopher protocol yes yeah
it's dead it's long dead and to me somebody somebody making like a somewhat hacky very corporate rewrite of an email client a web-based email client.
Feels like what are you doing.
[56:49] Why are you wasting your time on this I disagree there's there's got to be a change to email there's got to be some rethink of it and and they're trying and I applaud him for it it they're trying but email I mean fundamentally doesn't.
Do what it was supposed to do maybe Usenet there are some great Usenet clients use that has a huge number of features that are untapped maybe start rolling out custom Usenet servers for internal discussions on stuff or.
Tag one of your crazy idea sure.
I don't want lame ideas which hey is a lame idea and the moment it was announced everyone rolled their eyes and went all try it.
[57:29] When who was the MTV guy who started the whole podcast craze.
Rubbing there was no podcast there was no podcasting there was there was none of that and he was like one of the first ones that was a.
That I knew of who was Adam Carolla Adam Carolla that's right good good car Frank jizo flat Frank Frank and Discord free,
coming in for the Save You YouTube You've Got A Discord
oh YouTube yes so he oh he was like on the Forefront of creating podcasts and you know it was it was going to be the new internet radio and all that in my whole thing was no no no
what it should be is the new email I think about
your family subscribing to like services for each other and that's how you communicate like you don't send emails you you just do quick little you know recordings and then.
You know because now your mom doesn't have to learn how to set up an email or anything they just know the click on this link and they can see if they have any messages for from Tommy Boy.
In the click it and they don't have to read it or anything Tommy is there talking to them and maybe even video and I always thought that people did try that.
[58:51] Really see I always thought that was going to be like that whole RSS feed podcasting thing.
We were going that what's going to replace email like nobody's going to write an email anymore why write an email you just do these quick little hey just wondering if you had a chance to work on that project.
And you know you just subscribe to these different channels and.
[59:13] How is that that was going to be a good night but I was wrong well there was stuff like real audio and they were trying to push that kind of thing
I mean you start going back into the late 90s there were a bunch of people trying to push that kind of tech but it it's imagine if Twitter was built on top of the the SMTP protocol I mean,
that's what hey is trying to do they're trying to,
say hey the protocols fine but the feature sets missing it's like well then the protocols not fine the protocol doesn't support the feature sets you know
read receipts is the perfect example because read receipts you can enable it but no one's going to follow it.
[59:48] Well that's that that's thing and they're not even addressing
the real issue with email the security aspect of it and there's nothing there's nothing about hey.com it's any more secure than just regular email,
right well so and I mean even even better there's a lot of advancements made an email about having to digitally sign stuff having double opt-in procedures
all that kind of stuff to catch spam but now instead of spam I have a thousand emails,
over the last two years from one company telling me what their daily deals are or what they're there for mm breakdown for the day is,
and there's no system in place to say hey these emails expire after 24 hours in the next one is the one that's important so something has that by the way
oh my gosh yeah saying it's insane has folders that have that anything that goes in that folder has an expiration date on it
sure but that should be part of the protocol if I'm sending if I'm sending someone a receipt it should have a receipt meta tag on it.
[1:00:54] And the client says I received receipt I'm going to store it in a permanently archived location and not bother you with it or you know email actually has a high priority flag did you know that,
like part of the SMTP protocol but no one's used it since 98 because everybody was using everything hyper right so like,
we've built an entire ecosystem out of something that was not meant to be an ecosystem and it's ended up looking exactly like.
[1:01:25] The truck mail in your mailbox everyday.
Except that you receive four hundred of them a day instead of three mmm and my wife Fox my wife ran out of space on her Google account and I told her hey did you know.
[1:01:42] You've got 50,000 unread emails she was she goes yeah is that a lot like
that's a lot that's a lot of unread emails because you've got a hundred thousand read emails like
the protocol itself is fundamentally flawed there was a time where Bill Gates was talking about you no one sent to send an email and that didn't pan out because cryptocurrency didn't exist and there was no way to properly bind into it but now.
The tech is moving in a forward Direction you don't you can create an SMTP bridge to your new
fangled system and handle that with a much stricter control but there's no reason to stick with email email sucks absolutely agree,
what we said when you stood up was.
We've talked too much about this already let's move on but it's the least mature of the currently used protocols all right so earlier I talked about helping my mom with with her
her paper last week we talked about pie hole and I mentioned.
[1:02:48] You know that's a pretty good idea I should do some testing with pie hole and pie hole is this DNS service you can run on a Raspberry Pi that will automatically block a bunch of ads and things like that
so I thought well you know I should test that and if it works I would love to put one of those out at my mother's house because she's very bad she
she's one of those people that have like four toolbars in their browser back in the day or five toolbars in a browser bang they she clicks everything she does Banzai buddy.
[1:03:22] Yeah so so I did some testing with my Raspberry Pi for which I don't even know where I have that at right now but.
And I'm like hey this works really well but like a Raspberry Pi for I don't think you need that so.
[1:03:37] I ordered a pi zero in this thing,
rocks I put I put pie hole on it the only problem is so it has Wi-Fi so I did the testing over Wi-Fi but it doesn't have a network connection so I ordered a micro USB network adapter for it
but it works so well.
It was so easy to install and so easy to configure I think I'm going to put it here in the house like I have F to I have this one and then I have another one and I've already imaged this
this little drive that I have is this memory drive I have I've already imaged it so I can just blow it down on this other one and these things
freaking fantastic man.
[1:04:26] I mean even over Wi-Fi it was working pretty well but I want a heart I want to hardwire it so I don't have to go because I'm not going to I mean here at the house I wouldn't worry too much about it but,
my mom says I don't want to have to worry about it some of the hardwired to their network but dude Raspberry Pi Zero Man.
Piehole do it it's awesome I I'm I'm putting this one at the house I mean there's just I can't I have no good reason not to do it I don't have to worry about.
[1:04:54] My wife my wife please others games on her phone and they're littered with ads so.
I'm kind of curious of how much it catches.
It catches most game ads yeah I've I do I run it on my run a mini version of pie hole on my Android.
Called a block Adder mmm and it very successfully blocks ads on everything yeah I was happy in the interface is written in PHP.
Sir changes your your DNS on all your machines that connect to your Wi-Fi to it and then it connects to
so it's connected to it has the DNS assigned to it so I'll just configure it for Google's DNS that's actually a step.
In the configuration process it says okay what DNS service do you want me to use and I descended up for Google would be a mess,
so if you do that you don't get the best stuff I use add guard DNS I don't remember a guard was one of them it had like five I was I was actually looking for the one.
I was hoping they had the one from what's the one one one one one Cloud slab.
[1:06:10] Cloudflare yeah I was hoping they have that one but if they did I didn't recognize the name like I said they had about four or five of them from the list,
so so the answer your question John that has a penis and then what you do is you go to your Wi-Fi and say okay any automatic DNS settings you dish out,
you give him the pie hole IP address so you give the pie hole static IP,
now of course like I'm pie hole has a lookup log to so you can see what has been looked up.
And block and Blacklist or whitelist the domains right in like said that whole interface is written in PHP which is I want to get in there and take a look at that and see.
If they're using the Frameworks anything but.
So but like you and I are I assume you still have yours configured manually to use Google so ours would actually.
Bypassed the Bots the pie hole because I don't get DNS automatically assigned to my laptop.
My wife does my wife's phone my ways you can still do it you can actually you could do a MAC address Booth what do you mean because it's acting as.
[1:07:26] Part of your well actually you have to do that through your router right in your end your router you can spoof the MAC address of an IP and so,
if someone does try to use a custom DNS it'll still wrapped a pie hole
interesting yeah I never never thought much about it so I'm sure you got it in the middle you could also route anything going out to Port 53 you could redirect it there's lots you could that's true yeah that's true.
So yeah I'm actually very stoked about it I am I'm really happy about it I'm looking forward to get my little I was hoping to have my little network adapter and today so I can I can test it but.
Adult so I'll have it next week Travis these are awesome.
[1:08:15] Pi 0 man got off the Amazon Emily I think you could order pie zeros I thought they sold out like everywhere and I just went to Amazon it's like oh yeah right here it's like I think it was like 20 bucks for the whole for the heat sink the case.
The pi 0 it even has like.
[1:08:34] It has a adapters for HDMI crap like that but I don't I don't need any of that I just needed that the one thing I did need to see a network adapter didn't come with that,
tell me we're running along in time but I really have a doom and gloom in here for for Tom oh that's hoping he was I didn't see it.
[1:08:58] I figured you were the one that killed this one I know for next year's description Point um John do you want to talk about it just,
bring it up I saw this at a again I haven't read enough into it I was hoping you had more information but US senators introduced lawful access to encrypted data act we I know this is come,
up on and off for years where lawmakers are trying to,
basically break encryption and it's so effing scary and this is basically they basically they did it they're they're they're demanding that all encryption on all devices have a back door.
Master that's introduced I thought I was under the impression that passed.
[1:09:42] No it hasn't passed it's been introduced it may have passed one stage of the process but it's never going to get all the way through interesting I thought the reason I put it on here was because it passed but that's good
that gives me hope that gives me hope yeah this is terrifying stuff though.
Yeah everything I'm saying is it's just introduced it nothing that it's passed yet yeah so the the endgame here is unlocking iPhones there.
They're not as concerned or they're not at all concerned about real encryption they're concerned about unlocking someone's iPhone and.
This is this is one of those Dubin glooms that I can't worry about because it's almost completely unenforceable it's almost technically impossible because
if you have something like AES encryption or any existing encryption technology you can't just add a back door to a math problem it's not possible.
[1:10:42] You would have to you'd have to mandate duplication of keys and having one of the keys automatically sent to the NSA or whoever I mean it's one of the arguments though that they're the one of the arguments is that if they make this that,
encryption is going to get weaker because not just Waker it'll destroy encryption.
Was again this is the argument this is the argument from from people in the fields like listen you're not going to be able to build back doors for company for governments to get in there in only have it for the u.s. government first off
all governments will take advantage of it right second half to even build the back door you have to encrypt you have to Cripple the encryption which means that that
that surface Vector is going to be much simpler for
actual hackers to attack at this bill is being written by the same people who are also saying that we can't install.
Highway or Y way 5G infrastructure because it's.
Sending data to the government of China like well what do you think they're going to do if we put a back door in anything made in America they're going to ban use of all of our technology all over the world it's,
I can't worry about this it's stupid and if it happened it would be monstrously bad but it's so.
[1:12:01] Dumb and misguided.
That it kind of just can't happen if they got the law passed there would be challenges to the Supreme Court immediately from Apple Google Microsoft Amazon and those challenges would go on for 20 years.
And they would probably win,
because forcing a company to break encryption violates the privacy of every user on the platform so I mean it's I see the Articles come up everyone's saying like this is crazy this is stupid and I'm like yeah it is crazy and stupid don't pay attention
it's not worth your headspace really,
I'm in Gloom that he's that he's somehow makes not even glue that's it's a it's a bummer that people,
that the people in power are so unaware of how technology works that they want to do this but they'll be dead by the time the litigation on it ends,
and hopefully it will be repealed by the people we actually put in power after them because they'll understand things better but like this is a fight that's going to go on for 10 15 20 years
I don't want it in my head for that long
I just like there are much more pressing concerns the New Orleans Police Department admitted that it has a 94%,
false positive on facial recognition worry about that don't worry about this.
[1:13:23] This is stupid and no one would abide it all right I'm not going to worry about it let's move on if I don't,
oh there's nothing I don't think we can move on and I think it's a wrap it up sort of time what do you think I I agree I agree except in fun,
except friend of the show freak pulled up the wrong damn,
slightly different method you're going to patreons fun of the show for the show freak van hurting announced at the there will now be a monthly laravel worldwide Meetup hosted on YouTube and.
It's going to be cool so go and subscribe to that that that's in the show notes as well as well meet up that laravel.com.
[1:14:10] I assume this has some sort of blessing from Taylor if it's on the laravel.com domain.
Well it's freak vendor hurt and so like he could say to Taylor hey you know if I for Clerval and called it better laravel you would lose all of your clients yeah
I mean this is Kawaii know in this day and age where conferences are going online you know of monthly worldwide laravel Mina yeah I don't see why not you know,
um we're baritone.
It should be fun I just hope they have better production quality than late-night TV which for some reason doesn't know how to ship a camera and microphone and laptop to somebody.
[1:14:52] It's scary that I think we have better production values and some of the late-night TV P significantly significantly better what's this A horrifying thing yeah our content our content still sucks but you know our production value.
[1:15:05] Production value has gradually scaled up over the hundred and ninety should seven shows that we've put together.
I think that's it we're going to do is speaking of episode 1 97 which I actually don't even if that's really the episode is that where we're at yeah 197 that's it in the can we're out of here I'm Eric,
I'm John I'm Tom thank you patreons keep my lovely patreon damn it.
[1:15:38] Thank you me trance keep it only Kevin Romanians thanks for listening to the PHP ugly podcast.
If you would like to support PHP ugly check out our patreon at www.payoor.com PHP ugly
you can also follow PHP ugly on Twitter at PHP ugly or join us in the PHP ugly Discord Channel,
show notes an RSS feed can be found at PHP ugly.com.
To catch the live stream be sure to subscribe to our YouTube channel at www.youtube.com PHP ugly
you can also subscribe to the edited podcast on iTunes Spotify or your favorite podcast catcher of choice a reading of five stars is always appreciated,
and finally thanks to our sponsor the Diego Dev group if you are looking for developers who care about the code they create
the communities they built and the solutions they Implement then reach out to the Diego Dev group at Diego Dev.com.
[1:16:37] Until next week keep it ugly.