Okay, so hello, I'm alexandre bourgeois director of development at saouafali nukes This is gonna be pretty quick and so just get your brain straight and look at the screen Okay, it's gonna be a demo. I have a lot of stuff. I never timed it So I'm just gonna rush and look out how long I have okay. I'm a bit tired. So I might do a lot of typos So we'll start see I have that I never did that before slide. Okay. I have a couple questions I want to know who you are. I wouldn't tell me who has some PHP background. Raise your hand Okay, who has some Python background does Python. Okay. Okay who who heard about or read about pylons before oh Wow, so you use that who who use that? Okay Who worked with Django previously? Okay, so a bunch of Django guys who knows virtual and easy install Pip the replacement for oh Okay, and who does the web development with Java or did Yeah, of course, of course did okay. Okay. Thanks, and everyone knows what an MVC framework is Okay, raise your hands. Just I have a good. Okay. So I want to explain that Okay, good I'm just gonna quick start with a little comparison between Django and pylons just to set things I'm not gonna bash on Django. Just have a little difference Okay, so Django is the all-star see it's one single thing It has a norm to deal with databases URL dispatcher has its own forms manage Which was are pretty good and request object authentication system and templating language It does it pretty well it even plays guitar or almost and whoop now I'm screaming the thing and It has a lot of marketing and a hypes in so and pylons is more like the milky way You have the best of the breed components from elsewhere See see what take pick up the best templating out there engine out there and it's wired into pylons So pylons by itself is about thousand a thousand lines of codes and Mako Now you choose your I'm gonna have a little demo here so if you want a good or I'm go and get the best of the breed and plug it in wire it in and So poof see you have like for example Mako Jinja again She ensues your authentication system. There's many out there, but you can wire them very easily and The strength of Python will see it's because it's WSGA by GI based Okay, what's for web stand server gateway interface. We're gonna see that in a moment Okay, just how I didn't screw things up Very good Okay, so over here. We're gonna see we're gonna see pylons. What's WSGI and what we can do about it controllers templates mode So the MVC MVC here. Okay, this is the view and we're gonna see a lot of demos and some fun stuff We can do with with pylons being a WSGI framework Yeah, that's horrible just to follow Okay Now we're just gonna set up the environment We assume you have virtual and even pick you're not gonna do that with me But we have that already installed you can install pip with easy install. It's pretty nice thing. We're gonna do that together Okay very good Just so you pip a little bit here if you pip help you have a bunch of new Functionalities which are pretty cool like bundle you can have a bundle which is many packages all bundled into one file You can deploy that on the machine pretty cool and freeze your feature like build out system You can freeze all the requirements and all the versions in a file and then you can install from that You can have like a subversion and git and Repositories listed in there with specific version So when you check out or install a new environment with pip while you can or a new installation You can unfreeze those version right into your environment So you can follow and notice here the uninstall which was lacking to the easy install world, huh? No easy uninstall so that's pretty cool, too Okay, now we're gonna create a virtual environment okay virtual and we're gonna specify we don't want no site packages So we don't mind of the Debian distributed packages, okay? We want an isolated environment and we're gonna call that pylons and it's gonna be created here and let's look into it it's pretty quick just drops a couple of files and See you have a little sub architect sub here hierarchy here Which have sim links mostly and sim links to the standard library and a bunch of file like pip and python and you're gonna activate that with Activates notice here the pylons and now you're in the environment if you run python from there well and import OS for example You're using the one in the environment, okay, so you can isolate all your packages right there, okay? So we're gonna use that and And Poof very good I'm gonna just show you what WSGI is now I should see that There you go. Thank you Okay, so what's WSGI WSGI is? Java servlet, okay? Specification it's a pep 333 so it's standard in python. It's the way you deploy web application It's the standard way to deploy web application some of you might have been there when I present that as a flashbook So it's a bit I need to stuff it in so it's complete mode. Okay, so for example, you have Apache here and That worked Apache and with mod WSGI which is loads the interpreter here. Oh Shoot That's bad. Okay, that had to happen Okay, this way here Okay, so it's gonna load the interpreter and then run your program which contains WSGI We're gonna see what the WSGI application is it's gonna run that and loop until some client outside Go and get something goes through Apache hits your program knock knock and it's gonna call the application here So it's gonna call the actual python object and it's gonna populate a special environment Which looks like CGI variables or what you get in under dollar underscore server act happen when in PHP So if you call when you're gonna call the application like that with two variables It's a very simple spec and wait for the response and deal with it and send it back to the user. Oh, yeah They're very happy user Okay, the application looks like Three modes of first application mode. You can you just have you just need that It's a callable and it returns something that iterates So in a terrible that's gonna be a generator and at some point it has to cost start response If it's going to return something it well, it should do something. That was just a hello world That's the environment variable. That's passed on and contains the request on the server part Well, you have this and you're gonna create the environment call the python app deal with the response and now middleware that's nice stuff because Just like serve like can be stacked together and give Functionalities you can do that with WSGI for example We're gonna have an example so this acts as a server to that application this one acts as a server to this one While this one acts as a an application to the server very good. We don't okay So let's look here I have a request coming from the web and so we all want to get something it goes through ever middleware Which is the stack here? That's a stack. Good. It's gonna go through Come on Session middleware and the session is gonna fetch from the from the drive based on cookies and add some session data To the environment variable it's gonna be passed on to my application We're just gonna do something or crash and if it crashes It's gonna go back to the session middleware with an error. That's my error Okay, and go to the error and error middleware is made to handle errors. It's going to Produce a nice a beautiful page and send it back to the user Unbroken and you can even have further requests and go back and forth between the error middleware so you can debug interactively We're gonna see that that's awesome. Well, that's in the pylons framework That's the end here now Okay, we're gonna install. I think I should go back manually. Okay. Sorry for that. That's horrible Okay, okay. Now I'm going to install pylons Okay, only doing that here Will install it's going to download the packages from the web, of course, you know whoop. I don't care I have squid 3 and I have all the package installed Oh Where did I do that pip install? Oh, yeah, sorry, okay So it's going to install so I just gonna shoot the command once more it's going to install down all the dependencies and all this stuff And put that in my environment in my local So it has installed all the dependencies with pip install that allowed me to just download and not install right away, okay? So Now the next thing pylons uses so as I said pylons is a thousand lines It's really glue and just a way of thinking and bundling things together So pylons does not do deployment per se. It uses pacer, which is an awesome deployment to a Swiss knife it's another Swiss knife and so you have to and So for example pacer is going to deal with creating a new application is scaffolding in the rail in the rails world And it's going to serve the application pacer has a production ready a web server and like Django Which you had to you have to host somewhere else because of the run server doesn't isn't Solid enough to serve on a okay and set up up to just set up the database and create the temporary directories for example Okay, so that's what pacer does so we're going to look at create here and create can list Templates and we see we have two templates pylons and pylons minimal So we can have two kind of projects and you can build those you can say I have all those files built and it loads that plug-in Loads that system and I want to be able to start off with that Package next time so you can do a pacer template and load it like that. So I'm going to create whoop create See I slept very well Pylons and we're going to just get out of here You don't have to be under the environment to deal with that. It's just activated So pylons, we're going to call it MTL pi. Okay. Okay. Now we're being asked A templating language see we can use Mako Genchi or Jinja to let's have a look at those things This should have been automatic Okay, so here's Mako an example. It's more line-based very powerful very fast It's you can insert. Oh, that's very Pythonic. It uses Python syntax Those lines will be rendered as HTML and you can render any type of files csv or will have you okay? So sample Mako and Jinja to this is more like a port of the Django templating system Which is I think more powerful on the guy who did that wanted to add some functionalities So a lot of Django people want to use that in Django because it's better. So use that syntax You can wrap it around pretty neat and Genchi, which I find pretty cool to see you use those Fake HTML tags and it it's gonna deal with the line It's not you don't have to specify and for it's just gonna loop in the structure there So it's not going to display if there's nothing in the links. That's nice Okay Can't follow that Select Mako Okay, so we're gonna select Mako because it's nice and I'm used to it and I love it and now SQL can be here is An orm so object relational mapper. It deals with database interfacing with Python It's a very awesome package And you would like to learn it right away because you can use that in pylons But in all your other database needs you don't depend on pylons unlike the Django orm Well, you're you're tied to Django. You can't use it externally something like that or with a lot of us I'm gonna put true here and in mtl. Sorry Is that the next thing an mtl? We'll have our pack or We're gonna see that right after I just want to start with a demo of SQL alchemy. All right It's in fact an extension called SQL soup That helps you introspec databases already existing databases and you can just Okay, and you can discover from the inside and use it object-oriented interface to your data So to do that we're going to create a quickly a From scratch a database. Oh wait a second we need to install SQL alchemy there we go downloaded from the web and install all all right And we're going to create that database so super db.sqlite create table users with ID integer primary key auto increment and First name varkar something like that. You used to that varkar to 5 5 last name varkar to 5 5 Oh, see I knew there was something you know the syntax for a Auto increment. Oh There's the underscore here. Oh Okay, that probably be okay. Let's take it out Cuz I I didn't test it with the auto increment anyway, okay, so insert into user. We're gonna add some values So ID one Alexan Something like that, huh, and then I want to change that for alt one was my brother Oh, yeah, I have to put that too and then somebody else. I don't know Bob Dylan okay, there we go. So we could select from the database, you know, SQL SQL light tiny database It's a library from users here. We go and There okay, we have that file Super db sqlite Wacky's my username Okay, now let's go with SQL soup. I have a python here. We're gonna import from SQL alchemy From extension SQL soup import SQL soup and we're gonna create a connection to soup So SQL alchemy is also a database instruction layer. So it deals with any database in the background oracle and you name it Okay, so here we just specify super db sqlite and s discovers automatically that there's a table of users And you can query them and It's gonna return objects where you can access the elements inside and SQL alchemy has that neat pythonic syntax to query it So if you do for example users dot id equals equals one You don't have to specify id underscore underscore and all sorts of creepy stuff It returns a binary expression because the python allows you to do that I don't know why some people didn't do that and if you print it out or cast it to a string It's gonna be returned like that and you can pass it as a parameter users See whoa, what's that query? No Filter sorry Filter and that gives you a query a full query and you can run it with All or put in a loop so it's an iterator. So you got the element here. Okay, that's pretty neat. Isn't it? Okay, thank you Now we're running pretty fast, aren't we we'll have a lot of time for questions Are you following? Okay, good pace So now let's go and look at the files No, is it all right? I'll try to slow down. I have a little difficulty with that So let's just look at the files in our project here So you have an egg ready set up the py you can pack you can you can Deploy it on pi pi and French is pee pee. Okay, so and it's ready to go You be disted upload and it's ready to go. You have those So let's say the model here. I didn't explain the model here You have anything you want here was going to be SQL alchemy stuff But you can have anything you want to go to data flat files a couch DB kit for example and grab your data from anywhere It's a generic term model. So you store that in in it now the controllers We will have your controller data here the business logic stuff So you can name it you have several several of them and each controller is a wsgi application. Okay, and we'll see that's cool Now in templates, you'll have all your templates Which are basically what you want Mako templates or Genchi templates or flat files if you want and in Lib Well, it's just a convention here So Lib contains all your things you're going to use for in every controller base For example contains things you're going to use in a controller's helpers You're going to use in the templates most of the time so load stuff you're going to use with h dot For example trim or cut to words and put your trailing dots stuff like that and app global This is where PHP gets blown off. You have an actual application running and it keeps its state You have a Python program running and it requests coming in and app global is shared between all threads all requests coming in Shares app global and you can have some cues in there So you can share data between those threads for example having a somewhere a jabber connection and it's Spits out data to the different threads and you have the user connecting. So that's pretty cool You can't do that with PHP unless you you spit that on the disk serialize, but then I'm in cash D and stuff like that Okay, config you'll have all the config configuration. Mostly those things not going to change a lot rootings routing Sorry, you're going to route for example this URL to that controller slash foo goes to foo.py and You have a pretty powerful engine called routes and actually it's an external project just tie it in here because it's the best Yeah, okay Environment is just one function that's going to set up like load the database connect and start up your things middle where we're going to see the moment and Test stuff public is going to get served and yes with pylons You can actually serve your media files with pylons You don't have to use some other means because it's not safe or something like that Not looking at any place anywhere. Okay, so we have the database and we're going to see that any file Which is just the configuration files any files. Is that clear? Sorry, I'm giving a lot of Course these times. So is that clear you have you understood have questions if you want to stop me at any time you can just scream Okay, I'm speaking loud. So you just scream and say what's that or okay? Don't be shy. Now. Let's go and look the middleware MTL pi config middleware no CD come on The middleware file is I don't know if you notice a little bit earlier that my app See you have your WSGI stack here That's the actual application the one we're building and it's stacked with the routes middleware Which does that URL? Directioning and the session middleware where it's going to load from disk data according to the cookies and the cash Middleware if you don't want that anymore, you just stack it out and of course a little bit like other MVC frameworks And you have that awesome error handler Which does like I said you can debug interactively if you put that on production of course You're not going to put the error handler and that allowed a people to import OS and OS dot system but it's very useful for debugging registry manager and You can serve here if you want static URLs in public and you just return that application That's your WSGI application the stack is built and each application has been configured according to certain configs I see here You don't have the same screen. Yeah, here configurations, okay, so that's good now. Let's go and create Let's we're gonna run the server. Okay, so we've seen paster here paster Oh, yeah, one cool thing of paster you can you can have some plug-ins So here pylons have some plug-ins you can have the shell and controller So it's pretty easy to extend and it's generic You don't need to use pylons you can deploy other types of applications in fact any type of WSGI application Okay, so we're gonna create a controller to do that We're just gonna create controller foo is gonna create two files a test file I do tests with external tools, but you can do that in in there. I had to press a button I don't think it's useful Just a second. All right, wait for button Okay, so I have that controller here Created and I'm gonna call up paster serve. I'm gonna pass it reload Oh, let me just show you development on any so that's the configuration for our application So you have a couple of defaults you want to debug that's going to be a that's going to turn out as enabling or disabling the error handler SMTP server you'll receive you'll receive by email. There's an error on your application with full debugging info and logs and stuff so the server here Listen on that port use that as a loader and we're gonna listen to port 5000 now for our application Well full stack. Yes or no in static files here The beaker is the caching middleware and the session middleware, which is pretty good And if you deploy a new system, it's going to create a random secret so it can encrypt the Elements you have config here and most notably SQL alchemy here URL so you can choose your database In fact, we're going to use that cute database. I created earlier Yes, I use emacs Okay, so it's super DB dot sqlite. What was it? And you have those vloggers. Okay, very good now. We're ready to run the server aren't we and We notice a reload statement here. That means it's going to detect a fast change reload the server But we have that can be annoying sometime when you have a big big problem So we have a demo of sensing very sweet that can Allow you allow you to blah blah, okay? Now this is getting. Oh, there it is Very good. It works.  Okay now we're going to go in our Controller foo and look what's there so you have a bunch of imports most notably. Oh, okay. Those are comments We don't care. I'm going to read them out if you want so you have that controller based on base controller That's a WSGI controller. So that thing foo controller at the end There's you have that identity or foo controller is an actual WSGI application It's going to be called as so because pylons is Interleaved with WSGI and it's going to route according to what the routes took out from the URL for example slash Index or by default. This is the default Method It's going to call the right method here So if we see So the the controller is named foo. Let's go in the routing section So you have a pretty simple match The controller name if you have the controller name here and here this the action Well, it's going to be routed to the good controller and action So these are two important keywords controller and action that actually point to the right place Shouldn't lose too much time here Okay, so let's go and see foo Index for example. Okay, here we have hello world Which is awesome and if you modify Well, we'll notice here that's get that gets reloaded restarting and it's going to be changed. Wow So are you very happy now? Okay, now let's go to routing and add for example map connect You can't read the green. I Can't I'm sorry Not at this at this time Sorry, you have the emacs command right away Color Okay, so I'm going to use I'm going to use geodit. Can you see that? Is it better? Sorry, yeah, good.  We couldn't read Okay, is that all right, so we're gonna have here Blah blah goes to foo index goes to browser. Okay, so we can and open that's going to be slower though config routing if we go here Different HTTP versions Verbs. Yeah, of course. Yeah, Russ deals with that. He's going to point to different thing You have a full rest controller. Just drop it in is going to point to different. Yeah, of course. That's supported Yeah, so you see you can go to drop foo and index so slash mp11 is going to point to that foo controller and action index It's gonna get restarted and if we go here mp11 is going to point. Wow. That's brilliant I probably made an error and it crashed the server. So There you go mp11. Okay. That's very not useful. I'm gonna Put that out for the next time Okay, now we're going to use a little bit of Mako so of the templating engine, okay? Okay Thank you. So this we're going to trash out that return here and we have the comment that we can just put in Return to render. I'm used to emacs. So foo index dot Mako. You can use HTML if you want That's just the exception that we give man. I think I'm gonna go back I'm a bit speedier in here Let's see HTML so you don't have the same coloring. Okay So templates foo index dot Mako. I'm going to create that No, no, I don't want that. I want to create that simple file. Can you read that? So I'm going to show you all Python 11 titles. So you have something like that Body what we're gonna have some So I'm super title and some paragraph Super stuff here. Okay Now you can see the render thing Well, it's gonna get rendered That right Server all great. So see that now we crashed. I probably entered some weird things or broke So you have that top-level look. I don't know that extent that that error But I can go in here So that's the web error in in action it crash and now I'm on a solid thread and thread is continuing and I can deal with the server with the The exception objects still in memory and I can go out in any level for say first see the code here this level or that at this point of the stack and Go and import pylons or from pylons Import config and look what's inside config keys and we have all this see we can really introspect the request Whoa from pylons import requests request and the fire and of course that's not pretty useful because you have already that in extra data Okay, and you can view the source code of each of the files right away here Okay, wow Now let's fix that error So an mp11 so what was the error? Render foo index Maco can't locate. Oh, it just can't locate foo index. What's the file? Oh, yeah, that's horrible I didn't save the file Nick directory. Thank you. Okay. There we go Okay, so we have that file there perfect So let's add a bit of mako stuff for example if we were gone we want to loop We want to loop through a list. Okay, so import random and we have a list here of random stuff How we would do that ran int? zero to two hundred I don't know for X in range Ten okay, and we're gonna store that in C. Notice that template context here that pylon does that integration To see there so my list oops Equals L and in index will be able to reuse those ran it non-define. Oh, yeah So that's random. It's not better. Okay So let's go in the template now and for example UL Li and here for L in my list Use that yeah, there are numbers, huh? So we're all right with this and That and for Okay, so these are random numbers. Okay, so that's the basic stuff. You know that huh? We don't want to see that So I wasted a lot of time doing that I'm really sorry. I'm gonna try to strip that up a little bit Okay, so now maybe something a little bit more interesting. So we want to have our application to actually serve video files And we had on-demand File server you do that with Apache serving the files But you have to HD access files to secure or other means we can do that all in pylons because there's that awesome file app WSGI application which deals with with a byte range is all the cranky stuff Apache does normally while you have that WSGI application which does What you can't see now this had to happen We're just gonna pause I I Have to get the right time. What's that? Oh, thank you. Thank you. No, you didn't do anything Yeah, yeah, of course Okay, I Want to go back to Emax? Okay, now if you want to do some video blah. Yeah, that was this one here They controller showing it off controller foof. Sorry Okay, let's create that so in food. We have index. We're gonna save that as Video dot Mako and we're gonna put some Video embedding stuff, but we're gonna grab SWF object and stuff like that. Okay script and type text Java script here SRC equals object.js. Don't worry. I don't I won't type SWF object And then here we'll have that div id video which is gonna be empty and a little script here Which is going to embed so the latest version of SWF object is embed SWF takes Media player VRL Okay, we're gonna grab that from the web Now we want that in a video tag so it's gonna be six We have that Adobe version some Expressing soft stuff and then the flash bar that's going to be in video file. Let's for example elephant Or mp4 I have here Okay, and that proof that should be pretty good Video So that's our video dot Mako file. Let's go in the controller diff video self and return render food video Mako We should we should be able to see that at food video Of course, we don't have the files already. So we're gonna go here and Whoo, there you go download The the media player and download the SWF object shoot. I should have put that in an NPL public. We want to serve that. Okay Public public and unzip Local directory here media player. So we're all set. We have that SWE object blah blah Now what about the video file? We have nothing to play here. It does not exist So we're gonna create the controller to do that the controller part to do that Okay, we're gonna put that in a video file for example self and we're gonna get the file name from here And we're gonna use the awesome Is it from paste or file app? From import file app and return file app temp Don't do that at home. Okay, and This is a wsgi application Okay, and file app is gonna be returned and that's enough for pilots to just deal with it and call it and anything that this does It's gonna be returned as the final request of the user. So to do that It's just it's not just an application pilots can add the environment and start response if it sees you have that in there And after you created the application the configured application. Well, you call it Wow So you can use any like for example track or an instance of track the bug ticket system You do the same thing in just instance of track and you have it running there at that amount point for the mountain point part Let's look at config routing We're gonna add our little map connect video file and file name So anything that goes there is gonna go to controller foo in action video file. Sorry for the pep 8 compliance. Okay, and That's good. Sorry Too many ends. Oh In connect. Yeah, that's true So normally normally if elephant dot thing exists Wow, it's there. Okay. I have sin like in the background. So If everything goes right, no, wait a second before we load that No, let's load it So I crashed at some point has not all connect. There you go And doing a play is gonna load that I don't know if you know the open source told the open source movie or Elephant dreams. Okay, so you can play it out. Now what we want to do of course is not just serve a file You can do that with Apache but You could add some security here at that point for example if You have environment variable Remote HTTP and you split it with the dots and you map that Oh, you have the environment here.  Okay, that's an inconvenience of a remote HTTP. Oh, what's that remote HTTP? remote host What is it? remote address Sorry So there you go. Okay, so that's pretty much. You know what was what happening? Okay. Now. Let's go and integrate SQL alchemy Okay, because it's fun Let's go in the model here So you have some sample we're gonna uncomment that you have three modes of operation SQL alchemy You can use reflected table. We're gonna see that reflected tables Which are gonna discover the the tables in the database and give you an object or just like SQL soup But you can map it to a local object and all the attributes in that SQL suit we've seen like dot first name and stuff we haven't seen that but Are gonna map to that object and you can add some functionalities like another method to deal with for example users change name or I don't know in validate password or You could use a long definition like this Okay, so you explicitly say I want that table and that column and that stuff you can create very complex reference and it has all Class inheritance hierarchy stuff and it's very powerful Or you could use the declarative like layer like you have in jungle You just say I have that class this attributes equals a column integer and stuff like that and they would all three work We're gonna try the reflected table because we have a beautiful database to use Okay, so let's say we have class user and To use the reflected table. We have to use this one here. So users table Because we need oh here it is Users table equals none. It has to be a Reflected user That's gonna be reflected and when we initialize the model so in the environment. Well, we're gonna go introspect auto load truth and you have to comment that here and Reflect so here you're gonna map the user object to the users table That's a bit too complicated. Isn't it? That should be users of course and a table here will be users So you want to go inside that way this way you could use a an already existing database and create a new application over it And you don't have to manage the schemes other schema schema Fat that thing, you know, have to you let the other application in here provided you don't modify to to cranky Lee Well, you can use it with this application by introspection Okay, so if we want to test that we can hear use paste or shell which doesn't work because Let's just sim link that Pylons environment I always do that here so I can activate poof Paste or shell Which loads the environment so I have my model here and my user and Model user query all is gonna fish in the database Okay, I forgot a line, but that should work and we could create a new user You of course you could from MTL pi model import user if you fan of a direct Access so my user youth first name super Bob and last name a hero Bob and My ID would be seven and then we could add that to the session. Just save it to that database Okay, you have the debugging info. See you can see the actual queries, which is kind of nice Okay, so I won't go through all that crud stuff. Okay, because you probably don't care I want to show you some neat stuff we can do with that. I'm gonna skip that part. Okay a quick overview of You guys want a three minutes break? Okay, maybe I take one next time Templates we're gonna go to the controller here Do I have it open? Okay, so my foo controller? We're gonna show some for example a tom feed So RSS and this is gonna show. I don't know some So feed generator Import a Tom one feed We could create in the Tom feed here, which takes a title super title and a link To that site. We're gonna URL for which is generated from routes Yeah, can use browse odd use without your URL both sides generation of both side of course and link a description super description and and We need a language and then to the feed we're gonna add an item which was a title Some post I know I've seen and a link. Let's go to google.ca, which is an awesome site description simple post And we we're gonna Set the content type to application at Tom XML and return There we go. So we'd have a beautiful Where did the response come from? It's loaded automatically here. So it's a pylons. So that's what pylons Gives you on top of WSGI which the Java specification gives right away. It gives the request and response here WS guys is a bit more lightweight and gives the application the burden of dealing with that But pylon uses web OB, which is the best of the breed a response of well one of the best response objects Request and response. So let's go and see that in the website We don't have a control. All right. We're through RSS Of course, I'm probably did a bunch of typos So I see the feed here and just to be Okay, wait that should launch. Oh, there you go. No, so I'm gonna add that to life. We which is a feed reader Through RSS and you have it here with a new item and a new blah blah, okay? So that's what web helpers is there for you It has a bunch of HTML generation tools So you can trim files cut words and add some dot dot dot change dates and say, okay Since two days since one hour since the last minute and stuff like that also HTML it was ported by from rails Initially, but now it's been expanded. It's a bit more complete and stuff That's web helpers It comes with pylons, but there again, you can use that with other projects. You're not tied to pylons, but okay Okay, that's what it that one's a good one Now what if you have a PHP application and you want to stack it up on your You have an application here You have foo RSS and you deal with that slash the root of the server and you want for example slash Bob or PHP app to host a PHP application Well, we're going to create for that. Oops a controller and the controller only needs so you have to copy paste from the the WPHP website from WPHP Import blah blah and we're going to follow the convention here By pylons to use PHP app controller That's what it's going to seek and I call a WPHP thing We're going to host Well, that's not that's a PHP app and we're going to serve here path templates first element and So we're going to serve from our templates directory. Okay, and we can add PHP options for example magic quotes magic quote gpc off And now you have the power WSGI this is a controller and it's a WSGI application like any other the foo file See foo controller is a WSGI app and the same as the PHP application so you can go in your routes Go in a config routes and add a special map or a simple map if you will pH PHP app and here you add What's the name path info that's going to be passed on as the path info to the controller PHP app here You notice you don't need action because the controller does it all You need an action only for pylons to know which function to execute but here PHP app does it all well that worked Maybe not because I think we didn't install a pip install. Oh, yeah, pip install. I have that in build somewhere PHP There you go Okay Now let's try that before we can do that. We have to create the templates. Don't we so PHP app Let's go in there and do some PHP man so let's try index dot PHP and Sorry, it's been a long time And try to serve that where did we try to serve that? PHP app and index dot PHP is that gonna work no module name PHP app Wait a second In PHP app from blah blah import PHP app. Where do you say that? I didn't say that file. Oh, that's horrible Config not defined of course so from pylons import config. Oh man So you can have all those files hosted under that and you have that WSGI rewrite thing that understands the HT access mod rewrite thing So you can have actually beautiful URLs from inside Python dealing with a PHP application underneath So that's a little bit. I don't know if you say it's insist. It's a bit insist you insist you wish or anyway Okay, but it works. I mean you can have any spawns a PHP a CGI process in the background I think that's yen biking to that or band background. I don't remember any paster tools. You know, yeah Okay, okay, so that's good now What's the most important here? Okay, what do you want? I have I have three things so the reload problem Who can circumvent the reload problem using a WSGI? I'm gonna do that. Okay So see if you have a big application This has to be reloaded if I go here and I modify for example this one I add a PHP app blah and I save it. There's a moment see where that Where that reloads and there's some drops time So if you have that in production if you want to update the code Well, you'll need to restart the service. You have five five seconds depending on the bigger the bigness of the application Well, it's gonna take five ten seconds to reload. So you have that downtime but you can use the awesome or simple or in config middleware You know config middleware a simple thing called me mental and And it's it so you could import me mental Of course, we're gonna need to install that to there you go It's a package on the pipe I and you replace that here with something that looks like Assassin and you give it the actual object you want you'll want to load See this is and we're gonna give it the package We want to be dropped and reloaded at each new request for example, my mtlpy and We won't need to load the pylons app anymore here Okay, cuz it's gonna do it and at each new request is gonna reload everything. That's in mtlpy That's mtlpy in green. Okay, let's try that Because it it seems a bit mysterious For example foo index not implemented index So if I go and modify that foo file Okay, here. I have a bunch of enters and modify that for mako 2 See it's getting reloaded. That's annoying. So let's stop that and having placed our memento thing prevent the reloading and Modify that again. See it's not reloaded Of course, it hasn't been loaded, but so F5 here It's not reloaded And if we change that for randint zero one Normally the code here changed it should be reloaded in order to to be updated on a server Well, it's it got updated right away and the awesome part here is you can activate and deactivate the memento thing So you can just activate it for a bunch of seconds while the code reloads And you still all you get your your clickstream and then you deactivate it on production servers for example So this is neat and that's a double sji application. It stacks in the middle and does a certain good job Okay, was that fun? You probably don't have that that problem often, huh? Okay So that's good in pylons. We have Wow Okay, I Have a next MLRPC server service or controller. Okay, you just change XMRPC I can demo that and I have also the beaker caching caching algorithm with a new Slick a clever CSS package. We can just demo like that. I have six minutes for question You want a question or want me to demo that? Yeah, go ahead Questions are better. Okay, so pylons is the underlying Stack of two burgers true burgers adds some some it selects things for you So you have that or me have that type of thing to choose So they chose things for you and they add some more maybe a Yannick would be a better off to answer that they add more Icandes selected application and more functionalities on top of that But once you learn pylons, well, you know two burgers more right away So it's a bunch of libraries that they added on top of that Yes. Yes here tie up the application instance So the controller here is created on each request it creates a new controller and calls it So you just create a new instance of the file app each time and you can use conditional to run it or not So you have one paster process Which listens for incoming HTTP requests and spawns a thread for each request and in that thread Well, you create a new instance of a food controller and in the code you create a new dynamically, of course That's Python create a new instance of a file app each time well Probably there's some I wouldn't say there's absolutely no Overhead of course if you use a patchy which is optimized But you can't use that when you can you want to have some Checking or error permission checking and stuff like that But you can do it because it has the power to do of course is gonna it might take some Processing time on the machine that runs the other HTML page. Maybe you want it quicker, but So file app is pretty efficient. Yeah, and it's fully fled Yep. Yep. I haven't talked about that, but I'm gonna just show off Where's that oh that's on a bureau The Apache demo Oh So that's an example Deployment script that you put that in Apache. That's one of the methods I prefer Okay, because you can run the the process on your own username You're not tied to WWW data and your environment for production is the same as development because you use paster for development and paster on production and you use the Port mod proxy to just forward every request on the local port so your process is listening on 504 and on the other side. Well, you have that development.ini file That listens on local interface and you can put a script in the inif in it dear Okay, if you use that as an in it dot d script is gonna lower your application of course, just add that to your File.ini and you can use it with that file start and it loads the application apps as that user Spons as a demon and it's gonna serve That might not be very clear But it's pretty neat So you just run your application just like you would with Apache and then in the modular It's not separated. Yeah, in fact, it's separate separate Python process. You can run different versions and stuff in different environments. Yes Yep, yep, yep, it's using production on several servers. Yeah, it's a good thing See it's because it's a project of its own and it's worked on by itself not as a Means to okay. We need that because we have something else to do. Huh not looking at anyone or any project here So that's it any question Yep, yeah, you had a question. Yep though so the session we haven't seen that beaker is a has the cache and the Session middleware we've seen it stores that in a temporary directory. Okay, you can use memcache Do you can do all sorts of a serializing thing, but it doesn't store that in there? Well with memcache. Yes Well, you have several ways to store the session data Okay, by default. It's in a directory Does that answer the question? Sorry. I'm I'm a Quebec or French. I don't speak English very fluently so Yes back there. Yeah Well, you'd put a queue in there so you can do threading as you say one Request one thing cool you can do is for example when you start the process it's that might not be an answer to your question, but You can spawn a process you launch a paster and you start a thread on the side and in that thread You can wait and do some things like for example each hour You don't need to configure a cron job or stuff like that in that case You have one thread more than any requests are gonna have and in that special thread you could also use that apps global and Communicate through each thread using that G. So you'd probably do something like in from pylons import Lib sorry I'm tired import app globals as G before it was G or you can just app globals something like that Now I'm not in an environment or another Directory and you'd use that up global as a dictionary as or I don't remember if it's a dictionary or just the attributes are mapped And they're safe and shared between all the applications. Okay and thread thread safe manner. So Well in that case you probably you're gonna need some other things that I can't talk to you about or I don't want to Yeah, to do a load balancing use a couch DB and use that as your means to Well, I'm not gonna suggest on your required infrastructure for your personal project But I guess you have to find a solution if you want to spawn on several servers. Maybe yeah, I have a central Data exchange. So yeah Yeah, yeah, you could do that Yeah, yeah, we could do that of course you have a low balancer in front put that on AWS Amazon EC2 and have a low balancer hit different parts of those over. Yeah, now that's application architecture. It doesn't have pretty Stuff to do with pylons, but yeah pylons would serve you that like any other sweet Python application Are there any questions because I'm pretty much out of time. Yeah Yeah, so oh I didn't talk about that. So you have to do that you have several Shoot man, you have several Packages that do that you have form alchemy, for example, which does all the form rendering and it's bound to SQL alchemy So you can use that is alchemy the good word. No, sorry. Okay, so you can use that in pylons or in other frameworks But for my key has a an admin interface So it's going to generate an admin interface Maybe not as sweet as the Django one because it's been work and they use that in production stuff But format can be does has something like that. Also two more gears have that cake sprox. Yeah, it's a bit ugly Yeah, yeah, of course. So so the turbogears is built on pylons. I had that question while you were out Yeah, so what turbogears? What does to bring your add to pylons? Yeah, yeah, it's another thing. Yeah, you can use that in pylons and if it Yeah, of course Exactly Yeah, so with pylons you have Flexibility and you can you mostly can if you have a problem if you have a project that use couch TV For example, well, you probably better off using pylons and then adding the other stuff that was probably in turbogears But and to break isn't that matter will be a bit more like Django, which has Django apps You notice here the WSGI Applications are not like the commenting system with a bunch of tables And they're really application years. So under that backs another slash you have like a track instance or you have a video-on-demand service or you have those type of Applications all right. So turbogears allows you to do that So you can have a look if you want into turbogears, but learn that first of course because WSGI is Java's server And who would deploy Java application today without a servlet, you know, you want pipe and create your new deployment methods Okay Well, if that's what you need, of course Yeah, don't just don't just drop and oh, there's a lot of hop on Django and go back go there And if it's not your nevel you're gonna get struggling In fact a lot of people that start off because of the hype and they have to rewrite mostly everything at the end because Oh, it wasn't the fit for that wasn't fit for that It's not powerful enough for for what I need because today We don't only have applications that are like my weblog and my address book and simple database stuff You have an actual application that do some processing and do some particular things and I don't know scan some stuff and be linked to other Internal systems and so you have to think about that Anyway, okay Anything else?  That's it's awesome. You can do everything Yeah, yeah, of course of course now you have a several a Python deployment option that our favorite Namely Google App Engine Well, that's gonna run on App Engine. Okay, you either have a couple of recipes just copy paste and and Spit it out on Google of courses. It might not be very speedy when you have a low but their web faction does a Python deployment point and click I think I never use that It does. Oh a woman's voice. Okay Any other question? So I should have a last slide that says thank you, but I don't have that And we've skipped a bunch of things so thank you and I hope you appreciate it And I'm ready for comments if you want to spit on me or stuff like that. Hey, I can talk it I won't be over there at the beard It was a pleasure


We have all sorts of detailed stats about dying, but little about the experience of death. For the minority who die under the palliative care teams, one's death could probably be described as good, but there's a suspicion that for the majority who die in hospitals or nursing homes, the experience is bad. And that's where most people die. In spite of widespread preference to die at home, in almost all populations, most deaths occur in institutions. And this doesn't just have consequences for the patient, but for the bereaved caregivers as well. Patients with cancer who died in an intensive care unit or hospital experience more physical and emotional distress and worse quality of life at the end of life. And their caregivers suffer five times the odds of suffering post-traumatic stress disorder and nearly nine times the odds of severe prolonged disabling grief. Now this was an observational study. They weren't randomized to die in different locations. So this doesn't prove cause and effect, but certainly raises concerns. When researchers have looked into the care of dying patients in hospitals, it hasn't been pretty. Basic interventions to maintain patients' comfort were often not provided. Check with dying patients was minimal, and the distancing and isolation worsened as death approached. For example, a 52-year-old woman with metastatic cancer spread to her liver. She had gross abdominal distention, was jaundiced and very breathless. But alert, her eyes were swollen and she shed yellow tears. The patient received no care from the nurses delegated to give care. But in the nursing record it was recorded that attention had been given to her personal hygiene and pressure areas to prevent bed sores or hygiene in eyes, but it was all a lie. The only attention she got was to receive a commode from a nursing assistant. Contact time totaled six minutes over the four and a half hours the researchers kept track. In contrast, what would a good death look like? Retaining control. Privacy, pain relief. You choose where, you choose how. Emotional support, respecting your wishes, saying goodbye and being able to leave when it's time to go and not have life prolonged pointlessly. One's best bet for all that is access to hospice care. Palliative care is comfort measures to relieve symptoms and improve quality of life, utilized at any stage of serious illness, whereas hospice is just comfort measures. And focus shifts from curing the disease to improving the quality of one's last days. Hospice is often framed as giving up, but ironically when you compare hospice versus non-hospice patient survival, the patients in hospice actually live longer. Patients who choose hospice care live on average about a month longer than similar patients who do not choose hospice, randomized those with advanced lung cancer to early palliative care, and they don't live a month longer. They live two and a half months longer.  And in fact, that's one of the ways hospice could extend survival by avoiding the risk of over-treatment with chemo and its related toxicity. There are however limits to palliative care. Even under hospice, where one would assume excellent palliative care, there are those who appear to unavoidably spend their last months in uncontrollable pain. And this unbearable suffering, despite our best efforts, leads to requests for ending a patient's life prematurely. Although physician-assisted suicide is gaining acceptance, it's only legal in eight states plus DC. In contrast, V-S-E-D is legal throughout the US. Voluntarily stopping eating and drinking, V-S-E-D, can be defined as a conscious decision to voluntarily and deliberately choose to stop eating and drinking with a primary intention of hastening death because of the persistence of unacceptable suffering. I've talked about fasting to extend one's life. What about fasting to shorten it? We hear a lot about physician-assisted suicide, but V-S-E-D has not gained nearly as much attention. This is presented as perplexing, since supposedly it's relatively peaceful and a comfortable way to die. But is it really? How long does it take? How would you do it? I'll talk about the pros and cons and practical implications next.


Good morning everyone. I'm not sure if you could hear me inside. I was whispering because well everyone is still asleep at the house All right, we are going to seek out some uphill Running that's right. And up is gonna be the key word Basically this mountain I'm going to it's called Mount Bierstadt. It's another 14er here in Colorado and it's a doozy It's it's a good one. And it's a perfect opportunity to Talk to all of you about why I love running uphill so much, but also some technique ideas if you're interested in Improving your uphill work and we've talked about this in the past here on the vlog But I'm excited to dive in again now that it is summertime at least here in Colorado So all right, we're in an upward as we like to say literally today again. Let's get some up Let's go get some up here. All right, we made it up Gwanella pass to Mount Bierstadt You can see it there off in the distance and it's looking very nice I haven't been here all summer, but just keep in mind You'll never be if you're looking for a little solitude up in the mountains. This is not the place to come It's very busy. A lot of people come here actually tip of the day across the valley from Mount Bierstadt is Some are some 13ers so mountains that are not quite 14,000 feet and they are not nearly as busy for some uphill Running or uphill speed hiking if you will so anyway, you might want to check out across the valley as well But the reason you can I like coming to Bierstadt is that you can get a really good aerobic stimulus at altitude without putting a ton of miles into your legs because you start the running Basically right at tree lines. So anyway, that is why I like coming to Bierstadt. All right, let's lace up We're gonna start in the terra chagra fives. That's right. This is the last test before I've done the wild horse fives the the peg 36 trails and now the terra chagra fives for the last Mountain test before giving you my full opinion and comparing them And how they're performing here in the rocky mountains. So oh, yeah so these are considered the fastest fastest option out there and I will be publishing this comparison All right, we're we're about to hit the steep sections on Mount Bierstadt and let's before we hit them I want to even remind myself. What is one of my favorite techniques and tips for uphill running? It's not in my legs. It's in my shoulders. That's right. So putting your shoulders in their pockets Okay, so instead of letting your shoulders shrug forward you put them back Just put them in their pockets that helps so much with posture with with torque with your pectoral muscles So your it's just I boom boom and when your legs are getting tired, which of course They're gonna get tired running up a big mountain I I lean into my arms so so much to help me to help propel me up the mountain as fast as possible So again, it's just put instead of shrugging forward which also inhibits your breathing put the shoulder blades in their pockets So just kind of put them back just put it not too much But just put them back and then it creates a little bit of tension here with your pectoral muscle that allows you to Just power just power up that mountain So that's one thing that I focus on all the time in uphill running. All right, let's keep getting it elevation game Come on All right, and another uphill running technique and tip is keep your eyes Keep your eyes up. You don't want to look down too much. Okay? I realize if it's really rocky ground you need to look down a little bit But try and keep your eyes up because as soon as you start looking down Your shoulders start to collapse in it can inhibit your breathing quite a bit So keep those eyes up and that'll help with it'll help with I I'm telling you with everything with knee drive We know it's crazy, but it just it helps with all of your posture and keeping yourself Nice and straight up and down as you go up the mountain So that's what I and it's easier said than done. It's easy to forget this technique.  I like to really focus in on my upper glutes and my lower back Which basically? Prevents me from leaning too far forward because you're naturally gonna want to lean forward going uphill It's just what happens, but you don't want to lean too far forward and So it just allows you to keep your posture, and I'm gonna talk more about that in a minute It's gonna keep your posture good And so anyway, it's that taut feeling between your the front of your leg and the back of your leg All right, let's keep rolling And another tip for uphill running all right you're gonna be to you want to take shorter quicker steps, so this is where the fast-feet exercises really comes in handy and Like you don't want to overstride is what I'm getting at because that's gonna wreck your quads you're gonna you're gonna get way too tired way too quick and What determine what helps influence this how many how short and quick your steps are is the pitch of the mountain So obviously if you're racing a hilly cross-country course in high school This might not be quite as applicable, but for big mountain runs big ultra races with a lot of vertical gain It's that quick feet short steps and and I'm not talking about What I'm not talking about speed hiking. That's a whole nother ball game. We'll we'll touch on that another day So short quick steps and that'll help save your quads a ton And this is where the suppleness and of your Achilles tendon and your ankles comes in so handy We're getting into the gym and this is where like the ballet dancers that I've talked about in the past It just helps to have really good torque through that ankle and Achilles tendon Your flame jump into my blue blood And I thought of you Beer stat in the books, okay, it's always I struggle to communicate clearly Running technique and running form. It's it's always better in person But I hope those little tips and technique ideas Will give you at least something to chew on when you're out there running your next set of hills Whether it's in a race or a workout and again, of course ask any questions down below in the comments And if you really really want to ask a question make sure I answer you can look look me up on Instagram and I'm pretty good at getting back to people it usually takes two or three days But I will get back to you eventually and one more idea for running uphill with respect to technique And also the mental side of running which is so critical for uphill efforts. Okay. Here we go I call it cresting the hill. So whether it's a hill a pitch a big mountain Maybe it's a 30 meter hill on a cross-country course Whatever it might be if you can maintain your form on the hill once you get to the crest So right before the top that is when I try to Basically put the hammer down and make it hurt for every if it's a race for everyone around me And how do I do that?  What is something in an uphill effort that you struggle with whether it's mental? So it could be physical or mental or a combination of both But is there something that you're noticing in your uphill running that doesn't seem right? Like you're breaking down your form is like anyway So just think you might have to you might have to go run some hills and just figure it out for yourself In the next couple days and feel free to come back and ask your questions down in the comments I love you guys. Okay. We're packing up the van. We're hitting the road. We're going to Illinois for a wedding It's gonna be crazy and I just come along for the journey So I think that's it. I think that's it. All right. Oh, yeah, and yes the next video It won't be today. I don't think you never know you never know But yes, I will be comparing the Nike trail shoe lineup as soon as possible. All right. See beauty work hard


Save 10% with my coat, Bobby Tan. Just kidding guys, today's offer is much greater than a saving of 10%. I teamed up with my Muslim brothers and we created pure passage. Imaging sending the reward of Umrah, this Ramadan, to someone you really loved but had already departed from this dunya. For they're really sick and they cannot perform Umrah at all. Imaging the feeling of honoring his or her memory and expressing your love and devotion while still ensuring that they receive this gift, the reward of performing Umrah. As a new revert I just learned about this but you know better than me that performing Umrah is a profound spiritual journey that most Muslims aspire to undertake and you understand the rewards of it. However, for some this journey can be challenging especially when their loved ones are sick or have already passed away. At pure passage we understand how important it is to fulfill this obligation for your loved ones. That's why we offer our professional and reliable service to perform Umrah on behalf of your sick or deceased parents, spouse or any other relatives. We believe that everyone should have the opportunity to fulfill the sacred act even if they are unable to do so themselves. And equally understand that the physical and financial challenges of performing Umrah yourself on behalf of your loved ones can be overwhelming. That's where pure passage comes in. We take care of everything and make sure that your loved ones Umrah is performed with the utmost care and attention to detail. So let us help you earn this immense reward for your loved ones by performing Umrah on their behalf. Contact us today and let's make it happen. Alright guys, welcome back to the channel. If you're new Manusbabi guys, finally we're gonna continue with the Prophet series. Today with Prophet Khut and the Nation of Ad. Guys, you waited long enough for this so we're gonna jump right into the video. Just do me the favor.  Subscribe to the channel if you haven't already. And check out the description box. All the links to support this channel are in that box. Thank you so much for your ongoing support guys with no further ado. Let's have a look. After the flood, the people were on Tauhid. They worshiped Allah swt. The first people to introduce the idols back into the worship. They were given the most power of any nation before them. Every single individual in this town. Alright, so that's very interesting because now we are speaking about a reset ultimately. When Noah Nuh came, he reminded the people of monotheism, of Tauhid. But they didn't want to listen so God sends the flood. After this reset you have new people that are on the monotheism, that are upon the truth. Obviously, but now you see they're declining yet again and they start to worship anything besides Allah. Passively built, powerfully built. These people are actually giants. So nobody could stand up to these guys. And so they were... Very interesting. We have the same narrative in the Bible. Those giants are called the Nephilim. Super power that took over much of the land. They used to build those palaces in the mountains. So unique palaces for the sake of fun. But these were giant pillars and they were decorated and they had a lot of decor all around and the beautification of this world next to nothing. These were the people of Aad. Allah SWT sends a prophet to them now. What was his message? The same message of Nuh. O my people, worship Allah. You have no other God but him. And such were the people of Aad. And once you get this message you cannot resist Islam any longer. Once you understand that Islam has a clear cut message, a red threat that is always the same. Why would it be any different if God's pattern is not changing? Never changing. God is eternal. Why would the message change? Once you open up your eyes, once you open up your heart to this message, you cannot go back. This was really the crucial factor for me personally. This is why I reverted to Islam. Had they denied the revelation of their Lord and disobeyed his messenger. This is in fact what they were asking for. It is the punishment of Allah coming with wind. Anything that this wind will pass will make it like dust. This wind will grab them, will take them up to the heavens and with their heads first on the ground. Aad disbelieved in their Lord. So away with Aad, the people of Hud. Bismillah, Alhamdulillah. Wassalamu ala Rasulillah. As-Sallallahu alayhi wa ala alayhi wa sahbihi wa min wa laa. Amma ba'd. Hud, that's a cool name. After Noah, alayhi salatu wa salam, his Qawm, his nation, they remained upon Tawheed, upon the oneness of Allah, subhanahu wa ta'ala, for some time. Until there came a nation called Aad. Aad al-Iram, the old one, nine for one tribe. Their location was a location called Al-Ahqaf. Al-Ahqaf means sand dunes. So it's a desert area right now. It was in that case before. Where is it? Between Oman and Yemen, close to Hadramaut in the southern Arabian Peninsula, Middle Eastern region. Allah subhanahu wa ta'ala described these people and their description is amazing. What Allah subhanahu wa ta'ala has given them is amazing. They were given the most power of any nation before them. The people of Aad were humongous people, gigantic people, very strong, very tough, and very smart. These people are actually giants.  They were more muscular. Their bone structure were very, very powerful. Yeah, the difference here is within the biblical context, those Nephilim are fallen angels. So yes, they are giants. They come to earth and then they have s*** with the daughters of men. This is the biblical story and they are offspring.  Nobody could stand up to these guys. And as a result, when somebody is powerful and strong and nobody can stand up against them, they take over and they destroy. And so they were the superpower that took over much of the land. It's been narrated that they were so strong, so big that one of them would grab a palm tree with his hand and pull it off. Pulling a palm tree with your hand. You need a bulldozer to take a palm tree. They would go anywhere and any law that they said was the law because of their power, because of their physical power, because of their political power. When they would attack any neighbors, they would completely destroy them, tyrants. And the description of their armies the Mufassirin they said when they would leave the army, the army would leave their city. When the front rows of the army would reach the enemy, but the last of the army still have not left their town. They had massive armies. Allah says, Such people, such creation, I never created before in this world, ever. Allah Subhanahu wa ta'ala has given them livestock and has given them manpower and has given them agriculture. And has provided them with an ample supply, good supply of water. That is as a society.  And they had the gardens and they had the rivers that flowed through those gardens. And because they are very smart, they were very civilized. They had wealth that was so enormous. They had so much luxury. They started to fall into the trap that rich nations fall into. And that is using your money for pride and arrogance. They would find a huge mountain and they would just build something up there. A huge castle. Someone would pass by and they would say, Who built this castle? Who lives there? Nobody lives there, but it belongs to Allah. That they were not used for living. They don't need them. They just building them for pride to show off. They had pillars over and over. And if you looked at it, it was like the golden city. It was a city you wanted to be in. That maybe with all the technology that you have these days, they would not architect and engineer such good and big palaces in the mountains. Good and big. Yeah. The point of the story is, of course, that we've heard about ancient civilizations that fell and have been destroyed be it the Mayans, be it the Aztecs, be it the Incas and whatnot all around the world. We find reminders of those ancient high civilizations and to this very day, people are wondering, archaeologists are wondering how the pyramids, for example, have been built. It points towards that those people were much further than us in their development, had technology that we don't even have nowadays. I had the best times. But these were giant pillars and they were decorated and they had a lot of decor all around and the beautification of this was next to nothing. They used to build it in a way as if they're going to live for a while. So strong and powerful. And some scholars say even to the day judgment night palaces will ever exist like the ones they had.  They were the first individuals to start to commit shirk once again. They started to associate because of your company so much quote on quote. If you build such towers, you build such castles, you start feeling proud of yourself as they said correctly. And once pride kicks in, you're starting to worship yourself.  We see that with some Protestants, for example, they call it the Prosperity Gospel and all praise to God, all praise to Jesus. They say that he has blessed us with money, but ultimately, they become proud of themselves. They can host such big events and with that, they start worshiping themselves. Parknas, as always, as I say, alaihi salatu wa salam. They specifically worship three idols. The names of the idols were Suda, Samud, and Haraa. Allah SWT sends a prophet to them now. His name was Hud.  Prophet alaihi salatu wa salam said, Please let me know in the comment section which prophet this would be in a Christian context, because I do not know anybody named Hud. And the messengers, there are four prophets and messengers who are Arabs. And the prophet alaihi salatu wa salam said, Hud was an Arab. Salih was an Arab. Shuaib was an Arab and he taught Abu Huraira and your prophet is also an Arab. Allah says, and to Aad, the people of Aad, we sent them their brother, Hud. The reason why Allah says brother here is because Hud alaihi salam came from their tribe.  So they learned his honesty, integrity, sincerity, truthfulness, character and so on. Hud alaihi salam had a strong enormous body, alaihi salam, was very handsome. What was his message? The same message of Nuh. O my people, worship Allah. You have no other God but him.   Remember Allah Az-Zawajal had given you. Remember Allah Subhanahu Wa Ta'ala had bestowed upon you. And remember Allah had made you as Khulafa, successors after the tribe of Nuh. And he had given you strength, physical, strong physical bodies. O my people, ask forgiveness of your Lord and then repent to him. He will send you from the sky abandoned rain and add strength to your strength. So with Ishtiwfar, you would become more powerful than you are now. They were already powerful and strong. So how was the response of the people of Aad? The first thing they did was, they rejected him and they rejected his words. They said, Every time you try to change the narrative of the times, you will be met with force. You will be met with opposition. Just look back what has happened from 2020 to 2022. Every time you would go against the global narrative, you will be deemed clinically insane. Ohud, no evidence have you brought us. And we shall not leave our gods for your mere sins and we are not believers in you. They used to make fun of him. Wouldn't Allah send someone beside you, Ohud? Who were you to come and tell us what to do? Can't you look at our strength? Can't you look at our power? Can't you look at our civilization? This is the way our forefathers used to worship. Who are you to come change it? The people of Aad will accuse Ohud saying, look at the way you speak. You are acting different to us. You are speaking different to us.  Subhanallah. Made out of statues. Allah subhanahu wa ta'ala says, Aad denied the messengers. How many messengers did they receive? One. How come it's made plural? If you refuse one messenger, it is as if you refuse them all because all the messengers... Yet again, this makes sense, man. This is exactly what I'm talking about. If you accept Islam, you do not reject Jesus. People tell me now, oh, you left Jesus for Muhammad. No, that is not true. You accept all the messengers. Why? Because they all came with the same message. Worship God alone. Even in the Christian context, yet again, the first commandment is you shall have no gods before me.  He never told us those things. Therefore, no, I'm not rejecting Jesus. I'm accepting all the messengers. He just came with the same message. If you refuse the message of Muhammad Sallallahu Alaihi Wasallam, it would not suffice you to believe in Isa, O Musa or any other Nabi. If you disbelieve in one Nabi, in one Rasool, it is as if you have disbelieved in all of them. That makes perfect sense because you're disbelieving in God's message ultimately, which is always the same and God is always the same. He is already perfect and He is one. Believers and the immortal from amongst His community, they began to say you are foolish.   Hood responded back said, there is no foolishness in me. I'm only a messenger from the Lord of this universe, Allah Subhanahu Wa Ta'ala. I'll convey the message of Allah to you. I'm only a good advisor and sincere advisor to you. I just want to warn you from a severe punishment that will come. You build yourself palaces and you don't live in it and you build all these monuments and you don't benefit from it. Why are you doing this? Is it to show off to people?    You have to have mercy and compassion towards the people and the people of Huda A.S. they didn't care. They were also amazed that how can a man come to us? If Allah wanted to send a messenger, he could have sent an angel. Why did he have to send a human being? That's what they always wanted to know. Who are you to come now and change our way of life? This is the way things are here. This is the way we used to live in. This is the way things are. Who are you to come change it?   If you are from Germany, if you are from France, if you are from the United States or from the Balkans as myself, what happens is you are born within a society that is allegedly Christian. However, there are many different ideologies infused into that society as well, be it democracy, be it communism, be it liberalism and whatnot. And if you want to go against the grain, people will of course fight you. People won't understand why you have accepted a new religion, even though it's not a new religion. There's only one relationship between us and God. And Islam prepares you for that battle because Prophet Muhammad may peace be upon him was fighting against his own people as well. They were ridiculing him. They were telling him, why do you want to change what we've been doing before? This is how our ancestors worshiped and this is how we want to worship. They're saying that if you follow a man, That's amazing. That is the same as you. Same as you.   They said, in that case, you will be losers. What makes him any better than us?  You think you're strong. You have muscles. You have power. You have military might. You have these tanks and whatever you got.  So fear Allah and obey me. Now they are accusing Hood of lying against Allah, SubhanAllah. They are claiming that they are the true believers in Allah and he is lying against Allah.  We die and we live and we are not going to be resurrected. He is only a man who has invented a lie against Allah. But we are not going to believe in him. They started spreading a rumor that this man here, he's doing it for some ulterior motive. He wants some money. Allahu Akbar. Why? Why lay accusations? So Hood, alaihi salatu wa salam says, Oh my people, I'm not asking you to recompense me in any way whatsoever. My reward lies with the one who made me. And another thing they used to do is they had taxation. They had blocked some of the passageways in travel and they used to tax travelers. And they used to take the wealth of the people unjustly. And Hood, alaihi salam is telling them, don't do this, don't do that. And he used to call them to social justice. And Hood, alaihi salam will continue calling them to Allah, Subhanahu wa ta'ala. And calling them to Allah and remind them about Allah and call them to Allah and remind them about Allah, Al-Zawajal. And the more he calls them to Allah, Subhanahu wa ta'ala, is the more they become stubborn against the call of Allah. And the more he reminds them about the Tawheed, the more they get against the Tawheed. And the more he reminds them about the favours of Allah upon him, it's the more they turn against Allah, Subhanahu wa ta'ala. Because my really loves to scream. And the more they mock and make fun of Hood, alaihi salam, to the stage they said, Can't you look how strong we are? Who is stronger than us? Even your own Lord is not even stronger than us. They said, these tales that you are telling us about Nuh, because he told them that Nuh, alaihi salam's people were destroyed just before you. He says, these are tales of the people of the past. As for us, we are stronger than them. We have much more than them. We cannot be destroyed. Yeah, it's absolutely amazing. You always find a civilization in Amnesia almost. They have forgotten. And moreover, they always believe that those are tales of the past. They're just fiction, right? Nowadays, people will tell you exactly the same thing. Oh, we're so evolved now. Now we have the science. Now we have the technology. We are so, so strong. But it's absolutely insane when we see a natural catastrophe like an earthquake. For example, we get humbled right away. Sci-Fi movies will tell us, oh, we can predict when a meteorite will hit earth and we can prevent that. But you cannot predict an earthquake, man. We have absolutely no control over this world. All the control lays within God's hands, of course. So the true curse of every high civilization is arrogance. They said there is nobody more strong than us. Yeah, yeah. No one. Who is there who has more power than us? This was a question. Looks like the body below Frank Zayn. So Allah responds immediately. Do they not see simple calculation in their brains that the one who created them, that Allah is more powerful than them? Right, that's what made them do what they did. And that's the same pride that made Iblis not to prostrate to Adam, alaihi salam, pride, the mother of diseases, pride, the mother of all sins. And the only one that deserves to have pride is Allah subhanahu wa ta'ala. This is the kind of thing that... No, I disagree. He doesn't need to be proud. Moreover, God has no need whatsoever because he is already perfect and more over than that. There is only one God. So why should he be proud? There is absolutely no other than him.  Don't you get it? You tell us. They don't get it, man. What to do? You don't tell us what to do. You warn us. You don't warn us. You give us advice. You don't give us advice. It's the same. We're not changing. We've told you so many times. Who, alaihi salam, got up. The interesting thing is that the only constant in life is change. So even though those people were convinced that they are not going to change, ultimately everything has changed. So don't get sucked into the global narrative of our times. Now people believe we made it. Nothing will ever change. We have our smartphones. We have our social media. Nothing will ever change. We did it. Of course not, man. Everything will change. 20, 30, 50, 100, 300 years into the future. Everything will change. From all these people and he says, oh my people. Inescapable. I am making Allah bear witness and I am making all of you bear witness that I am free from all that which you have associated as partnership with Allah. So now if you want to plot against me, all of you get together and let's see what you're going to do to me. Now this was a challenge the other way around. Now this was a challenge. The messengers never normally told the people, look come attack me. When you come, you will see what will happen.  This is what he said. So they didn't come. Allahu Akbar. And so the people of Hud said, oh Hud, you've talked to us so much about this punishment. You kept bragging about this punishment. Bring the punishment.  He could punish us. We are kama'at. We are those with strength and pride. We are those with power. We are those with greatness. Who could punish us? Even your own Lord can't even punish us. You say that Allah can do anything against us. Do what we want. Who is more powerful than us? So he leaves it to Allah. He says, it's not up to me to punish you. It's Allah subhanahu wa ta'ala. If you think this is something personal between me and you, you're mistaken. I'm only giving you good advice. But if you don't believe me, then it's your own loss. So Hud, alaihi salam, at that point, made dua. Hud, alaihi salam, a dua mentioned in the Quran, one dua short. Short is anything. He says, oh Allah, assist me because they have now belied me. That's all. Help me, ya Allah. That's all he said. And Allah responded immediately. Allah subhanahu wa ta'ala says, Don't worry, Hud, very, very soon they will regret everything. Allah still gives them that time. If they want to repent, they could repent to him subhanahu wa ta'ala. What happens? Three years for three solid years, not one drop of rain. And he, the people of Ad, start to realize, many of the trees are dying. Many of the plants are dying. Many of the cattle are dying. They need water. What's happening here? And Hud told them, oh my people, if you really want rain, there's two things you need to do, repent and turn to Allah. And you know how strong you are? Allah will grant you more strength, over and above the strength you already have. Look, we're not going to get punished. You've been telling us for years. Get the message. You've been saying, you're going to get punished.  So Sayyidina, Hud was saying, look, you are in the punishment. You are in the punishment, guys, because the rains have stopped. That's the punishment. They said to him, what? You think that's the punishment? No, no, no. The only reason why it stopped raining is because of you. That's what they said to him. The rains have stopped because our gods have cursed us and you, because you're still wandering around saying bad things about them. The moment you leave, that's the moment the rain comes down. Don't understand? It's your problem. Subhanallah, how do you argue with these people? Allah tells Hud, and his followers to leave town. They leave. When he leaves the city and all the believers leave with him, don't forget, they're giving up their belongings, giving up their houses, giving up anything. And you can imagine, there's almost like a party here now. They're thrilled. The guy's going. Man, bad time. Get out of here, man, quick. They started to cry unto their gods. They used to offer sacrifices for their gods, and they started asking their gods for rain. Now, whilst they were invoking the idols, suddenly they heard a voice from the heavens.  Then they all replied, yes. What color clouds do you all want? Do you want yellow clouds? Do you want red clouds, blue clouds? What color do you want? They all cried out, we want gray, dark clouds. Why? Rain. Because the minute you see dark clouds, what comes to your mind? Ah, it's going to rain, masha'Allah. Right? The voice said, fine, you will have it. And now they were happy. They thought their invocation to their gods had been answered, and now they started to expect the dark gray clouds that were promised to them. They see a beautiful thing that they've been waiting for. One day, a gray, dark cloud is coming. We don't look often enough to the skies any more, man. They say, woo! Do you see, guys? All these years we've been saying, the man is cursed. He's leaving now, and our gods are bringing the rain back again. When they saw this cloud coming to them, Everything works, ay? They said, this cloud is coming to give us rain. Say, Allah makes you feel comfortable, feel very comfortable. Feel very secured. But Allah says, if my servant secures me in this dunya, I'll make him fee me in the hereafter. And if my servant fees me in this dunya, I'll secure him in the hereafter. Little than you, this cloud was the beginning of a great end. Rasulullah sallallahu alaihi wa sallam, when he would see clouds approaching Madina, his face would change. You can see that he's worried. And Aisha would notice that she asked Rasulullah sallallahu alaihi wa sallam. She said, oh Rasulullah, when people see the clouds, they are happy, especially in Arabia because they don't receive lot of rain. When people see the clouds are coming, they are happy. They are very pleased. So Aisha said, when people see the clouds approaching, they are happy, but you look anxious. Rasulullah sallallahu alaihi wa sallam said, because a nation before us saw these clouds and thought that they had mercy. They didn't know that it had the punishment of Allah sallallahu alaihi wa sallam. Rasulullah sallallahu alaihi wa sallam had the fear in his heart. Allah subhanahu wa ta'ala says, So we sent upon them furious wind in days of evil omen for them, severely cold and very ringing and loud voice, and very furious. This is the wind Allah subhanahu wa ta'ala sent on them. Anything that this wind will pass will make it like dust. So the people of Aad saw this. They ran into their palaces, into their houses, into their mountains. They thought will be protected here. Your Lord is great. And his punishment is severe. Allah sallallahu alaihi wa sallam sent on them the wind. This wind will grab them, will take them up to the heavens. And those who thought they could hide into their palaces, into the mountains. Allah will send the wind inside the mountains, will grab them, take them out, take them up to the heavens. And he started to swirl them around. These giants, now these are not normal people. For the whole 24 hours, Allah gave you permission to go completely out of control. So it came around and he was twirling and twirling. Now 24 hours have gone. No, then Allah says, I let it continue the next day. It's carrying on. These people are still in the air. They're carrying on.  That's pretty horrible man. They're all the buildings, their belongings, they're all their pillars, all their luxuries, all of it's in the air. Allah said, I left it there.  Please let me know in the comment section as well if this is authentic, because oftentimes I really do not know. I'm just watching those videos and I have to take their word for it. I haven't found those stories like that in the Quran. So I assume that they are in the Hadith. So if they're authentic or not, I do not know. So please let me know. Day, the wind was still blowing and then the wind went, but then he went strut on the ground. It hit them on the ground. What happened is when they were left on the ground, they weren't in one piece. They were twisted and they were twisted limbs. Yes, but basically what Allah had done to them is Allah had broken every limb of their body. So you saw arms there, you saw hand there, you saw feet here, you saw body there, you saw parts of a body here.  Now this world has never seen such a natural disaster in its history. Allah says that we might give them a taste of disgracing torment in this present world, but surely the torment of the hereafter will be more disgracing and they will never be helped. What was the result? When the dust settled down and you walk into the nation of earth, what do you see? Allah Subh'anaHu Wa Ta'ala says, so that you could see men lying over thrown as if they were hollow trunks of palm trees. These were very torment. So Allah Subh'anaHu Wa Ta'ala said, they are like palm trees that are knocked down, upside down lying dead. And then Allah Subh'anaHu Wa Ta'ala ask us this question. Allah Subh'anaHu Wa Ta'ala says, do you see any remnants of the people of earth? We have remnants from the people of Rome, the pyramids. We have remnants from Samud, the dwellings of Samud. We have remnants from the Greek Empire. We have remnants from the Roman Empire, but from the Empire of earth, we have nothing. Allah Subh'anaHu Wa Ta'ala completely destroyed them because they were the most powerful. So Allah Subh'anaHu Wa Ta'ala completely erased them from the face of the earth. And now it is the land called Allah Haqqaf, sand dunes. You don't even see nothing. Nobody even lives there. It's the desert now in Hadramouth, known Allah Haqqaf. It's the desert, empty.  And Allah Subh'anaHu Wa Ta'ala did not give the permission to that wind to go near hood and those who believed with him. So the wind will come and move away from hood and those who believe with hood and hood was in a shed with some carols. And Allah Azza wa Jalla even protected those carols from that wind. Allah says, and when our command came, we rescued hood and those who believed with him through our mercy and saved them from a severe chastisement. When Hood alaihi salam returned and saw them this way, he said the following words, I advised you also but you O people do not like the ones who advise you. And the believers with hood left in Hadramouth in Haqqaf as all believers. And once again believing in the oneness of Allah Subh'anaHu Wa Ta'ala the Tawheed took over the land until Hood alaihi salam passed away and it was buried in Hadramouth in Yemen. After them by many generations and from them the tribe of Thamud will come. And the tribe of Thamud is one of the offspring of the tribe of Aad. The minute they forgot about Allah Subh'anaHu Wa Ta'ala Allah Azza wa Jalla he sent a prophet to them to remind them about Allah Subh'anaHu Wa Ta'ala and what was his name? His name was Salih alaihi salam.  We ask Your forgiveness and we repent to Him. May God bless you all, much love and peace.


Hi guys, it's Andrew Klein, a speaker trainer and emcee. I have just completed a webinar with the wonderful team from Redback Conferencing. Troy was looking after the AV behind me. He was absolutely awesome. Sara set the whole thing up behind the scenes. I've done webinars before. This was absolutely easy. The lead up questions, the lead up communication that I had was all very, very smooth. I got everything that I needed and then on the day, Troy and Sara took me through everything that I needed. Technology seemed to work well. They were lovely. They were easy. They were engaging. I'm sure technologically everything went well. Highly recommend the team from Redback Conferencing. They did an awesome job. Thanks guys.