Showing posts with label 750words. Show all posts
Showing posts with label 750words. Show all posts

Thursday, 8 May 2014

I'm in love!

And this doesn't happen often, for I'm one tough customer when it comes to culture such as books. Luckily it however happens so often that I can claim my brain isn't calcified beoynd redemption. Last time I fell in love for a book (or in most cases, a series of books) was four years ago, when I met the Bernard Cornwell's Saxon Tales - books, in which we followed a saxon in the ninth-century britain. The books are as historically accurate as possible without giving up the poetic license, and contain moderate amounts of violence (where moderate amount means twenty saxons killing hundreds of vikings in a shield-wall without casualties :)). So, basic stuff you'd expect an Age of Empires II fan to love.

And what have I fallen for now? The Stephen King's Dark Tower, that's what. I've been told now and then for the last five years how I should read something from the King, because why should I not read them? I didn't care to read that stuff for such lame arguments (and in fact, reading anything that needs arguments to justify the reading is dumb), and I always categorized King as something people my father's age read, mainly because his bedside table always contains at least two King novels. By doing that I forgot that most of my father's books, or at least the Hitchhiker's guide and Stainless Steel Rat, are in fact among the best I've read.

Anyway, I spent a weekend in Estonia. There, I found myself in a local bookstore's area of english books, for I find my skills of Estonian language lacking. They had a shelf dedicated to the King's Dark Tower novels. I had seriously thought of reading a book or two, so a quick call to my father revealed that he has parts 2, 3 and 4 at home, so I have to buy only the first. Then, I spent a week reading the book, sometimes wondering what kind of funnytea he had drunk while writing, sometimes laughing to the genious twist in the plot. After that week I began the second book, and after a week I'm now reading the third, with great difficulties in putting it down and beginning to read stuff I'm supposed to read currently (if you need to know, electricity physics and such).

The first book was a bit dull, but undull enough to get me to pick up the second book. The second book had weird initial situation, most of the first few hundred pages happened inside a mind of a heroin courier. This sounds like a generic american movie, but in fact that worked nicely. A heroin addict, recovering or not, is also a good character to wonder the weirdness of the world, as I think the Holmes NYC tv-series has demonstrated. After the initial shock of the feeling of an american movie, the book had some cogitation on the evil of the world, both natural occurring and man-made, and nice, abstract symmetry. And doors in a bloody beach! I had great doubts on them, but their absurdity actually works!

The first part of the third book was a bit boring, maybe too much pondering on irrelevant things, or something, but now that we're following Jake once again, I'm trading hours of sleep for the pure enjoyment of reading the book.

As a writer myself, I'm mainly reading these to get my muse to sing for me again. The first 'Lomaproosa' owns its existence to Assassin's Creeds, Cornwell's books, and a bit on Witchers (both the books and the games). Albeit I probably wont borrow the huge amounts of absurdity from the Roland's universe, its effect will be visible in the second instalment of Rajol Al-Ramal's adventures. I love how the Roland's world feels to have seen all the great things in the past, and now the only thing it will see is its own demise. That kind of a setup provides multiple possibilities on asking big questions of life, but tales consisting mostly of these questions are horribly hard to write to be interesting.

And what is the conclusion, what am I trying to say with this short text? Damn if I know. Maybe it is that everyone should read the Dark Tower - series, because why should they not?

Friday, 25 April 2014

Email rant

Good day to you. I think communicating with people isn't as good as it could be these days. For example, the SMS represents the least horrible way of communications. If you do call someone, you have to try to do sort-of face-to-face communications without being able to communicate nonverbally. I don't know about other people, but at least I rely much more on the nonverbality when discussing face-to-face, and thus making a phone call feels like driving a car without wheels. With SMS you don't have the social pressure of forming the response in milliseconds, and thus you are able to actually think before saying things, and you have also time to play little verbal games. However, SMS is not the final solution to the problem of communications. They are really used only in the phones, they originally had the stupid 160 char limit, and again, I don't know of other people, but I hate doing SMS with a touch screen.

How do we, for example, communicate with computers? Well, with emails. Emails are another thing I hate with firey passion, alongside the phone calls. You always check the mail folder too often or too seldom. Done too often, your real jobs suffer, and done too seldom, people will complain. You could setup the Outlook on your pc to ping you every time it receives mail, which'll lead to the former problem, or you can use the web clients, which'll lead to the latter. I think the only thing worse than receiving email is sending it, for you have to prepared for the recipient to read it either immediately or sometime within the following decade. With email the misunderstandings are the easiest and the worst, and with the previous problems, they'll probably be noticed too late. And then there's the problem of spam. Luckily the problem of completely irrelevant spam has been solved, but the problem of almost relevant spam is still strong. The usual cause for the almost relevant spam are the people that don't know how to use the email. They'll send mail to whole school groups, when the mail is relevant to maybe three out of the fifty students, because they don't know who it is relevant to. Subject lines with the pattern [Re:|Fwd:]* (hoping I got the regexp correct :P) are sign of collective stupidity of both users and email clients alike. If the discussion has more than two participiants, making a flattened representation of the discussion tree up to the present moment is unbelievably hard, if not impossible, and the signatures with a length of a Yegge's rant make following the discussion even larger pain in the ass. And guessing how formal to be in the mail? Hard.

So, emails might have been a good idea a few decades ago. What else do we have? Well, one can always build a persistent communication tool around the discussion board - concept, but, unlike emails and calls, has never been not-stupid idea. You either setup some PHP-based abomination who first saw daylight fifteen years ago (and thus working inside it is nothing like working with a tolerable PHP-codebase), or you experiment with something like Discourse, on which I wouldn't base my life on. Or, in my case, with little work I could hack the Pröng to be a tolerable PHP-communications-board to achieve anything, for the code isn't actually bad (despite the database interactions being a slight WTF), but that's not an option for general people because I can't be arsed to release the source code.

And the last, but not in any way, the least: the instant messages. If your friend is not online, they work sort-of like email, and if the friend is, the friend is forced to react to it somehow. This has the same productivity problems as setting up the Outlook to ping upon every new email, but for some reasons it feels not as awful to me. If the friend doesn't react with at least response like "ok" within a few minutes, he probably is never gonna react, and if there's miscommunication, people can immediately (or if the other participiant is offline, once he logs in) ask for clarification. The IM-discussions also scale to multiple participiants much more nicely than emails. The formality usually is a no-problem, for the tone of discussion is usually the same as would be in a gang of friends hanging out.

Unfortunately, most of the IMs of the day have an awful user experience. And in case they have a good UX like the five-year-old Windows Live Messenger -09 had, they have minor fuckups one can't fix themselves, and the customization- and expansion possibilities are fairly limited. These I try to fix with the IM-project of mine, which currently lacks a good name. I'll maybe tell more about this thing's current state, but now I'll move to the sauna. Til the next time!

Friday, 21 February 2014

Babbling of the Lomaproosa

I don't think anyone but Tässi will understand anything of this mind dump for I've still not managed to publish the old Lomaproosa anywhere. However, let this be published here, in a place where it is easily fetched.

I should continue the Lomaproosa - project. I have been doing thinking, and I am sure the stealing of Rajol's children would be... well, it would be a cliche, but a cliche that kickstarts the story. I'll edit it into something else if and when I see fit. The children, who Rajol doesn't know are his, are stolen to the lands of the south. Who are these thieves? And what the hell exists in the south?

Some time ago we decided with Tässi that although in the regular maps the north is in the up and west is in the left side of the map, in the maps of MERPG (available in the merpg.webs.com) the north is to the left and the west is thus to the down. This provides some sort of help for the cartographers (in other words, me, until Tässi is again available), but I fail to recall the exact nature of this help. Still, what is there in the south?

There should not be grand wizards, for they are supposed to be dead now that the Tuula was got rid of in the end of the previous text, and bringing them back would be as ridiculous as the Daleks, who are killed into extinction in the every other series of the Doctor Who. Pirates, which I think I spoke something of in the previous text, are also a ridiculous cliche, albeit a popular one. I should play the Assassin's Creed 4 through though until I write anything real of the pirates.

But what do I put into the south!? Who would be stupid enough to steal the children of the greatest hero the universe has ever seen. And how should the said hero understand the kids are his? And how should I get back to the guild he thinks views him a failure? And, of course, WHAT DOES EXIST IN THE SOUTH?

Let's try associations. In the lion king, there are the lions, who can be associated to the guild in my texts. Then there are the animals that aren't lions, but aren't the hyenas either. These can be associated to the common folks. Then, the hyenas, the awful guys. Who can they be associated to?

Some sort of nomadic tribe, I'd say. They don't know anything of the magic, which I'd say didn't work too well in the old text, but with their swords, horses and siege weapons they are extremely fatal to both villages such as the Vo Wacune (a tribute to the author who introduced me to the genre of fantasy, may he rest in peace) where the Rajol resides, and castles such as the guild's, resided by the assassins and their leader, Rajol's beloved Amrah. If these guys raze the Wacune (again with the tributes...), harass the guild into its knees and destroy half of the world that survived the mass destruction of the first story, I'd have a base to build the story on.

But what does motivate this tribe to attack the northern world? I could follow the Conn Iggulden's idea of the civilized world discriminating the nomads, but what for would the Amrah, the undoubted leader of the post-war world and one trying to unite the world, do bad things against them? No. Are they lacking in food, and also attracted by shiny metals the cities of the north are filled with? Yes, that could work. Food and gold, another cliche, but I'm not afraid of them, as you could see had I published the old text anywhere.

Thursday, 20 February 2014

Documents and stuff

Again a good text from the 750words experimentation. Remember that these are more like brain dumps than actually researched and thought texts:

Well, this day was almost gone until I remembered that hey, I still have the daily 750 words undone!

The school today was awesome for once. It seems I'm doing the IM-project I've babbled about everywhere for the project-classes, which means I have to really put my hours to a book. I resist the "use excel for bookkeeping of hours" - clause of our instructions though. .xsl(x) is a stupid format in Windows, and completely useless in the real world. Currently I do the bookkeeping as a series of Clojure maps, with keys like when, count of hours, and what did I do. I think the git could provide the when and what is done - values, but it is useless in keeping track of the hours used. I think there exist real apps for tracking the used time per project, but since the school is too lazy to propose anything better than Excel, I'm also too lazy to experiment with stuff that is not guaranteed to be better than Clojure.

If I am allowed rant more about the office formats, I want to express my utter dismay about the state of the document-producing software of ours. First: MS Word is... well, if the document is expected to follow formal standard, then it is a nice tool, although producing software with strict, formal standard is dumb. For producing somewhat informal text that doesn't look like it is done by agitated baboon it is horrible. For that I use Emacs. Today I translated and edited the first IM-blogpost into a "starting report of the project" by writing finnish into an org file in my blogging folder, and then let the Emacs export it into something that doesn't yield "WTF is this format?" - responses. I hoped the odt would be enough, since at least in the Emacs of my mac the creation of pdfs is somewhat challenged, and producing docx:s from anything usable is not a walk in a park. Of course the response was "can't you... export it to pdf or something from that linux of yours?"!

Yeah, hold on a second, I'll just brick this macbook with a fresh install of fedora or something...

I spent ten minutes trying to get the latex->pdf - exportation working, and after failing that, opened the exported odt in the Libreoffice Writer, the only thing worse in producing text documents than Word, and exported the document into pdf.

I think the project document was accepted, and now I'm rewarded with credits for working on this thing! I have yet to check the official site where these projects are hosted, but at least I received no complaints as a reply to my email where I attached the report. I was also told the school could give me a hypothetical server in case the Heroku fails, but I am not really looking forward to that, since as far as I understand, they do not have too many public IP-addresses, and I am not absolutely certain I'm able to keep the security holes out of my code.

After giving my report I resumed hacking the server of this IM (which by the way needs a real name. I think the old MEsE is a stupid one, but this faceless "the IM-project" is also such.), and found out that the server doesn't correctly update the moment of the last call any time the client calls. This means that after five minutes from the logging in the client is officially timeouted with no way to reset the timeout. Let me tell you, the state will be the end of this world.

I should do designs of the client at some point. I've spoken of this project only as a better Skype without the VoIP, but that doesn't seem to be enough to convince some people about how awesome this project is, and neither does the fact that only thing I've got to show of it are some four blog posts and a screen full of Clojure. I have seen a few people that wanted to take part in this project if I switched the implementation language to something "sane", like the Java or C# we're being taught in the school, and in a general case I could do this (although assuring them the project will probably be doomed after it), but with this project I've actually tried them. The Java was lousy in the server side, and although the C# was somewhat verbose in the client side (compare XAML to s-exprs... :P), I could see me doing an alternative implementation of the client in C# sometime.

Monday, 17 February 2014

Authentication scheme

Hello, friends! I am back in Kotka!

The Friend - authentication library of Clojure seems interesting, but because I'm a bad coder, who probably seems to hate sunshine, green grass and all other good things on this earth, I can't be arsed to learn to use this ready but large library that is somewhat complicated for my simple needs. I will probably earn a The Daily WTF - headline with this text, but a coder who has not done that, isn't a real coder :)

I am also too lazy to teach myself how authentication against Twitter's and Facebook's user databases would work. In the spirit of the Worse is Better, I will hard code Feuer (myself) and a few test accounts to the server and I abstract the user-authenticates? - function somehow nicely and I'll write the user management on either CouchDB or the previously mentioned SOME-services. When the authentication works, I'll write the web-API (REST-API?) (and test it somehow...) and begin writing the proof of concept of the client program.

It is unnecessary to dream of the clients and other stuff until the authentication works. How then should it work? In the beginning, the server is minding its own business, and then it finds a surprising login-request from the Compojure's level. The Compojure receives username and a naked password as parameters of the request. The password can not be hashed in the client, since if I remember correctly for the reasons I can't say I understood, the output of the hash-function is dependent on the environment it was called in. Both Java and PHP have given me different hashes in linux and windows for the same input in the past.

The password is immediately hashed with the sha512, and the userdatabase is queried with the username. If the username is found and the password matches, the user is authenticated and the client is responded with HTTP statuscode 200 and the sessionid, which is used for the authentication here onwards. Authenticationsystem updates the sessionid to the sessiondatabase with the current System/currentTimeMillis - value. Sessionid is also associated with the IP it was sent to, so that cracker guessing these ids can't get access to the session although finding an existing session-id unless they happen to be under the same public IP as the original owner of the session.

The rest of the requests do need the session id as a parameter. If the sessionid is found lacking, non-existant, the timeout has happened (the time from the last System/currentTimeMillis is more than 5 minutes (or 30000 millisecons)) or the requesting ip has changed, the request is dropped with response 403.  With every succesful request the moment of the latest request is updated to the currentTimeMillis.

What else? I don't know. The server's authentication scheme is hereby documented. Please tell me if you see something wrong with this.

Oh, and did I mention? I'm back in Kotka after a weekend in Espoo. This week has a possibility of being an awesome one. After my morning exercise (in other words, about three kilometers with a bike) and a couple of cups of tea, I'm ready to bleed some Clojure into the Emacs. Unfortunately I have the thing known as the school blocking my creativity here. Well, today I have a physics class, so the schoolday is in fact a bit more interesting than usually. And it isn't a long day in school. Unfortunately tomorrow I have to rise early for school, so I am not able to code tonight until 2 am. Hopefully tomorrow is different :)

Let me fill the word quota by expressing how dissatisfied I am with the gray the sky has been filled with for almost a month now. I'm sure I spotted the sun a couple of times in the January and the December, but this month has been a british one: rain, rain and not rain but still awfully gray. Luckily when I have been cycling the rain has kept away. In June a little rain isn't that bad (especially when I'm on a bike), but other times only weather condition worse than rain are the snowstorms.

I'm horrified how bad I'm in holding a train of thought even for as small texts as 750words requires. Then again, my daily thoughts don't take so much written space, unless I'm pondering on something locally revolutionary, such as the IM-project, which has filled almost three 750words texts now. Unfortunately all three of them have exploded into this kind of rubbish by the end.

Thursday, 13 February 2014

~600 words on IMs and school

I have been doing 750words every morning this week, and now I have a text I feel could be published also here. It's not long, most of the rubbish I wrote in the original 750-entry has been edited away, but it has some interesting material concerning the yesterday's post. And I hope I'll publish more of them. The long text once in two months - method I've been doing here since discovering Yegge's blog hasn't been merciful on this blog, so I'll try to ape Swizec's way of writing shorter stuff at least weekly, and I'll try to wander outside the programming niche.

Last night I unveiled some new thoughts on this instant messenger - project I've been doing for a few years. I think the SMS is the best instant messaging technology we currently have, and I don't mean this as a compliment for those Nokia engineers who made this techonology two decades ago. I mean that as a compain to us fools who have had the microcomputers for three decades now, and the best thing for communicating with them is the IRC. Five years ago we also had the Live Messenger, which was barely better than writing SMSs alongside the coding, but the Microsoft killed the thing: first they created the Live Messenger 2011, which did have probably one improvement, but it also had dozens of stupid ideas, and the stupidest of them: after a year the thing was killed by Skype. Skype is somewhat usable as an AV-phone, but it is horrible with textual messaging.

From the mild attention I got (one, probably bot, more follower in twitter and one comment in the facebook) I can deduce this thing could gain some traction in the market. Unfortunately, if it gets, I really have to familiarize myself with the ad-networks, because I don't expect the free heroku-server to support more than five concurrent users. In the weird case I get the system to pay itself with the ads, I'll become one very happy panda (to utilize an odd metaphor). If the thing will generate revenue, I might also write clients for the three mobile platforms. There the ad-systems should be easier to implement than in the computer land, as would be getting the people to pay for the clients.

This project might also be applicable in the school. We have these weird classes known as the project classes, where us students are expected to come up with an idea (since we're too inexperienced to implement existing ideas for the local software companies, or something) and implement it. I think most of us will do some game or another, but since I'm not currently in the mood for developing such things, I'll try to get the yesterday's blog post accepted as a design for my first project. The only problem is: the projects are supposed to be done in groups with two or more people, and I'm actually a little afraid of opening my mouth on stuff that actually matters. So trying to sell this idea to one or two other people is hard, even if I was implementing my IM on more traditional tech. I imagine Clojure looks like ancient greece to guys who barely have their feet wet with C#.

I just asked in the facebook if anyone actually would be interested in this project. Let's hope someone responds out of serious interest, not out of "Feuer is ..." for some stupid reason, if I may add, "... deemed to be a wizard in programming. Let's hope the wizardness overflows to me also!" - feeling. For some reason the two (or three? or four?) people who I am certain would have any valid input (in either designing and programming sense) for this project don't even live in the Kymenlaakso.