Archive for the ‘Uncategorized’ Category.
…is that they are too important to take time for the grunge work that makes a technical book useful.
Agile Web Development with Rails is essentially a book-length tutorial, and imho not worth either the money or time. The entire book is narrative. It admits as much in the introduction: “This book isn’t meant to be a reference manual for Rails…reference manuals are not the way most people learn.” Maybe so, but they are extremely helpful productivity tools when trying to do actual work! (The narrative itself is so patronizing and self-aggrandizing its painful to plow thru, though probably does have some value if you can stomach it.) An auto-generated code API is no replacement for a human edited reference manual with context. It seems Rails requires you to ‘read the code not the docs’ in order to do anything nonstandard, which works, but…not exactly productivity enhancing as advertised.
Browsing a good reference lets you see immediately the structure of a framework.
PHP.net is beautiful and so efficient, I’ve never bought a PHP book either – but for the opposite reason I’d advise not buying this one.
The thing that is the most annoying about rails, after the general atmosphere of one-upsmanship, is that the general arrogance about being the best way to do things seems to lead to lack of good reference documentation. Tutorials for specific ways to do a particular task in ‘the Rails way’ abound, but reference docs are limited to the actual api for the code. Method-level references with clear explanations are just..nonexistent.
Everything is eventually possible, with much reading of code and blog posts, but clarity as to what is possible in a given context – missing.
Ruby is a beautiful, elegant language. Rails popularized the idea of scaffolding, and yes, if you want to do the standard shopping cart of database items you are done in 8 minutes. However….if you want to do something else entirely, every step needs to be painfully discovered by deep introspection….
Of course Joel says this so much better: Joel on Rails
Using a shared gemset between two projects may be a bad idea, not sure. After installing vhochstein’s Rails3 branch of ActiveScaffold in the second project (tho not sure that was the key factor), I started getting this error on running rake db:migrate:
“no such file to load — net/https. Try running apt-get install libopenssl-ruby”
Tried many of the suggestions at http://www.ruby-forum.com/topic/90083 without help…finally, decided it was rake at fault, just ran
gem install rake
(even though it was already installed), and the error went away…
Here’s a thought on how to code to spec:
Write a clear, concise design document for your application that can be understood by users and domain experts. Use brief, simple language as much as possible with some preferred constructs.
Then write code that makes the design document run.
Seriously – why not? It seems to me code should be more about language constructs, building powerful syntax for expressing functionality. So why not build up the syntax that makes a design document into a program?
I was thinking about the old LOGO functional language from Seymour Papert, the one with turtles that you could teach to do things ‘to square: forward 10, turn 90, forward 10…’ then ’square, forward 10, square, …’ etc. The logical conclusion seems like it should bring us closer to bridging the gap between language and code, or at least lead to more libraries of syntactical constructs. OO is fine for nouns but it doesn’t lend itself well to creating new verbs, let alone sentence structures.
Ah well – back to implementing my HLD manually…