shedskin 0.9.2

161 views
Skip to first unread message

Mark Dufour

unread,
May 1, 2012, 6:44:44 PM5/1/12
to shedskin-discuss
hi all,

I'm thinking about releasing shedskin 0.9.2 in about a week or so.
there have been quite a few minor fixes and optimizations since 0.9.1,
and there's also a nice new example program:

http://code.google.com/p/shedskin/wiki/releasenotes

I'd really like to add another nice example program before the
release, but so far I haven't found anything suitable. please inform
me if you know of any potential examples or would like to help search.

I'd especially like to add near-optimal rubik solver in pure python,
but the only python solver that I have found so far needs lots of
moves, and mixes lots of types so it would require a large rewrite to
make it compile.. (http://pastebin.com/KwGMujyB)..

thanks,
mark.
--
http://www.youtube.com/watch?v=E6LsfnBmdnk

srepmub

unread,
May 3, 2012, 4:34:22 PM5/3/12
to shedskin-discuss
I ended up rewriting the rubik solver anyway, so now there's a new
1000-line example.. :-)

perhaps I may also have a go at implementing the kociemba algorithm in
python before the release, which can often find solutions in 20 moves
or less, but we'll see.

mark.

srepmub

unread,
May 6, 2012, 1:44:36 PM5/6/12
to shedskin-discuss
hi all,

I have just uploaded the files for 0.9.2.. :-)

http://code.google.com/p/shedskin/wiki/releasenotes

please try them out and let me know about any problems before I
announce the release more widely.

as for my attempt at a better rubik solver to the example programs..
kociemba's algorithm ended up being too complex, so I translated a C++
version of the thistlethwaite algorithm by stephan pochmann and added
it to the example programs, so there are now 3 new examples for this
release..

at only 78 lines (sloccount) the new example program is able to solve
a randomly scrambled cube in around 30 moves, taking about 2 minutes
here after compilation. I left out one optimization for readability
(two-directional search), otherwise solving would probably be a matter
of seconds.

thanks!
mark.

Thomas Spura

unread,
May 6, 2012, 3:46:03 PM5/6/12
to shedskin...@googlegroups.com
Hi Mark,

On Sun, May 6, 2012 at 7:44 PM, srepmub <mark....@gmail.com> wrote:
> hi all,
>
> I have just uploaded the files for 0.9.2.. :-)
>
> http://code.google.com/p/shedskin/wiki/releasenotes
>
> please try them out and let me know about any problems before I
> announce the release more widely.

Which gcc are you using/is it currently tested?

With current master (f9d0004a1) it fails with this:

$ ./run.py -f
*** test: 0
*** SHED SKIN Python-to-C++ Compiler 0.9.2 ***
Copyright 2005-2011 Mark Dufour; License GNU GPL version 3 (See LICENSE)

[analyzing types..]
********************************100%
[generating c++ code..]
[elapsed time: 2.12 seconds]
rm -f 0 0_prof 0_debug
g++ -O2 -march=native -Wno-deprecated -I.
-I/shedskin.git/shedskin/lib 0.cpp /shedskin.git/shedskin/lib/re.cpp
/shedskin.git/shedskin/lib/builtin.cpp -lgc -lpcre -o 0
In file included from /shedskin.git/shedskin/lib/builtin.cpp:140:0:
/shedskin.git/shedskin/lib/builtin/file.cpp: In member function
‘virtual __shedskin__::__ss_bool __shedskin__::file::isatty()’:
/shedskin.git/shedskin/lib/builtin/file.cpp:190:20: error: ‘::isatty’
has not been declared
/shedskin.git/shedskin/lib/builtin/file.cpp: In member function
‘virtual void* __shedskin__::file::truncate(int)’:
/shedskin.git/shedskin/lib/builtin/file.cpp:200:37: error: ‘ftruncate’
was not declared in this scope
make: *** [0] Error 1
*** failure: 0


$ rpm -q gcc gc-devel pcre-devel python
gcc-4.7.0-4.fc17.x86_64
gc-devel-7.2-0.6.alpha6.fc17.x86_64
pcre-devel-8.21-5.fc17.x86_64
python-2.7.3-6.fc17.x86_64


Greetings,
Tom

Mark Dufour

unread,
May 6, 2012, 4:29:07 PM5/6/12
to shedskin...@googlegroups.com
hi thomas,

thanks! ah yes, GCC 4.7.. I've fixed a few issues with it just
yesterday I think, but I couldn't get it installed myself (ubuntu
12.04) so I couldn't fix the isatty problem.. can you figure out the
include magic perhaps..? here are some suggestions to try for isatty:

http://code.google.com/p/shedskin/issues/detail?id=167

(I don't remember why unistd.h is now included in namespace std,
probably to avoid conflicts..)

the ftruncate problem may also just be GCC 4.7 becoming stricter about
including stuff..

thanks! ;-)
mark.
> --
> You received this message because you are subscribed to the Google Groups "shedskin-discuss" group.
> To post to this group, send email to shedskin...@googlegroups.com.
> To unsubscribe from this group, send email to shedskin-discu...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/shedskin-discuss?hl=en.
>



--
http://www.youtube.com/watch?v=E6LsfnBmdnk

Mark Dufour

unread,
May 6, 2012, 4:30:24 PM5/6/12
to shedskin...@googlegroups.com
oh sorry, you asked which GCC versions I test with.. that's 4.6.3
under ubuntu 12.04 and 4.5.something under windows.. I'm sure paul
will use an even older version when trying the debian package.. ;-)

mark.

On Sun, May 6, 2012 at 9:46 PM, Thomas Spura
<thomas...@googlemail.com> wrote:

junyi sun

unread,
May 9, 2012, 10:48:01 PM5/9/12
to shedskin...@googlegroups.com
Hi, Mark

The file  shedskin-0.9.2.exe    sames to be broken. I clicked the install file in windows 2003 (x64), but it failed to extract some of the files in it. Also, there are some error messages said that "files are broken", as the screenshot shows.
sc.PNG

Mark Dufour

unread,
May 10, 2012, 4:07:42 AM5/10/12
to shedskin...@googlegroups.com
hi junyi,

> The file  shedskin-0.9.2.exe    sames to be broken. I clicked the install
> file in windows 2003 (x64), but it failed to extract some of the files in
> it. Also, there are some error messages said that "files are broken", as the
> screenshot shows.

ah, thanks a lot for reporting, I see the problem here too. that
should teach me to check the final archive after uploading, not
before.. :P I will upload a new package tonight, and let you know.

thanks again!
mark.
--
http://www.youtube.com/watch?v=E6LsfnBmdnk

Mark Dufour

unread,
May 10, 2012, 4:49:41 PM5/10/12
to shedskin...@googlegroups.com
hi,

alright, after a few more corrupt uploads using firefox, I managed to
get a good one using chrome.... not sure why firefox also doesn't even
have a progress bar for uploading.

thanks again in any case for reporting!
mark.
Reply all
Reply to author
Forward
0 new messages