Prošle noƒái sam izgubio 4h na debagovanje i modifikaciju koda koji je bio ispravan, ali nije radio – a ja sam jedva provalio o ƒçemu se radi. Glavni krivac bio je Windows, a šta se desilo, kako sam otkrio o ƒçemu se radi i kako sam problem rešio, saznaƒáete vrlo brzo Naime, razrešenje ove misterije nije išlo gore pomenutim redosledom, pa upravo zato i reših da svoje iskustvo podelim sa ostatkom svet.
Pretprošle noƒái krenuh u realizaciju jednog mog mini WEB projekta. Kako su pitanju XHTML/CSS + PHP/MySQL tehnologije, krenuo sam sa radom u lokalu. Startovah LAMP pa se bacih na izradu baze i back panel-a. Zakljuƒçno sa sistemom za logovanje korisnika, privedoh rad kraju za taj dan (noƒá zapravo) pa sam sve do tada uraƒëeno okaƒçio na server. Probao sam skriptu i sve do tada implementirano je radilo bez ikakvih problema.
Onda prošle noƒái reših da malo sredim kod, formatiranje i komentare, pa sam sve ponovo svuk’o u lokal, sredio i vratio online. Jedina razlika bila je što sam ovog puta radio sa WAMP-om na mašini sa Windowsom. Ništa znaƒçajno nisam menjao što se koda tiƒçe, ali ipak reših da još jednom proverim da li je sve ok. Kad imam šta i da vidim: na svakom fajlu pucaju neke funkcije (2-3 uproseku). Od svega su se najviše bunile sesije (kreiranje i promena podataka). Tu je krenulo 4h pakla sa istra≈æivanjem šta taƒçno ne radi i zašto se od jednom buni, a prethodnog dana je radilo.
Ovu teoriju sam eksperimentalno dokazao na sledeƒái naƒçin: Prvo sam sve fajlove upload-ovao preko FTP-a (text-modom) gde sistem autoamtski sreƒëuje EOL. Pokrenuo sam skriptu sa servera i nije bilo nikakvih grešaka. Zatim sam iste fajlove arhivirao i ponovo upload-ovao (ovaj put kao jednu arhivu, binarnim modom) pa otpakovao na serveru. Prilikom pokretanja skripte, ponovo su se javile misteriozne greške o nemoguƒánosti pokretanja sesija.
Suma sumarum: Ukoliko se bavite WEB development-om i radite pod Windows-om, imajte na umu da je veƒáina WEB servera pod nekim UNIX-olikim operativnim sistemom (Linux, BSD, Solaris, MacOS…) te da je preporuƒçljivo da svoje fajlove spakujete u odgovarajuƒái format kako ne bi dolazilo do ovakvih problema. Sa druge strane, ako radite u Linux okru≈æenju, a koristite komponente koje su razvijala treƒáa lica, obavezno proverite da li su sami fajlovi saƒçuvani na odgovarajuƒái naƒçin. Na taj naƒçin uštedeƒáete vreme i sebi i drugima ukoliko doƒëe do ovakvih problema.
* tekst orignalno objavljen na adresi:
This my first article on linux.com
and the first thing i record is about exam,
and i hate exams, very much !!!
I just thought that I would point this out and see what others have to say.
The one thing that I keep finding when reading through linux.com is that I'll find an article that I find great and I want to indicate it as something I enjoyed by a "digg"-type button, but all I have is a "Favorite" button.
That said, I realize that there is a real Digg button, but that would mark the article up in the ranks on the actual digg site.
Request: Add a button that I can use to mark an article as worth reading. (I can mod up comments, but why not articles?)
As many of you I've decided to stop using this blog area until spam ends in this zone.
When linux.com renewed its layout I've used the Blog area to read opinions from other users and even publish some tech hints useful for myself and hopefully useful for someone else as well. I've sent few hints and some usernames to linux.com managers and they've replied back with appreciations for it.
They're now implementing a new spam filter as well as other things to keep spammers out and avoid blogs with tons of spam links, I'll look forward for this kind of improvements.
Well I have to admit that ive been looking forward to the release of NetBeans 6.7. In the last release of Netbeans (6.5) it really did feel like Groovy and Grails support was a bit of an afterthought and somewhat rushed into the release, so ive had my fingers crossed that the 6.7 release would bring solid support for this new dynamic language and great web framework. My hope was that this would be the first decent free IDE for Grails (IntelliJ Grails support looks solid).
(This is a quick look at NetBeans 6.7 RC1)First thoughts
- The first thing that I noticed was how fast this new version of Netbeans (NB) starts up, fantastic! In general this release feels a lot more responsive which is a big plus because sluggish performance has always been a weakness of NB.
- NB integration with standard Grails scripts has greatly improved, you can now clean, create a war file and open the Grails shell as well as select a Grails command from a comprehensive list. This means that you no longer have to leave NB to perform some commands from the command line (e.g. the clean command wasnt supplied in NB 6.5).
- Unfortunately there seems to still be no support for auto code completion when editing GSP pages. This is a real problem for me because one of the things I enjoy the most about Grails is its comprehensive tag library which grows as you install plugins. I use "g" tags all time, so it is a hassle for me to have to break out of the IDE to go and look at the documentation to find a specific tags attributes.
- It still looks like there is no obvious way to debug your application, you can insert breakpoints but I could not find anyway of running the application in debug mode.
- Groovy refactoring still looks as though its effectively disabled, so large complicated find and replaces will have to do for a little longer I guess.
- Groovy code completion looks like its improved a lot. My domain objects now show up with code completion tips for dynamic GORM query methods and weakly typed collections also show up with useful code completion tips. I think this Groovy code completion enhancement has been the main focus of this release.
So to be honest im left feeling a little disappointed overall with this releases Groovy and Grails support. It looks like we will have to wait a little longer for our solid free Grails IDE.
Learn more about whats in NetBeans 6.7 here
I have just joined and set up my profile in Linux.com.
I just wanted to say "hi" to the wonderful Linux.com community.
All the best
So, a wearable computer, have you ever heard of those? Probably not. I mentioned those in my last post and there's still not a group for them, or anyone other mentioning them besides me and those old TLDP-pages.
So, Steve Mann "Invented" the modern wearable computers. I'm not talking about intelligent clothes, pdas or silly wrist-worn computers one would not catch me in public with alive. I'm talking about a small computer that is preferably running some flavour of Linux, that is always with you and always ready for input and augments, that is empowers your mind in some way.
That's part of Mann's definition of the wearable, and I actually like it.
When you walk around with your wearable, you shouldn't look like a geek. At least I'd like not having a backpack full of pc hardware and a helmet with a screen, however this (the right one) is something I could wear. Figuratively speaking only, because I'm not going to stuff my boards into my underwear like he did.
So, Like I said last in my last post, I'm going to build a wearable for myself and I'm already planning it.
I'm most definitely going with a BeagleBoard as my cpu, some hacks with kopin vga microdisplay as my covert sunglasses display. I still need to decide my chorder because there is no twiddlers anymore, research how to use batteries and how to connect that displaythingy in a vga port.
I'm going for a INX like menu based user interface, mostly because I think there is no better solution for vga resolution and the wearable experience is better if there is no need for the mouse at all. It could be different if I was going for some augmented reality, but babysteps for now. Also I think it would be better for me to simplify my computer usage so I want to switch to command line for most things and only use X for stuff like Gimp and Blender.
And really, the wearable computer is a real thing, it can give you nightvision, invisible post-it notes in your office, you can have dictionaries and wikipedia always with you, code everywhere, maps and gps, to-do lists and notes, plan your interior in 3d in real life, play Quake in corridors with friends... Just see what youtube finds with "augmented reality". It's a sad thing they never took off, probably because of good displays being pricey, but it's still possible for them I think.
The Linux community can always be a better place. I have always pictured the "perfect" Linux community as one that is helpful and kind to others, nonexclusive, professional (not in the sense of business formality) and free of bureaucracy. As picturesque as that is, I have doubts to whether that will ever happen. Too many people have attitudes that limit the community. I cannot recount how many people have told me they want to use Linux but don't want to get around the online community. In this series of blog posts, I plan on addressing several sticking points that are not helping the Linux community, basically a subject per part. We're close, but we're not there yet.
The Activism Needs to End
Anyone remember the failed "BadVista" campaign the FSF ran a few years ago? Remember the protests in the hazmat suits? How about the protesters against the OOXML document format? Or even the student who ran across a stage behind Bill Gates with a sign that said "FLOSS" on it? Ever feel a little... embarassed? I'm not saying that the people protesting are not fighting the good fight, because they are, just not in the best way.
Thankfully, the FSF seems to be changing it's tune. It's turning to actually creating better products than the competition, rather than having a fit because the competition has a lock on the market. The truth is that there are better ways to approach software injustice... and step one is to not blow it out of proportion. It's just a piece of software -- remember that.
Protesting, of course, is not the only form of activism. There's also the issue of what is said online. Of course, I could make a 1000 volume book on the junk that happens online. People say a lot of stupid things -- mainly because they feel free from the consequences that could be faced in the real world. It's a shame, it's a freak show, it's the online community... not much that can be done there. However, there are a few things that can make things better for everyone. First, attack blogs need to go.
When I think of an attack blog, the first one that comes to mind is "Boycott Novell." Just a few minutes on the site makes me nautious. So many self-pointing links, angry rants (and pointless rants?... irrational rants?), and images disparaging Microsoft, it leaves me almost embarassed to say I know of anything about Linux. It's not that the site fights for a competitor, it's on our side. The site just goes about it in the wrong way - primarily by demonizing a company, and even more specifically demonizing individuals. That's not good. It makes us look bad and very unprofessional. I mean professional in the sense that we can stand competition, we face it with our own offerings, and we do not stoop to such low levels as attacking individuals. Remember, it's just a piece of software!
So, instead of activism, we should keep focusing on what we do best: software! If we stick to that, how can we go wrong? If we fall behind, it may not be because of the software, but if it really is better than the competition, people will use it. Remember that the business world is a dirty place, and sometimes someone will sleaze by with a plan that will hold us back. Help somebody on the forums, IRC, or mailing lists. A little kindness goes a long way -- a lot further than any sleazy business plan because you end up with another happy user using your software, a user earned by hard work, not just paying someone off. It is also important respect the competition, because that will give us a good reputation with end users, and possibly make things easier when working with the competition.
I'll follow up soon with Part II. I'm not exactly sure what topic I will hit at just yet, but the Linux community has given me a lot to work with. ;-)
I found this great little article about one of the most important skills required to be a great programmer. I loved this quote.
"most of programming is an attempt to compensate for the strictly limited size of our skulls. The people who are best at programming are the people who realize how small their brains are."
Its so true! Acknowledging your limited capacity will definitely make you a better programmer. Ever had that NullPointerException and instantly blamed the framework your using or the JVM? Remember a good tradesman never blames his tools.
Heres the article: http://www.codinghorror.com/blog/archives/000051.html
Linux Distribution Chooser
is thery intresting thing. I get 90% Gentoo and 90% of Slackware :)