I gave a five-minute Lightning Talk on sqlpython on Saturday. I hoped it would pique the interest of some people who sometimes use Oracle, and give them a neat example of yet another cool thing being done with Python. It certainly did that, and I got lots of gratifying feedback.
I knew people would ask when it would be available for non-Oracle databases, so I said, tongue-in-cheek, that this was my distant-future ambition for "sqlpython 3000". What I didn't expect was that several of the people buttonholing me over the next two days would ask to collaborate to get multi-RDBMS support in place. Help? Uh, yeah... I guess help would help... I honestly hadn't even been thinking about that...
Brian Dorsey in particular wanted to see the code face-to-face with me, so I put a card on the Open Space board, just in case anybody else wanted to show up, and twittered about it one bare hour in advance.
Nine people came, all of them eager to get going on writing code, bringing great ideas to get started. All this for a project that was basically personal 36 hours before.
Noooo, now other people are going to be exposed to my squiggly code! Now I know what embarrassment-driven development really is.
If I'd had $1 million of startup funding to hire a staff to work on sqlpython, I couldn't have gotten a team that large or that talented. I figure that gives me better than a 1000-to-1 return on my PyCon investment. :)
So anyway, I'm setting up a mailing list for cooperation on sqlpython, and it looks like the far-future dream of multi-RDBMS sqlpython has suddenly become imminent. Stay tuned!
Monday, March 30, 2009
Saturday, March 28, 2009
sqlpython lightning talk follow-up
This morning's lightning talk on sqlpython was an example of what's so great about PyCon - it instantly really good suggestions about how to go onward with sqlpython development, and offers of collaboration. Awesome!
Except that I forgot to show the instant graphs using \b / \l terminators. Rats! That's the most eye-catching part!
I wasn't prepared for the common question, though: "Where's the repository?" Well, it's here:
https://www.assembla.com/wiki/show/sqlpython It is crazy-unstable, and if you're actually trying to use it, use the PyPI version instead.
I mean to get a link to that into the docs as soon as possible, but I don't have Sphinx configured right on this machine, so that may have to wait.
Quick review of the lightning talk:
* Unix-like powers: cat, ls, grep, >, |
* Python interactive session; access to resultsets (`r`) and bind variables (`binds`)
* Special output formats with alternate terminators (see `help terminators`)
* The magic that makes sqlpython work:
- cmd
- cmd2
- pyparsing
- code (for the embedded Python interpreter)
- cx_Oracle
For further reference, see the sqlpython docs, particularly the comparative review of sqlpython vs. SQL*Plus vs. gqlplus vs. Senora vs. YASQL.
Except that I forgot to show the instant graphs using \b / \l terminators. Rats! That's the most eye-catching part!
I wasn't prepared for the common question, though: "Where's the repository?" Well, it's here:
https://www.assembla.com/wiki/show/sqlpython It is crazy-unstable, and if you're actually trying to use it, use the PyPI version instead.
I mean to get a link to that into the docs as soon as possible, but I don't have Sphinx configured right on this machine, so that may have to wait.
Quick review of the lightning talk:
* Unix-like powers: cat, ls, grep, >, |
* Python interactive session; access to resultsets (`r`) and bind variables (`binds`)
* Special output formats with alternate terminators (see `help terminators`)
* The magic that makes sqlpython work:
- cmd
- cmd2
- pyparsing
- code (for the embedded Python interpreter)
- cx_Oracle
For further reference, see the sqlpython docs, particularly the comparative review of sqlpython vs. SQL*Plus vs. gqlplus vs. Senora vs. YASQL.
Tuesday, March 24, 2009
Ada Lovelace Day: Tech Women I Admire
I will publish a blog post on Tuesday 24th March about a woman in technology whom I admire but only if 1,000 other people will do the same.I can't stop at one; sorry if that breaks the rules.
- As a frequent speaker at conventions and as co-author of the Python Cookbook, Anna Ravenscroft has a great talent for helping people understand problems, even the brain-bending ones.
- Dianne Marsh helps run a company that vigorously fosters good, innovative programming, both among their own developers and throughout the entire region. Her energy and dedication have been crucial to CodeMash, one of the most innovative things to happen in our area, and to several user groups in Michigan.
- Sarah Dutkiewicz, aka the Coding Geekette, is a programmer from northeast Ohio who's done great things in pulling together the geek community and teaching them new technologies (like IronPython on Mono) - often the sort of stuff that requires venturing into dragon-infested realms where the documentation is scattered or nonexistent.
- In her long-time leadership of the OOUG, Coreen Walker has helped make it one of the best Oracle groups around.
PyCon begins...
... well, the tutorials and summits begin tomorrow. But some of the organizers are already in place, getting things set up. I wish I were there! I won't arrive until Thursday afternoon - I had to sacrifice all but the core conference days so that I could make the separate trip to IOUG Collaborate. For me, it feels like arriving at a family Christmas halfway through the gift unwrapping.
Have you seen the list of PyCon sponsors this year? It's amazing! It's practically a Who's Who... if your company isn't sponsoring PyCon, your corporate headquarters is probably roofed with thatch. :) It's a tribute to Van Lindberg, PyCon's sponsorship coordinator, but even more to the growing corporate recognition that Python has become a pillar of the IT world.
Have you seen the list of PyCon sponsors this year? It's amazing! It's practically a Who's Who... if your company isn't sponsoring PyCon, your corporate headquarters is probably roofed with thatch. :) It's a tribute to Van Lindberg, PyCon's sponsorship coordinator, but even more to the growing corporate recognition that Python has become a pillar of the IT world.
Friday, March 20, 2009
Where to host docs?
I'm working on some preliminary sqlpython docs using Sphinx, which is really really nice. No guarantees that they will remain there, though - they need a home without a raw IP address for a URL!
I'm trying to figure out a permanent home for the docs. Here are the possibilities I know of.
I'm trying to figure out a permanent home for the docs. Here are the possibilities I know of.
- Host the files on my own server. Buy a domain name (but not like last time). This is obviously the best option... unless I ever decide to quit paying for the domain, or the server, or forget to, or get hit by a bus. So really, I'd prefer something that wasn't so dependent on, well, me.
- Sourceforge, Assembla, Google Code, and probably everybody else who hosts projects also let you create and host wiki-style documentation. As far as I know, though, there's no way to upload Sphinx documentation into any of them; the wiki form and the Sphinx form are not compatible.
- Google Pages gives you free webpages with a reasonable URL - but no folders. Sphinx depends on a folder structure - it creates folders "html", "doctrees", "_sources", "_static", and maybe more once I get serious.
- Creating a Google App Engine to host the docs - now this is an intriguing possibility. I'm going to check it out. Still, it would be nice if posting the docs for a technical project were not, itself, a technical project.
Thursday, March 19, 2009
sqlpython 1.6.1 puts the "python" in "sqlpython"
I've been asked several times, "Why is it called sqlpython?"
My answer used to be, "Ask Luca [Canali]; he wrote it."
Not anymore. Now, witness the power of this fully armed and operational hybrid SQL/Python working environment.
[EDIT: As of sqlpython 1.6.2, you use quit(), exit(), or Ctrl-D/Ctrl-Z to return from
interactive Python mode. See docs.]
A history of result sets from each query is exposed to the python session as the list `r`; the most recent result set is `r[-1]`. Bind variables are exposed as the dictionary `binds`. All variables are retained each time the python environment is entered (whether interactively, or with one-line `py` statements).
Resultsets in `r` are read-only, but `binds` can be written as well as read, and will be working bind variables in the SQL environment.
Oh, the possibilities...
My answer used to be, "Ask Luca [Canali]; he wrote it."
Not anymore. Now, witness the power of this fully armed and operational hybrid SQL/Python working environment.
[EDIT: As of sqlpython 1.6.2, you use quit(), exit(), or Ctrl-D/Ctrl-Z to return from
interactive Python mode. See docs.]
0:testschema@eqtest> select title, author from play;
TITLE AUTHOR
--------------- -----------
Timon of Athens Shakespeare
Twelfth Night Shakespeare
The Tempest Shakespeare
Agamemnon Aeschylus
4 rows selected.
0:testschema@eqtest> py import urllib
0:testschema@eqtest> py current_season = urllib.urlopen('http://cincyshakes.com/').read()
0:testschema@eqtest> py
Now accepting python commands; end with `end py`
>>> r[-1]
[('Timon of Athens', 'Shakespeare'), ('Twelfth Night', 'Shakespeare'), ('The Tempest', 'Shakespeare'), ('Agamemnon', 'Aeschylus')]
>>> for row in r[-1]:
... print '%s by %s' % (row.title, row.author)
Timon of Athens by Shakespeare
Twelfth Night by Shakespeare
The Tempest by Shakespeare
Agamemnon by Aeschylus
>>> [row.title for row in r[-1] if row.title in current_season]
['Timon of Athens', 'Twelfth Night']
>>> binds['nowplaying'] = [row.title for row in r[-1] if row.title in current_season][0]
>>> end py
0:testschema@eqtest> print
:nowplaying = Timon of Athens
0:testschema@eqtest> select title, author from play where title = :nowplaying;
TITLE AUTHOR
--------------- -----------
Timon of Athens Shakespeare
1 row selected.
A history of result sets from each query is exposed to the python session as the list `r`; the most recent result set is `r[-1]`. Bind variables are exposed as the dictionary `binds`. All variables are retained each time the python environment is entered (whether interactively, or with one-line `py` statements).
Resultsets in `r` are read-only, but `binds` can be written as well as read, and will be working bind variables in the SQL environment.
Oh, the possibilities...
Friday, March 13, 2009
Senora 1.0.1, and mutual FOSS goading
Martin Drautzburg just published version 1.0.1 of Senora, a command-line client for Oracle that makes a very attractive alternative to Oracle's SQL*Plus.
The timing - seven weeks before I present a review of Senora, sqlpython, and others at IOUG Collaborate - is not a coincidence. I asked Martin to review my draft paper submission for the conference. He graciously did, and supplied several crucial corrections and additions regarding Senora.
He also mentioned that he'd been continuing Senora development for in-house use, but that it had been years since he'd released the updates. My upcoming review spurred him to do the release.
And what a release it is - it's full of awesome! Mighty new flag options! Multiple sessions! Automatic generation of Senora commands from SQL scripts!
It sent me to scheming about how I can copy this fresh goodness to sqlpython.
Plus, of course, the paper reminded me painfully of some of sqlpython's shortcomings. I'm starting to use the sqlpython trac seriously now, as a token to myself of my goodwill. This will probably lead to a spurt of Embarrassment-Driven Development before the conference.
FOSS people know what the ancient Romans knew: money is a feeble motivator compared to glory. (Half the time, people only want money so they can buy things that will make them feel glorious...)
The timing - seven weeks before I present a review of Senora, sqlpython, and others at IOUG Collaborate - is not a coincidence. I asked Martin to review my draft paper submission for the conference. He graciously did, and supplied several crucial corrections and additions regarding Senora.
He also mentioned that he'd been continuing Senora development for in-house use, but that it had been years since he'd released the updates. My upcoming review spurred him to do the release.
And what a release it is - it's full of awesome! Mighty new flag options! Multiple sessions! Automatic generation of Senora commands from SQL scripts!
It sent me to scheming about how I can copy this fresh goodness to sqlpython.
Plus, of course, the paper reminded me painfully of some of sqlpython's shortcomings. I'm starting to use the sqlpython trac seriously now, as a token to myself of my goodwill. This will probably lead to a spurt of Embarrassment-Driven Development before the conference.
FOSS people know what the ancient Romans knew: money is a feeble motivator compared to glory. (Half the time, people only want money so they can buy things that will make them feel glorious...)
Thursday, March 05, 2009
using TurboGears 2 model outside TurboGears
Until/unless this ticket gets incorporated into the TurboGears 2 docs, I (for one) need a reminder about how I can make use of a sqlalchemy model, set up from a TurboGears 2 instance, for projects that don't actually start or use TurboGears. (I want a single, canonical sqlalchemy model for my database, for its web-based and non-web-based applications alike.)
Including this function in my model/__init__.py does the trick.
Including this function in my model/__init__.py does the trick.
import paste.deploy, os.path
def externally_usable_session(configfile = 'development.ini'):
tg_home_directory = '/path/to/tg2instancehomedirectory'
conf_dict = paste.deploy.appconfig('config:%s' % os.path.join(tg_home_directory, configfile))
engine = create_engine(conf_dict['sqlalchemy.url'])
init_model(engine)
return DBSession()
Monday, March 02, 2009
sqlpython 1.6.0 with Wild SQL
I just released sqlpython 1.6.0.
SELECTing a limited, but large, set of columns from a table is a real pain. What if you could use wildcards in the column list of the SELECT statement itself? Wouldn't that be wild?
OK, then, let's SET WILD ON.
SELECTing a limited, but large, set of columns from a table is a real pain. What if you could use wildcards in the column list of the SELECT statement itself? Wouldn't that be wild?
OK, then, let's SET WILD ON.
jrrt@orcl> cat party
NAME STR INT WIS DEX CON CHA
------- --- --- --- --- --- ---
Frodo 8 14 16 15 14 16
Gimli 17 12 10 11 17 11
Legolas 13 15 14 18 15 17
Sam 11 9 14 11 16 13
4 rows selected.
jrrt@orcl> set wild on
wildsql - was: False
now: True
jrrt@orcl> select *i* from party;
INT WIS
--- ---
14 16
12 10
15 14
9 14
4 rows selected.
You can also call columns out by number...jrrt@orcl> select #1, #5 from party;
NAME DEX
------- ---
Frodo 15
Gimli 11
Legolas 18
Sam 11
4 rows selected.
... or use ! as NOT.jrrt@orcl> select !str from party;
NAME INT WIS DEX CON CHA
------- --- --- --- --- ---
Frodo 14 16 15 14 16
Gimli 12 10 11 17 11
Legolas 15 14 18 15 17
Sam 9 14 11 16 13
4 rows selected.
... and you can mix it all together.jrrt@orcl> select n*, !#3, !c* from party;
NAME STR WIS DEX
------- --- --- ---
Frodo 8 16 15
Gimli 17 10 11
Legolas 13 14 18
Sam 11 14 11
4 rows selected.
A bunch of limitations:- Wild SQL is not yet a widely-accepted industry standard. Actually, I just made it up. If ANSI hears about it, they will hunt me down with dogs. That's why you need to SET WILDSQL ON to turn it on.
- Wild SQL only works on the column list - the part between the SELECT and the FROM. It doesn't work in the WHERE clause, or in subqueries.
- Wild SQL only works in SELECT statements. What, you were thinking about using it in DML? Are you crazy?
- Do I really have to say that it's very alpha? Well, it is. Expect a trickle of bugfixes over the next few months.
Wednesday, February 25, 2009
sqlpython 1.5.3, with version control
There are several barriers to use of version control tools for Oracle DDL (Data Definition Language: table structures, etc.)
The new sqlpython commands svn, bzr, and hg all do the following:
For example,
- Tools from Oracle, Quest, etc. may have VC capabilities, but you never know whether you'll have the tool available in any particular situation, and you never know when the workings of the tools will change beyond recognition. (I'm looking at you, Oracle.)
- The tools are separate from the mainstream of version control in software development - you're learning quirky specialty tools instead of widely-known industry standards.
- They lack some of the modern capabilities of distributed version control.
We're better off using standard software development VC.
But, of course, those tools are meant for text files, so there needs to be a handy way to get this stuff from DDL inside the database to version-controlled text files.It's easy with sqlpython 1.5.3
The new sqlpython commands svn, bzr, and hg all do the following:
- Create or update a directory tree, beginning at your current working directory, containing text files with the DDL for all the objects in your schema
- Put these files under version control and commit
For example,
testschema@orcl> !pwd
/home/catherine/oracle_vc
testschema@orcl> ls
NAME
--------------
INDEX/XPK_PLAY
TABLE/PLAY
2 rows selected.
testschema@orcl> bzr
added testschema
added testschema/index
added testschema/index/xpk_play.sql
added testschema/table
added testschema/table/play.sql
Committing to: /home/catherine/oracle_vc/
added testschema
added testschema/index
added testschema/table
added testschema/index/xpk_play.sql
added testschema/table/play.sql
Committed revision 1.
testschema@orcl> alter table play add (opening_night DATE);
Executed
testschema@orcl> bzr
bzr: ERROR: Already a branch: ".".
Committing to: /home/catherine/oracle_vc/
modified testschema/table/play.sql
Committed revision 2.
testschema@orcl> alter table play add (performances NUMBER(5,0));
Executed
testschema@orcl> create index xif1_play on play (opening_night);
Executed
testschema@orcl> bzr index/
bzr: ERROR: Already a branch: ".".
added testschema/index/xif1_play.sql
Committing to: /home/catherine/oracle_vc/
added testschema/index/xif1_play.sql
Committed revision 3.
Friday, February 20, 2009
"Writing about Python" at PyCon
PyCon early-bird registration deadline is TOMORROW (Saturday)! No time to lose - go register!
Most Open Spaces are not scheduled until the very day they are held, and that's good. Some are done with some advance planning, though, and that's good too. Doug Hellman is already preparing a "Writing about Python" open-space session at PyCon; I'm eager to take part.
If you're not familiar with conferences like PyCon, you may not realize that the formal schedule, goodie-packed though it is, is not the whole story by a long shot. People use the Open Spaces for a huge variety of things; last year, for instance, I got a lot out of a group organizers' freeform open space discussion, and even more out of the now-famous "Teach Me Twisted" session. If you think the published schedule leaves you in fits of indecision, wait until you see the Open Space board. There's a sort of joyful despair in seeing that you would need three months of PyCon to take part in all the PyCon you want.
Most Open Spaces are not scheduled until the very day they are held, and that's good. Some are done with some advance planning, though, and that's good too. Doug Hellman is already preparing a "Writing about Python" open-space session at PyCon; I'm eager to take part.
If you're not familiar with conferences like PyCon, you may not realize that the formal schedule, goodie-packed though it is, is not the whole story by a long shot. People use the Open Spaces for a huge variety of things; last year, for instance, I got a lot out of a group organizers' freeform open space discussion, and even more out of the now-famous "Teach Me Twisted" session. If you think the published schedule leaves you in fits of indecision, wait until you see the Open Space board. There's a sort of joyful despair in seeing that you would need three months of PyCon to take part in all the PyCon you want.
Tuesday, February 17, 2009
Open Source wrecked the economy
Well, not really, but it did get your attention.
This is a really interesting New York Times article about VaR ("Value at Risk"), a mathematical tool. Over-reliance on this tool was arguably the reason the world's financial experts and geniuses spent the last several years acting like morons. This paragraph jumped out at me.
OK, so it's not really a feather in Open Source's cap, seeing as the economy did end up wrecking over it 'n all, but it does demonstrate the power of openness to popularize a tool. Open-sourcing a tool can make it very popular, but it's up to us not to make a tool into a god.
(Of course, when it's applied outside the software world, we really ought to point out that the principle never came from software at all. It's simply openness, the same ancient innovation that happened in the move from alchemists guarding their secrets to scientists publishing their work.)
This is a really interesting New York Times article about VaR ("Value at Risk"), a mathematical tool. Over-reliance on this tool was arguably the reason the world's financial experts and geniuses spent the last several years acting like morons. This paragraph jumped out at me.
What caused VaR to catapult above the risk systems being developed by JPMorgan competitors was what the firm did next: it gave VaR away. In 1993, Guldimann made risk the theme of the firm’s annual client conference. Many of the clients were so impressed with the JPMorgan approach that they asked if they could purchase the underlying system. JPMorgan decided it didn’t want to get into that business, but proceeded instead to form a small group, RiskMetrics, that would teach the concept to anyone who wanted to learn it, while also posting it on the Internet so that other risk experts could make suggestions to improve it. As Guldimann wrote years later, “Many wondered what the bank was trying to accomplish by giving away ‘proprietary’ methodologies and lots of data, but not selling any products or services.” He continued, “It popularized a methodology and made it a market standard, and it enhanced the image of JPMorgan.”I thought this was a fascinating summary of open-source advantages: prestige, benefiting from community-contributed enhancements, creating a standard, all without the effort and expense of attempting to market a proprietary technology.
OK, so it's not really a feather in Open Source's cap, seeing as the economy did end up wrecking over it 'n all, but it does demonstrate the power of openness to popularize a tool. Open-sourcing a tool can make it very popular, but it's up to us not to make a tool into a god.
(Of course, when it's applied outside the software world, we really ought to point out that the principle never came from software at all. It's simply openness, the same ancient innovation that happened in the move from alchemists guarding their secrets to scientists publishing their work.)
Monday, February 09, 2009
Sunday, February 01, 2009
PyCon talks
You want an awesome badge like this for your blog, right? You can choose from a variety of badges at the publicizing PyCon site. PyCon depends on the user community (that's you) to spread the word. Bringing in a bigger and broader community is how PyCon keeps getting more exciting.
Anyway, even if you are certain you can't attend PyCon, it's worth it to browse the list of accepted PyCon talks - it's a great window into some of the exciting things going on in Python-land. It's already helped me learn about several useful packages and ideas.
Hope to see you in Chicago!
Friday, January 30, 2009
blogging about business, for once
Today my employer benefited through me, but almost despite me.
We're facing an exhausting slog through yet another incarnation of the Air Force's process for getting permission to continue to operate an IT system. My (Air Force) boss had heard somehow that Mark, one of my fellow employees at Intellitech, was shepherding some projects through this process, and asked if he'd be willing to give some advice. Mark came and spent a couple hours giving some desperately needed information, despite being warned that my boss has no prospects of funding to take on additional contracting help.
Everyone there was enormously grateful, because living, breathing survivors of the process are almost unheard of, and the available training material is of very little use. What's more, my boss had made a last-minute impromptu invitation to a friend whose project is also facing the process; she was just as happy to attend, and just might have the funding for some help. And everybody there is going to spread the word that they now know a source of much-needed information on this process.
The problem? I was passive. I hadn't thought to suggest to my boss to tap Mark's experience; good thing he knew about it and thought to ask. I hadn't thought to suggest inviting others to the meeting, either; again, credit to my boss. I really need to be more alert to this sort of thing.
The other problem? If Intellitech does end up with more work thanks to today, it's the kind of hellishly bureaucratic work that makes you want to chew your leg off to escape. Great for the company bottom line, but a blasphemous waste of a living human soul.
We're facing an exhausting slog through yet another incarnation of the Air Force's process for getting permission to continue to operate an IT system. My (Air Force) boss had heard somehow that Mark, one of my fellow employees at Intellitech, was shepherding some projects through this process, and asked if he'd be willing to give some advice. Mark came and spent a couple hours giving some desperately needed information, despite being warned that my boss has no prospects of funding to take on additional contracting help.
Everyone there was enormously grateful, because living, breathing survivors of the process are almost unheard of, and the available training material is of very little use. What's more, my boss had made a last-minute impromptu invitation to a friend whose project is also facing the process; she was just as happy to attend, and just might have the funding for some help. And everybody there is going to spread the word that they now know a source of much-needed information on this process.
The problem? I was passive. I hadn't thought to suggest to my boss to tap Mark's experience; good thing he knew about it and thought to ask. I hadn't thought to suggest inviting others to the meeting, either; again, credit to my boss. I really need to be more alert to this sort of thing.
The other problem? If Intellitech does end up with more work thanks to today, it's the kind of hellishly bureaucratic work that makes you want to chew your leg off to escape. Great for the company bottom line, but a blasphemous waste of a living human soul.
Tuesday, January 27, 2009
complexity
Fire up a program like Eclipse or Visual Studio and start a new project. Blam! It creates a dense forest of code files, text files, configuration files, XML files, directories, subdirectories, assistant directories, deputy directories, acting deputy subdirectories, and special liason to the ad-hoc subcommittee directories.
Java and C# people seem to think this is great. "Look at all this work the tool does for you!"
I disagree. "What IS all this stuff?" I wail. "What's it for? What's it doing? My program is already hopelessly complex and I haven't even started writing it yet! Guido, take me away!" A tutorial may tell me to start on one file and ignore everything else, but that's completely unsatisfying psychologically. I feel like I'm learning nothing because I'm at the mercy of so much auto-generated stuff I can't even hope to understand.
This, I think, is my biggest barrier to learning the "enterprisey" languages.
I admit, starting a project in TurboGears or Django does something kind of similar, and I tolerate it there. I think that's because I know Python well and can handle a limited amount of temporary mystery. It's when I'm trying to dip into a brand-new language and a brand-new environment that I want a small, digestible bite of mystery to get my mind around.
[ADDENDUM]
I'm beginning to think that what might get me over this hurdle is a C# tutorial that specifically avoids Visual Studio and similar IDEs... that gives projects and examples in old-fashioned code files in a text editor - and as few files as possible - even if that seems crazy to VS junkies, if it means the examples are a lot more painstaking and a lot less impressive. But that's what I need - I need to feel like the code I'm writing really encompasses the problem, isn't just a little flourish atop a vast understructure that I didn't write and don't understand. Then, after a while of that, I can start dipping into the IDEs and perhaps appreciate the code generation, rather than dreading it.
Any pointers to a C# tutorial along those lines would be most welcome.
Java and C# people seem to think this is great. "Look at all this work the tool does for you!"
I disagree. "What IS all this stuff?" I wail. "What's it for? What's it doing? My program is already hopelessly complex and I haven't even started writing it yet! Guido, take me away!" A tutorial may tell me to start on one file and ignore everything else, but that's completely unsatisfying psychologically. I feel like I'm learning nothing because I'm at the mercy of so much auto-generated stuff I can't even hope to understand.
This, I think, is my biggest barrier to learning the "enterprisey" languages.
I admit, starting a project in TurboGears or Django does something kind of similar, and I tolerate it there. I think that's because I know Python well and can handle a limited amount of temporary mystery. It's when I'm trying to dip into a brand-new language and a brand-new environment that I want a small, digestible bite of mystery to get my mind around.
[ADDENDUM]
I'm beginning to think that what might get me over this hurdle is a C# tutorial that specifically avoids Visual Studio and similar IDEs... that gives projects and examples in old-fashioned code files in a text editor - and as few files as possible - even if that seems crazy to VS junkies, if it means the examples are a lot more painstaking and a lot less impressive. But that's what I need - I need to feel like the code I'm writing really encompasses the problem, isn't just a little flourish atop a vast understructure that I didn't write and don't understand. Then, after a while of that, I can start dipping into the IDEs and perhaps appreciate the code generation, rather than dreading it.
Any pointers to a C# tutorial along those lines would be most welcome.
Friday, January 23, 2009
Reinteract
Shortly after semi-finishing pyparsing_helper, I realized that it's really not needed, because there's a tool called Reinteract that can fill the same role, plus much more.
Reinteract is a graphical Python session that lets you tinker with your code at any point and get an immediate recalculation. That's what pyparsing_helper does, too, but pyparsing_helper is specialized for pyparsing use, whereas reinteract is suitable for any Python. Here's reinteract applied to a pyparsing example.

Reinteract is also more sophisticated and versatile, so I'm afraid pyparsing_helper's short time in the sun has been eclipsed. I'm happy to have found this new tool, though!
Reinteract is a graphical Python session that lets you tinker with your code at any point and get an immediate recalculation. That's what pyparsing_helper does, too, but pyparsing_helper is specialized for pyparsing use, whereas reinteract is suitable for any Python. Here's reinteract applied to a pyparsing example.

Reinteract is also more sophisticated and versatile, so I'm afraid pyparsing_helper's short time in the sun has been eclipsed. I'm happy to have found this new tool, though!
Monday, January 19, 2009
New Year's Resolution (blogging while angry)
From now on, before spending any significant money on anything, I will test their customer service phone number. If I cannot get to a human being who is reasonably helpful, I will not become a customer.
Understand, I'm all for saving money by automating customer service where possible. But many companies (AT&T Wireless, for example) now make ad hoc, human-interaction support literally unavailable. A demonstrated intent to avoid customer contact is a sign of a bad business partner, and I will not support such bad business practices anymore. (steam, steam, steam)
Understand, I'm all for saving money by automating customer service where possible. But many companies (AT&T Wireless, for example) now make ad hoc, human-interaction support literally unavailable. A demonstrated intent to avoid customer contact is a sign of a bad business partner, and I will not support such bad business practices anymore. (steam, steam, steam)
Friday, January 16, 2009
coworking for the rest of us
Ah, so many ways to learn from each other.
And yet, there's a new one: hanging out and geeking out with other geeks. Programming with, or around, people who aren't your usual co-workers. Like sprinting, sort of, but on no predefined topic. Questions, advice, and ideas bubbling around unpredictably while you code.
That's basically what the CodeJam at CodeMash was, and I loved it. Even if you already work every day with a wealth of fiercely creative, inquisitive, knowledgable co-workers who are delighted to pitch ideas into your project - and not all of us do - it's still a benefit to mix it up with some new minds.
That happened just a week ago, yet suddenly, I'm seeing it everywhere. In Cincinnati, they're doing an evening called "bitslingers". In Ann Arbor, they're doing a daylong Code Retreat.
Solo from-home workers developed this a while ago; they call it "coworking". Now we cubicle monkeys are getting some chances at it, too. I'd love to see this carried to its logical extreme - a custom of getting out to work in new places with new people, say, one day a week. I think the payoff would be enormous.
- Formal conferences and meetings. "Eyes-front" presentations.
- Getting together with the geeks for chat.
- Unconferences and open spaces. Lots of potential for multi-directional learning, yet shaped around specific topics.
- Sprinting: gathering to code together with people outside your usual circle on specific projects. GiveCamps.
And yet, there's a new one: hanging out and geeking out with other geeks. Programming with, or around, people who aren't your usual co-workers. Like sprinting, sort of, but on no predefined topic. Questions, advice, and ideas bubbling around unpredictably while you code.
That's basically what the CodeJam at CodeMash was, and I loved it. Even if you already work every day with a wealth of fiercely creative, inquisitive, knowledgable co-workers who are delighted to pitch ideas into your project - and not all of us do - it's still a benefit to mix it up with some new minds.
That happened just a week ago, yet suddenly, I'm seeing it everywhere. In Cincinnati, they're doing an evening called "bitslingers". In Ann Arbor, they're doing a daylong Code Retreat.
Solo from-home workers developed this a while ago; they call it "coworking". Now we cubicle monkeys are getting some chances at it, too. I'd love to see this carried to its logical extreme - a custom of getting out to work in new places with new people, say, one day a week. I think the payoff would be enormous.
Sunday, January 11, 2009
pyparsing_helper
I'm back from CodeMash!
I got a lot of great ideas, and I especially liked Wednesday's CodeJam, where I started building pyparsing_helper. Hacking on code while surrounded by sharp people to absorb energy and advice from is a great way to get things done! I finished it on the way home, so pyparsing_helper is officially a child of CodeMash!

This is what I had in mind when imagining "Kodos for pyparsing" last week.
One big bad fly in my ointment: pasting into pyparsing_helper isn't working. I don't know why. That's top priority for fixing for v0.1.1; I wonder if I'll have to switch out of Tk to get it to work.
[EDIT:] Paste does work under Windows, and it looks like it's an inherent Tkinter flaw... what's up with that? Tkinter's only been around for, oh, 15 years or so - and this core function is still unfixed? Maybe that's why all the cool kids quit using it years ago.
[EDIT #2:] OK, paste did work in *nix, but only in its Shift-Insert variety. pyparsing_helper 0.1.1 (available now) makes the more familiar Ctrl-V pasting available, too.
I got a lot of great ideas, and I especially liked Wednesday's CodeJam, where I started building pyparsing_helper. Hacking on code while surrounded by sharp people to absorb energy and advice from is a great way to get things done! I finished it on the way home, so pyparsing_helper is officially a child of CodeMash!

This is what I had in mind when imagining "Kodos for pyparsing" last week.
One big bad fly in my ointment: pasting into pyparsing_helper isn't working. I don't know why. That's top priority for fixing for v0.1.1; I wonder if I'll have to switch out of Tk to get it to work.
easy_install pyparsing_helper[EDIT:] Paste does work under Windows, and it looks like it's an inherent Tkinter flaw... what's up with that? Tkinter's only been around for, oh, 15 years or so - and this core function is still unfixed? Maybe that's why all the cool kids quit using it years ago.
[EDIT #2:] OK, paste did work in *nix, but only in its Shift-Insert variety. pyparsing_helper 0.1.1 (available now) makes the more familiar Ctrl-V pasting available, too.
Subscribe to:
Posts (Atom)