Thursday, October 28, 2010

Who's playing catch up now?

At one time if I remembered correctly, ruby came up with their gems framework first. I tried it out and really liked it as I got to try out various gems without having to worry if my platform had packages for it or not. At that point the poor Python was left in the dust at the other side of the room without anything remote resembling gems or cshell (Perl).

Fast forward a couple of years and now easy_install and virtualenv and these two great apps are so wide spread. I used them so much and got used to using and depending on them that when I found myself returning to gem to try out watir, a framework for web testing, I found gem to be clunky and unwieldy. Kudos to the Python camp! In such a short time you have left gems shaking it's head disbelief in the dust! Who said snakes can't be fast.

For those who are interested, I had problems installing the gem for watir and encountered all sorts of errors and upon searching for the download point for watir to download it by hand, let's just say I missed PyPi a lot.

4 comments:

Charley Baker said...

Would be curious to hear more details around the problems installing Watir, so we can fix it. I used to be a perl dev years and years ago, but I'm not familiar with Python's packaging system, so I can't speak to that.

Rubygems have held up well with multiple improvements over the years. There are some glitches as well, which I'm more than happy to hear about.

Cheers,
Charley

lowks said...

Well here it is ..

[root@lowkster-arch bin]# gem install watir
Building native extensions. This could take a while...
ERROR: Error installing watir:
ERROR: Failed to build gem native extension.

/usr/bin/ruby extconf.rb
checking for strncpy_s()... no
creating Makefile

make
gcc -I. -I/usr/include/ruby-1.9.1/x86_64-linux -I/usr/include/ruby-1.9.1/ruby/backward -I/usr/include/ruby-1.9.1 -Iwin32 -fPIC -march=x86-64 -mtune=generic -O2 -pipe -fPIC -o api.o -c win32/api.c
win32/api.c:2:21: fatal error: windows.h: No such file or directory
compilation terminated.
make: *** [api.o] Error 1


Gem files will remain installed in /usr/lib/ruby/gems/1.9.1/gems/win32-api-1.4.6 for inspection.
Results logged to /usr/lib/ruby/gems/1.9.1/gems/win32-api-1.4.6/ext/gem_make.out

I found through google this has got something to do with the version of ruby being 1.9. The thing is I would be hard pressed to find a distribution that is not moving to 1.9 now ... on opensuse it as win api error.

Chai said...

Cool. A python developer in Kuantan. Is there any community there? I'll drop in next time I am home (I go back once a year).

EWT said...

You need to install watir-webdriver on linux. I got that error as well until I realized it was the wrong gem.