Ruby 1.8.1 preview1

It’s out.

ftp://ftp.ruby-lang.org/pub/ruby/1.8/ruby-1.8.1-preview1.tar.gz

md5sum is c739d26356b8e3a1fa6409a6bcdcef68.

						matz.

I just tried to build it with VC6 and got the following error:

    cl -nologo -MD -Zi -O2b2xg- -G6 -I. 

-IC:/OpenSource/ruby-1.8.1/win32 -IC:/OpenSource/ruby-1.
8.1 -IC:/OpenSource/ruby-1.8.1/ext/syck -DHAVE_ST_H -I. -I./…
-I./…/missing -c -TcC:/OpenSource/ru
by-1.8.1/ext/syck/yaml2byte.c
yaml2byte.c
C:/OpenSource/ruby-1.8.1/ext/syck/yaml2byte.c(15) : fatal error C1083:
Cannot open include file: ‘ya
mlbyte.h’: No such file or directory
NMAKE : fatal error U1077: ‘cl’ : return code ‘0x2’
Stop.
NMAKE : fatal error U1077: ‘.\miniruby.exe’ : return code ‘0x1’
Stop.

Sure enought, there is no yamlbyte.h anywhere in the source tree.

···

On 10/30/2003 4:41 AM, Yukihiro Matsumoto wrote:

It’s out.

ftp://ftp.ruby-lang.org/pub/ruby/1.8/ruby-1.8.1-preview1.tar.gz

md5sum is c739d26356b8e3a1fa6409a6bcdcef68.

  					matz.


Dean saor, dean saor an spiorad. Is seinn d’orain beo.

Mirrored here:

http://rubyforge.org/project/showfiles.php?group_id=30&release_id=149

Yours,

Tom

···

On Thu, 2003-10-30 at 04:41, Yukihiro Matsumoto wrote:

It’s out.

ftp://ftp.ruby-lang.org/pub/ruby/1.8/ruby-1.8.1-preview1.tar.gz

md5sum is c739d26356b8e3a1fa6409a6bcdcef68.

  					matz.

As Dave doesn’t have a -users list for Rublog I am asking here, sorry
if it is offtopic…

I am having a bear of a time getting rublog to work under 1.8.0 I get
errors along the lines of:

[Thu Oct 30 08:31:47 2003] [error] [client 209.137.167.162] Premature
end of script headers: rublog.cgi, referer:
http://kasparov.skife.org/rublog-0.8.0/rublog.cgi
[Thu Oct 30 08:31:47 2003] [error] [client 209.137.167.162]
./Request.rb:150:in slice!': can't modify frozen string (TypeError), referer: http://kasparov.skife.org/rublog-0.8.0/rublog.cgi [Thu Oct 30 08:31:47 2003] [error] [client 209.137.167.162] from ./Request.rb:150:indetermine_request_path’, referer:
http://kasparov.skife.org/rublog-0.8.0/rublog.cgi
[Thu Oct 30 08:31:47 2003] [error] [client 209.137.167.162] from
./Request.rb:79:in initialize', referer: http://kasparov.skife.org/rublog-0.8.0/rublog.cgi [Thu Oct 30 08:31:47 2003] [error] [client 209.137.167.162] from ./Request.rb:254:ininitialize’, referer:
http://kasparov.skife.org/rublog-0.8.0/rublog.cgi
[Thu Oct 30 08:31:47 2003] [error] [client 209.137.167.162] from
/home/mccallister/www/rublog-0.8.0/rublog.cgi:33:in `new’, referer:
http://kasparov.skife.org/rublog-0.8.0/rublog.cgi
[Thu Oct 30 08:31:47 2003] [error] [client 209.137.167.162] from
/home/mccallister/www/rublog-0.8.0/rublog.cgi:33, referer:
http://kasparov.skife.org/rublog-0.8.0/rublog.cgi

when I make a request against a category.

I have gone in and hacked up the obvious places but it just opens a can
of worms on new problems.

Anyone played with this and gotten it to work?

Thanks in advance to anyone who can help provide some pointers!

-Brian

Here is the result of an attempt to build Ruby with MinGW:

make[1]: Entering directory /home/gour/ruby-1.8.1/ext/syck' gcc -g -O2 -I. -IC:/MSYS/1.0/home/gour/ruby-1.8.1 -IC:/MSYS/1.0/home/gour/ruby-1.8.1 -IC:/MSYS/1.0/home/gour/ruby-1.8.1/ext/syck -DHAVE_ST_H -c rubyext.c gcc -g -O2 -I. -IC:/MSYS/1.0/home/gour/ruby-1.8.1 -IC:/MSYS/1.0/home/gour/ruby-1.8.1 -IC:/MSYS/1.0/home/gour/ruby-1.8.1/ext/syck -DHAVE_ST_H -c yaml2byte.c yaml2byte.c:15:22: yamlbyte.h: No such file or directory yaml2byte.c: In function bytestring_extend’:
yaml2byte.c:92: YAMLBYTE_ANCHOR' undeclared (first use in this function) yaml2byte.c:92: (Each undeclared identifier is reported only once yaml2byte.c:92: for each function it appears in.) yaml2byte.c:96: YAMLBYTE_ALIAS’ undeclared (first use in this function)
yaml2byte.c: In function syck_yaml2byte_handler': yaml2byte.c:134: YAMLBYTE_ANCHOR’ undeclared (first use in this function)
yaml2byte.c:139: YAMLBYTE_TRANSFER' undeclared (first use in this function) yaml2byte.c:153: YAMLBYTE_SCALAR’ undeclared (first use in this function)
yaml2byte.c:163: YAMLBYTE_CONTINUE' undeclared (first use in this function) yaml2byte.c:172: YAMLBYTE_NEWLINE’ undeclared (first use in this function)
yaml2byte.c:176: YAMLBYTE_NULLCHAR' undeclared (first use in this function) yaml2byte.c:187: YAMLBYTE_SEQUENCE’ undeclared (first use in this function)
yaml2byte.c:194: YAMLBYTE_END_BRANCH' undeclared (first use in this function) yaml2byte.c:197: YAMLBYTE_MAPPING’ undeclared (first use in this function)
make[1]: *** [yaml2byte.o] Error 1
make[1]: Leaving directory `/home/gour/ruby-1.8.1/ext/syck’
make: *** [all] Error 1

Sincerely,
Gour

···

Joey Gibson (joey@joeygibson.com) wrote:

I just tried to build it with VC6 and got the following error:


Gour
gour@mail.inet.hr
Registered Linux User #278493

Might be worth posting to the project’s forums:

http://rubyforge.org/forum/?group_id=74

Although I admit that probably a posting here is more likely to be seen
by other rublog users…

Yours,

Tom

···

On Thu, 2003-10-30 at 11:36, Brian McCallister wrote:

As Dave doesn’t have a -users list for Rublog I am asking here, sorry
if it is offtopic…

Hmm… I’m running it every day under 1.8.0 and 1.8.1.

Are you running it as a CGI, or under mod_ruby?

Cheers

Dave

···

On Oct 30, 2003, at 10:36, Brian McCallister wrote:

As Dave doesn’t have a -users list for Rublog I am asking here, sorry
if it is offtopic…

I am having a bear of a time getting rublog to work under 1.8.0 I get
errors along the lines of:

As Dave doesn’t have a -users list for Rublog I am asking here, sorry

if it is offtopic…

···

On Fri, 31 Oct 2003, Brian McCallister wrote:

I am having a bear of a time getting rublog to work under 1.8.0 I get

errors along the lines of:

No problems here under 1.8.0. Have you tried it with Webrick? I’d be
interested to know if it works there. What’s your web server config?
mod_ruby?

Chad

I have mod_ruby installed but am running it under cgi at the moment –
I want to run under mod_ruby eventually, but make it work, then work
right, then work fast =)

Completely disabling mod_ruby makes no change

Forcing it to run under mod_ruby gives me a security error:

./FileEntries.rb:85:in stat': Insecure operation - stat (SecurityError) from ./FileEntries.rb:85:in traverse’
from ./FileEntries.rb:84:in each' from ./FileEntries.rb:84:in traverse’
from ./FileEntries.rb:52:in initialize' from ./RubLog.rb:81:in new’
from ./RubLog.rb:81:in process_request' from ./RubLog.rb:66:in initialize’
from /home/mccallister/www/rublog-0.8.0/rublog.rb:33:in new' from /home/mccallister/www/rublog-0.8.0/rublog.rb:33 from /usr/local/lib/ruby/1.8/apache/ruby-run.rb:70:in load’
from /usr/local/lib/ruby/1.8/apache/ruby-run.rb:70:in `handler’

Running it as a normal cgi I get the previously mentioned error. The
“can’t modify frozen string (TypeError)” is why I thought that maybe
something changed between 1.6 and 1.8.

httpd cgi config is pretty vanilla:

LoadModule cgi_module modules/mod_cgi.so
AddHandler cgi-script .cgi

Aside from that it is httpd 2.0.48 prefork and 1.8.0 release with
nothing extra aside from eruby installed.

-Brian

···

On Thursday, October 30, 2003, at 12:00 PM, Chad Fowler wrote:

On Fri, 31 Oct 2003, Brian McCallister wrote:

As Dave doesn’t have a -users list for Rublog I am asking here, sorry

if it is offtopic…

I am having a bear of a time getting rublog to work under 1.8.0 I get

errors along the lines of:

No problems here under 1.8.0. Have you tried it with Webrick? I’d be
interested to know if it works there. What’s your web server config?
mod_ruby?

Chad

Entertainingly enough, the frozen string was it, the following patch
solved the problem:

— Request.rb Thu Mar 20 21:45:28 2003
+++ …/…/rublog-0.8.0/Request.rb Thu Oct 30 10:45:46 2003
@@ -147,8 +147,9 @@
request_path = “”
path = @environment[‘PATH_INFO’]
if path && path !~ /../

  •  path.slice!(0) if path[0] == ?/
    
  •  request_path = path unless path.empty?
    
  •  foo = String.new(path)
    
  •  foo.slice!(0) if foo[0] == ?/
    
  •  request_path = foo unless path.empty?
    end
    
    @is_rss = request_path.sub!(/index.rss$/, '') || 
    

@parameters.has_key?(‘rss’)

Now, to figure out how to unfreeze said String.

-Brian

···

On Thursday, October 30, 2003, at 01:29 PM, Brian McCallister wrote:

I have mod_ruby installed but am running it under cgi at the moment –
I want to run under mod_ruby eventually, but make it work, then work
right, then work fast =)

Completely disabling mod_ruby makes no change

Forcing it to run under mod_ruby gives me a security error:

./FileEntries.rb:85:in stat': Insecure operation - stat (SecurityError) from ./FileEntries.rb:85:in traverse’
from ./FileEntries.rb:84:in each' from ./FileEntries.rb:84:in traverse’
from ./FileEntries.rb:52:in initialize' from ./RubLog.rb:81:in new’
from ./RubLog.rb:81:in process_request' from ./RubLog.rb:66:in initialize’
from /home/mccallister/www/rublog-0.8.0/rublog.rb:33:in new' from /home/mccallister/www/rublog-0.8.0/rublog.rb:33 from /usr/local/lib/ruby/1.8/apache/ruby-run.rb:70:in load’
from /usr/local/lib/ruby/1.8/apache/ruby-run.rb:70:in
`handler’

Running it as a normal cgi I get the previously mentioned error. The
“can’t modify frozen string (TypeError)” is why I thought that maybe
something changed between 1.6 and 1.8.

httpd cgi config is pretty vanilla:

LoadModule cgi_module modules/mod_cgi.so
AddHandler cgi-script .cgi

Aside from that it is httpd 2.0.48 prefork and 1.8.0 release with
nothing extra aside from eruby installed.

-Brian

On Thursday, October 30, 2003, at 12:00 PM, Chad Fowler wrote:

On Fri, 31 Oct 2003, Brian McCallister wrote:

As Dave doesn’t have a -users list for Rublog I am asking here,

sorry

if it is offtopic…

I am having a bear of a time getting rublog to work under 1.8.0 I

get

errors along the lines of:

No problems here under 1.8.0. Have you tried it with Webrick? I’d be
interested to know if it works there. What’s your web server config?
mod_ruby?

Chad

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (Darwin)

iD8DBQE/oViTaOuMdvjqKWcRAtlpAJ44TmxkqGKRESxDe7JSfP64TX80vQCdH+g/
2+bXBrTZof26TZoPLmCm88I=
=psQR
-----END PGP SIGNATURE-----

The full patch:

···

— Request.rb Thu Oct 30 10:54:00 2003
+++ …/foo/rublog-0.8.0/Request.rb Thu Mar 20 21:45:28 2003
@@ -147,9 +147,8 @@
request_path = “”
path = @environment[‘PATH_INFO’]
if path && path !~ /../

  •  foo = String.new(path)
    
  •  foo.slice!(0) if foo[0] == ?/
    
  •  request_path = foo unless path.empty?
    
  •  path.slice!(0) if path[0] == ?/
    
  •  request_path = path unless path.empty?
    end
    
    @is_rss = request_path.sub!(/index.rss$/, '') || 
    

@parameters.has_key?(‘rss’)
@@ -242,7 +241,7 @@
@cgi = cgi
end
def

  •  @cgi.params[key][0]
    
  •  @cgi[key][0]
    end
    def has_key?(key)
      @cgi.has_key?(key)
    

also fixes a recurring error message in the http log:

./Request.rb:245:in `':CAUTION! cgi[‘key’] == cgi.params[‘key’][0];
if want Array, use cgi.params[‘key’], referer:
http://kasparov.skife.org/rublog-0.8.0/rublog.cgi/

-Brian

On Thursday, October 30, 2003, at 01:49 PM, Brian McCallister wrote:

Entertainingly enough, the frozen string was it, the following patch
solved the problem:

— Request.rb Thu Mar 20 21:45:28 2003
+++ …/…/rublog-0.8.0/Request.rb Thu Oct 30 10:45:46 2003
@@ -147,8 +147,9 @@
request_path = “”
path = @environment[‘PATH_INFO’]
if path && path !~ /../

  •  path.slice!(0) if path[0] == ?/
    
  •  request_path = path unless path.empty?
    
  •  foo = String.new(path)
    
  •  foo.slice!(0) if foo[0] == ?/
    
  •  request_path = foo unless path.empty?
    end
    
    @is_rss = request_path.sub!(/index.rss$/, '') ||
    

@parameters.has_key?(‘rss’)

Now, to figure out how to unfreeze said String.

-Brian

On Thursday, October 30, 2003, at 01:29 PM, Brian McCallister wrote:

I have mod_ruby installed but am running it under cgi at the moment –
I want to run under mod_ruby eventually, but make it work, then work
right, then work fast =)

Completely disabling mod_ruby makes no change

Forcing it to run under mod_ruby gives me a security error:

./FileEntries.rb:85:in stat': Insecure operation - stat (SecurityError) from ./FileEntries.rb:85:in traverse’
from ./FileEntries.rb:84:in each' from ./FileEntries.rb:84:in traverse’
from ./FileEntries.rb:52:in initialize' from ./RubLog.rb:81:in new’
from ./RubLog.rb:81:in process_request' from ./RubLog.rb:66:in initialize’
from /home/mccallister/www/rublog-0.8.0/rublog.rb:33:in new' from /home/mccallister/www/rublog-0.8.0/rublog.rb:33 from /usr/local/lib/ruby/1.8/apache/ruby-run.rb:70:in load’
from /usr/local/lib/ruby/1.8/apache/ruby-run.rb:70:in
`handler’

Running it as a normal cgi I get the previously mentioned error. The
“can’t modify frozen string (TypeError)” is why I thought that maybe
something changed between 1.6 and 1.8.

httpd cgi config is pretty vanilla:

LoadModule cgi_module modules/mod_cgi.so
AddHandler cgi-script .cgi

Aside from that it is httpd 2.0.48 prefork and 1.8.0 release with
nothing extra aside from eruby installed.

-Brian

On Thursday, October 30, 2003, at 12:00 PM, Chad Fowler wrote:

On Fri, 31 Oct 2003, Brian McCallister wrote:

As Dave doesn’t have a -users list for Rublog I am asking here,

sorry

if it is offtopic…

I am having a bear of a time getting rublog to work under 1.8.0 I

get

errors along the lines of:

No problems here under 1.8.0. Have you tried it with Webrick? I’d
be
interested to know if it works there. What’s your web server config?
mod_ruby?

Chad

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (Darwin)

iD8DBQE/oViTaOuMdvjqKWcRAtlpAJ44TmxkqGKRESxDe7JSfP64TX80vQCdH+g/
2+bXBrTZof26TZoPLmCm88I=
=psQR
-----END PGP SIGNATURE-----

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (Darwin)

iD8DBQE/oV0haOuMdvjqKWcRAmmSAJ9p6LKRdFK/yg3MpyBgcLA1d3XFcQCghedJ
6m1MEq6wMBjw5VcrCkmPElI=
=SDqR
-----END PGP SIGNATURE-----