Life tag testing

For scripts to aid with computation or simulation in cellular automata.
Locked
User avatar
dvgrn
Moderator
Posts: 12053
Joined: May 17th, 2009, 11:00 pm
Location: Madison, WI
Contact:

Re: Life tag testing

Post by dvgrn »

rowett wrote: November 19th, 2019, 1:21 pm
dvgrn wrote: November 19th, 2019, 1:08 pm See any obvious problems with the first-letter-capitalized Rule: article, plus optional redirects when needed?
No, that seems to work well.
I'll have a few more ExtendedLife-related rules to add tomorrow, and then I might put together a modified RuleTableToTree.py script that generates exactly the .rule file that should go in the Rule: namespace, including @RULE, @TABLE, @TREE sections in that order I guess, and @COLORS and @ICONS sections if they're available. It would start by asking for the location of an @RULE file (instead of the old .table file, which currently isn't allowed to have a @TABLE header).

... Let's see, nobody has done any really surprising [​viewer​] messages to show off this impressive new feature yet. What would be a good advertisement -- maybe just a DoubleB3S23 sample? Or one of the weirder LifeHistory variants, where gliders only leave history trails when they're inside a certain area, or maybe where different gliders leave different color trails.
User avatar
dvgrn
Moderator
Posts: 12053
Joined: May 17th, 2009, 11:00 pm
Location: Madison, WI
Contact:

Re: Life tag testing

Post by dvgrn »

Another couple of questions:

1) Is the @TREE-only processing temporary or permanent? Will LifeViewer eventually get all the code from RuleTableToTree.py ported into it, to parse @TABLEs and make its own @TREEs?

2) Looking at the JvN29 @TREE brought up the interesting fact that some relatively short @TABLEs had the potential to create very large @TREEs, probably especially if "permute" symmetry is used. Might these @TREE sections sometimes get large enough that there really wouldn't be any point in trying to copy the resulting file into the LifeWiki Rule: namespace?

I'm finishing up a RuleTableToTree-hacked.py that builds a .rule containing a @TREE section, starting from a .rule that contains only a @TABLE section, and drops the whole mess into the clipboard for immediate transfer to the LifeWiki. Just thinking about adding a warning message if the result ends up unreasonably large (whatever that might mean).

EDIT: Hmm, the Rule namespace text that I've been putting in LifeWiki so far doesn't actually make Golly happy. LifeViewer can handle both a @TREE and @TABLE section, but Golly is saying, "one or the other, please" -- not very clearly (it just says "not valid in any algorithm"). Should we stop including a @TABLE section in the Rule namespace, so that the rules are usable directly in Golly without editing out one or the other of those sections? It would be nice to have a place on the wiki to store the @TABLE information also, since that often includes explanatory comments that get lost in the @TREE.
User avatar
rowett
Moderator
Posts: 4597
Joined: January 31st, 2013, 2:34 am
Location: UK
Contact:

Re: Life tag testing

Post by rowett »

dvgrn wrote: November 20th, 2019, 7:19 pm 1) Is the @TREE-only processing temporary or permanent?
I'm hoping permanent but if @TABLEs are required then temporary.
dvgrn wrote: November 20th, 2019, 7:19 pm 2) Might these @TREE sections sometimes get large enough that there really wouldn't be any point in trying to copy the resulting file into the LifeWiki Rule: namespace?
Don't know but I guess that's possible. I haven't really used RuleTable rules so I've no experience as to how large they can get.
dvgrn wrote: November 20th, 2019, 7:19 pm Hmm, the Rule namespace text that I've been putting in LifeWiki so far doesn't actually make Golly happy. LifeViewer can handle both a @TREE and @TABLE section, but Golly is saying, "one or the other, please" -- not very clearly (it just says "not valid in any algorithm").
I think Golly does handle both @TREE and @TABLE sections. There are several such rules in Golly's rule folder. Please point me at one that doesn't work in Golly and I'll take a look.
User avatar
rowett
Moderator
Posts: 4597
Joined: January 31st, 2013, 2:34 am
Location: UK
Contact:

Re: Life tag testing

Post by rowett »

Build 457 is now available on the lazyslug server

Enhancements in this build:
  • faster RuleTree performance for von Neumann rules with <= 16 states
User avatar
dvgrn
Moderator
Posts: 12053
Joined: May 17th, 2009, 11:00 pm
Location: Madison, WI
Contact:

Re: Life tag testing

Post by dvgrn »

rowett wrote: November 21st, 2019, 12:24 amI think Golly does handle both @TREE and @TABLE sections. There are several such rules in Golly's rule folder. Please point me at one that doesn't work in Golly and I'll take a look.
Ah, thanks -- false alarm. My RuleTableToTree-hacked.py was putting out a combined @TABLE and @TREE file, but with some of the comments copied to the wrong place. Will repair the script and post it later, in case anyone else wants to LifeViewer-enable other threads on the forums.
User avatar
rowett
Moderator
Posts: 4597
Joined: January 31st, 2013, 2:34 am
Location: UK
Contact:

Re: Life tag testing

Post by rowett »

Build 458 is now available on the lazyslug server

Enhancements in this build:
  • decode Repository response faster
Fixes in this build:
  • use original rule name for Repository request
User avatar
rowett
Moderator
Posts: 4597
Joined: January 31st, 2013, 2:34 am
Location: UK
Contact:

Re: Life tag testing

Post by rowett »

Build 459 is now available on the lazyslug server

Enhancements in this build:
  • tokenizer uses less memory and is significantly faster
  • added size and timing information to Help->Info->Rule Cache
Fixes in this build:
  • fix a grid boundary crash in RuleTree algo
User avatar
dvgrn
Moderator
Posts: 12053
Joined: May 17th, 2009, 11:00 pm
Location: Madison, WI
Contact:

Re: Life tag testing

Post by dvgrn »

Here is an attempt to use a new rule, SlowLife, from the Rule Table Repository, that isn't activating LifeViewer.

I suspect the comments after @TABLE are making LifeViewer unhappy -- I left Andrew's original comments unchanged for now, but I bet if I remove them then LifeViewer will start working. Is it the "@TREE" inside the comments that's the problem, or something about the quoted Python code?


EDIT: Yup, it was the "@TREE" in the comment text. The original version of the rule is below; to get it working I just added a space between @ and TREE.

Code: Select all

@RULE SlowLife

A variant of Life that shows births (green cells) and deaths (red cells)
in every 2nd generation.  SlowLife patterns work the same as in Life,
but twice as slow.  Author: Andrew Trevorrow (andrew@trevorrow.com).

The @TREE data was created by copying the following Python code to the
clipboard and running Golly's make-ruletree.py script.

name = "SlowLife"
n_states = 4
n_neighbors = 8
def transition_function(s):
    # NW, NE, SW, SE, N, W, E, S, C = s
    C = s[8]
    
    # live states:
    normal = 1
    birth = 2
    death = 3
    
    if C == birth: return normal
    if C == death: return 0
    
    # count the number of normal neighbors
    ncount = 0
    for i in xrange(8):
        if s[i] == normal: ncount += 1
        # no change if there are any birth/death neighbors
        if s[i] > normal: return C
    
    if C == 0 and ncount == 3: return birth
    if C == normal and (ncount < 2 or ncount > 3): return death
    
    return C

@TREE

num_states=4
num_neighbors=8
num_nodes=39
1 0 3 1 0
1 0 1 1 0
2 0 0 1 1
2 0 1 1 1
2 1 1 1 1
3 2 3 4 4
1 2 1 1 0
2 1 6 1 1
3 3 7 4 4
3 4 4 4 4
4 5 8 9 9
2 6 0 1 1
3 7 11 4 4
4 8 12 9 9
4 9 9 9 9
5 10 13 14 14
3 11 2 4 4
4 12 16 9 9
5 13 17 14 14
5 14 14 14 14
6 15 18 19 19
3 2 2 4 4
4 16 21 9 9
5 17 22 14 14
6 18 23 19 19
6 19 19 19 19
7 20 24 25 25
4 21 21 9 9
5 22 27 14 14
6 23 28 19 19
7 24 29 25 25
7 25 25 25 25
8 26 30 31 31
5 27 27 14 14
6 28 33 19 19
7 29 34 25 25
8 30 35 31 31
8 31 31 31 31
9 32 36 37 37

@COLORS

0  48  48  48   background is dark gray
1 255 255 255   normal is white
2   0 255   0   birth is green
3 255   0   0   death is red

@ICONS

XPM
/* width height num_colors chars_per_pixel */
"31 93 10 1"
/* colors */
". c #303030"
"B c #404040"
"C c #808080"
"D c #C0C0C0"
"E c #FFFFFF"
"F c #004000"
"G c #007F00"
"H c #00C000"
"I c #00FF00"
"J c #FF0000"
/* icon for state 1 */
"..............................."
"..............................."
"..........BCDEEEEEDCB.........."
".........CEEEEEEEEEEEC........."
".......BEEEEEEEEEEEEEEEB......."
"......DEEEEEEEEEEEEEEEEED......"
".....DEEEEEEEEEEEEEEEEEEED....."
"....BEEEEEEEEEEEEEEEEEEEEEB...."
"....EEEEEEEEEEEEEEEEEEEEEEE...."
"...CEEEEEEEEEEEEEEEEEEEEEEEC..."
"..BEEEEEEEEEEEEEEEEEEEEEEEEEB.."
"..CEEEEEEEEEEEEEEEEEEEEEEEEEC.."
"..DEEEEEEEEEEEEEEEEEEEEEEEEED.."
"..EEEEEEEEEEEEEEEEEEEEEEEEEEE.."
"..EEEEEEEEEEEEEEEEEEEEEEEEEEE.."
"..EEEEEEEEEEEEEEEEEEEEEEEEEEE.."
"..EEEEEEEEEEEEEEEEEEEEEEEEEEE.."
"..EEEEEEEEEEEEEEEEEEEEEEEEEEE.."
"..DEEEEEEEEEEEEEEEEEEEEEEEEED.."
"..CEEEEEEEEEEEEEEEEEEEEEEEEEC.."
"..BEEEEEEEEEEEEEEEEEEEEEEEEEB.."
"...CEEEEEEEEEEEEEEEEEEEEEEEC..."
"....EEEEEEEEEEEEEEEEEEEEEEE...."
"....BEEEEEEEEEEEEEEEEEEEEEB...."
".....DEEEEEEEEEEEEEEEEEEED....."
"......DEEEEEEEEEEEEEEEEED......"
".......BEEEEEEEEEEEEEEEB......."
".........CEEEEEEEEEEEC........."
"..........BCDEEEEEDCB.........."
"..............................."
"..............................."
/* icon for state 2 */
"..............................."
"..............................."
"..........FGHIIIIIHGF.........."
".........GIIIIIIIIIIIG........."
".......FIIIIIIIIIIIIIIIF......."
"......HIIIIIIIIIIIIIIIIIH......"
".....HIIIIIIIIIIIIIIIIIIIH....."
"....FIIIIIIIIIIIIIIIIIIIIIF...."
"....IIIIIIIIHGF.FGHIIIIIIII...."
"...GIIIIIIIH.......HIIIIIIIG..."
"..FIIIIIIIG.........GIIIIIIIF.."
"..GIIIIIIH...........HIIIIIIG.."
"..HIIIIIH.............HIIIIIH.."
"..IIIIIIG.............GIIIIII.."
"..IIIIIIF.............FIIIIII.."
"..IIIIII...............IIIIII.."
"..IIIIIIF.............FIIIIII.."
"..IIIIIIG.............GIIIIII.."
"..HIIIIIH.............HIIIIIH.."
"..GIIIIIIH...........HIIIIIIG.."
"..FIIIIIIIG.........GIIIIIIIF.."
"...GIIIIIIIH.......HIIIIIIIG..."
"....IIIIIIIIHGF.FGHIIIIIIII...."
"....FIIIIIIIIIIIIIIIIIIIIIF...."
".....HIIIIIIIIIIIIIIIIIIIH....."
"......HIIIIIIIIIIIIIIIIIH......"
".......FIIIIIIIIIIIIIIIF......."
".........GIIIIIIIIIIIG........."
"..........FGHIIIIIHGF.........."
"..............................."
"..............................."
/* icon for state 3 */
"..............................."
"..............................."
"..JJJJ....BCDEEEEEDCB....JJJJ.."
"..JJJJJ..CEEEEEEEEEEEC..JJJJJ.."
"..JJJJJJEEEEEEEEEEEEEEEJJJJJJ.."
"..JJJJJJJEEEEEEEEEEEEEJJJJJJJ.."
"...JJJJJJJEEEEEEEEEEEJJJJJJJ..."
"....JJJJJJJEEEEEEEEEJJJJJJJ...."
"....EJJJJJJJEEEEEEEJJJJJJJE...."
"...CEEJJJJJJJEEEEEJJJJJJJEEC..."
"..BEEEEJJJJJJJEEEJJJJJJJEEEEB.."
"..CEEEEEJJJJJJJEJJJJJJJEEEEEC.."
"..DEEEEEEJJJJJJJJJJJJJEEEEEED.."
"..EEEEEEEEJJJJJJJJJJJEEEEEEEE.."
"..EEEEEEEEEJJJJJJJJJEEEEEEEEE.."
"..EEEEEEEEEEJJJJJJJEEEEEEEEEE.."
"..EEEEEEEEEJJJJJJJJJEEEEEEEEE.."
"..EEEEEEEEJJJJJJJJJJJEEEEEEEE.."
"..DEEEEEEJJJJJJJJJJJJJEEEEEED.."
"..CEEEEEJJJJJJJEJJJJJJJEEEEEC.."
"..BEEEEJJJJJJJEEEJJJJJJJEEEEB.."
"...CEEJJJJJJJEEEEEJJJJJJJEEC..."
"....EJJJJJJJEEEEEEEJJJJJJJE...."
"....JJJJJJJEEEEEEEEEJJJJJJJ...."
"...JJJJJJJEEEEEEEEEEEJJJJJJJ..."
"..JJJJJJJEEEEEEEEEEEEEJJJJJJJ.."
"..JJJJJJEEEEEEEEEEEEEEEJJJJJJ.."
"..JJJJJ..CEEEEEEEEEEEC..JJJJJ.."
"..JJJJ....BCDEEEEEDCB....JJJJ.."
"..............................."
"..............................."

XPM
/* width height num_colors chars_per_pixel */
"15 45 10 1"
/* colors */
". c #303030"
"B c #404040"
"C c #808080"
"D c #C0C0C0"
"E c #FFFFFF"
"F c #004000"
"G c #007F00"
"H c #00C000"
"I c #00FF00"
"J c #FF0000"
/* icon for state 1 */
"..............."
"....BDEEEDB...."
"...DEEEEEEED..."
"..DEEEEEEEEED.."
".BEEEEEEEEEEEB."
".DEEEEEEEEEEED."
".EEEEEEEEEEEEE."
".EEEEEEEEEEEEE."
".EEEEEEEEEEEEE."
".DEEEEEEEEEEED."
".BEEEEEEEEEEEB."
"..DEEEEEEEEED.."
"...DEEEEEEED..."
"....BDEEEDB...."
"..............."
/* icon for state 2 */
"..............."
"....FHIIIHF...."
"...HIIIIIIIH..."
"..HIIIIIIIIIH.."
".FIIIHF.FHIIIF."
".HIIH.....HIIH."
".IIIF.....FIII."
".III.......III."
".IIIF.....FIII."
".HIIH.....HIIH."
".FIIIHF.FHIIIF."
"..HIIIIIIIIIH.."
"...HIIIIIIIH..."
"....FHIIIHF...."
"..............."
/* icon for state 3 */
"..............."
".JJ.BDEEEDB.JJ."
".JJJEEEEEEEJJJ."
"..JJJEEEEEJJJ.."
".BEJJJEEEJJJEB."
".DEEJJJEJJJEED."
".EEEEJJJJJEEEE."
".EEEEEJJJEEEEE."
".EEEEJJJJJEEEE."
".DEEJJJEJJJEED."
".BEJJJEEEJJJEB."
"..JJJEEEEEJJJ.."
".JJJEEEEEEEJJJ."
".JJ.BDEEEDB.JJ."
"..............."

XPM
/* width height num_colors chars_per_pixel */
"7 21 11 1"
/* colors */
". c #303030"
"B c #404040"
"C c #808080"
"D c #C0C0C0"
"E c #FFFFFF"
"F c #004000"
"G c #007F00"
"H c #00C000"
"I c #00FF00"
"J c #FF0000"
"K c #E0E0E0"
/* icon for state 1 */
".BKEKB."
"BEEEEEB"
"KEEEEEK"
"EEEEEEE"
"KEEEEEK"
"BEEEEEB"
".BKEKB."
/* icon for state 2 */
".FHIHF."
"FIIIIIF"
"HIH.HIH"
"II...II"
"HIH.HIH"
"FIIIIIF"
".FHIHF."
/* icon for state 3 */
"JBKEKBJ"
"BJEEEJB"
"KEJEJEK"
"EEEJEEE"
"KEJEJEK"
"BJEEEJB"
"JBKEKBJ"
User avatar
rowett
Moderator
Posts: 4597
Joined: January 31st, 2013, 2:34 am
Location: UK
Contact:

Re: Life tag testing

Post by rowett »

Build 460 is now available on the lazyslug server

Fixes in this build:
  • fix an issue with Identify calculating wrong spaceship speeds after grid growth
  • ensure RuleTable sections are at the beginning of the line
User avatar
rowett
Moderator
Posts: 4597
Joined: January 31st, 2013, 2:34 am
Location: UK
Contact:

Re: Life tag testing

Post by rowett »

dvgrn wrote: November 24th, 2019, 10:48 am Yup, it was the "@TREE" in the comment text. The original version of the rule is below; to get it working I just added a space between @ and TREE.
Fixed in build 460, and I also restored the "@TREE" in the Rule:SlowLife page. Nice find!
User avatar
rowett
Moderator
Posts: 4597
Joined: January 31st, 2013, 2:34 am
Location: UK
Contact:

Re: Life tag testing

Post by rowett »

Build 461 is now available on the lazyslug server

Enhancements in this build:
  • further performance improvements to tokenizer
  • improved performance of @TREE decoder
Fixes in this build:
  • fixed Identify misbehaving with LOOP
  • handle HTML entities
User avatar
rowett
Moderator
Posts: 4597
Joined: January 31st, 2013, 2:34 am
Location: UK
Contact:

Re: Life tag testing

Post by rowett »

Build 462 is now available on the lazyslug server

Enhancements in this build:
  • added @TABLE support
    • note that in some cases the @TABLE runtime is significantly slower than the @TREE runtime so @TREE will be favoured if both are present in the rule
  • an optional rule name postfix may be specified with the <meta> tag on the web page hosting the Viewer
    • <meta name="LifeViewer" content="/myrepository/rules/ .rule">
    • an entry beginning with "." is used to define the postfix
User avatar
rowett
Moderator
Posts: 4597
Joined: January 31st, 2013, 2:34 am
Location: UK
Contact:

Re: Life tag testing

Post by rowett »

rowett wrote: November 21st, 2019, 12:24 am
dvgrn wrote: November 20th, 2019, 7:19 pm 1) Is the @TREE-only processing temporary or permanent?
I'm hoping permanent but if @TABLEs are required then temporary.
It turns out it was temporary.
User avatar
rowett
Moderator
Posts: 4597
Joined: January 31st, 2013, 2:34 am
Location: UK
Contact:

Re: Life tag testing

Post by rowett »

With a RuleTable @TABLE section is it valid to define a variable:

Code: Select all

var a = {0,1}
have one or more transitions that use it:

Code: Select all

0,1,2,a,0,0,0,1
then redefine the same variable:

Code: Select all

var a = {0,3}
and use it again:

Code: Select all

a,1,2,1,3,0,0,1
User avatar
dvgrn
Moderator
Posts: 12053
Joined: May 17th, 2009, 11:00 pm
Location: Madison, WI
Contact:

Re: Life tag testing

Post by dvgrn »

rowett wrote: November 30th, 2019, 5:31 am With a RuleTable @TABLE section is it valid to define a variable:

Code: Select all

var a = {0,1}
have one or more transitions that use it:

Code: Select all

0,1,2,a,0,0,0,1
then redefine the same variable:

Code: Select all

var a = {0,3}
and use it again:

Code: Select all

a,1,2,1,3,0,0,1
In theory, I have no idea -- I've never seen a rule table with variables anywhere except right up at the top.

In practice, there doesn't seem to be any problem with doing that:

Code: Select all

@RULE LifeHistory-test

@TABLE

n_states:7
neighborhood:Moore
symmetries:rotate8

var a={0,2,4,6}
var b={0,2,4,6}
var c={0,2,4,6}
var d={0,2,4,6}
var e={0,2,4,6}
var f={0,2,4,6}
var g={3,5}
var h={0,1,2}
var i={0,1,2,3,4,5,6}
var j={0,1,2,3,4,5,6}
var k={0,1,2,3,4,5,6}
var l={0,1,2,3,4,5,6}
var m={0,1,2,3,4,5,6}
var n={0,1,2,3,4,5,6}
var o={0,1,2,3,4,5,6}
var p={0,1,2,3,4,5,6}
var q={1,3,5}
var R={1,3,5}
var S={1,3,5}
var T={1,3,5}
var u={3,4,5}

# boundary cell always stays a boundary cell
6,i,j,k,l,m,n,o,p,6

# anything else that touches a boundary cell dies
# (using 'u' instead of 'g' below lets gliders survive as blocks)
g,6,i,j,k,l,m,n,o,4
1,6,i,j,k,l,m,n,o,2

# marked 3-neighbour birth
#  (has to be separate from the next section
#   only to handle the extra 'start' state 5)
4,R,S,T,a,b,c,d,e,3
4,R,S,a,T,b,c,d,e,3
4,R,S,a,b,T,c,d,e,3
4,R,S,a,b,c,T,d,e,3
4,R,S,a,b,c,d,T,e,3
4,R,a,S,b,T,c,d,e,3
4,R,a,S,b,c,T,d,e,3

# marked 3-neighbour survival
g,R,S,T,a,b,c,d,e,g
g,R,S,a,T,b,c,d,e,g
g,R,S,a,b,T,c,d,e,g
g,R,S,a,b,c,T,d,e,g
g,R,S,a,b,c,d,T,e,g
g,R,a,S,b,T,c,d,e,g
g,R,a,S,b,c,T,d,e,g

# normal 3-neighbour birth
h,R,S,T,a,b,c,d,e,1
h,R,S,a,T,b,c,d,e,1
h,R,S,a,b,T,c,d,e,1
h,R,S,a,b,c,T,d,e,1
h,R,S,a,b,c,d,T,e,1
h,R,a,S,b,T,c,d,e,1
h,R,a,S,b,c,T,d,e,1

# 2-neighbour survival
q,R,S,a,b,c,d,e,f,q
q,R,a,S,b,c,d,e,f,q
q,R,a,b,S,c,d,e,f,q
q,R,a,b,c,S,d,e,f,q

var a={0,1,2,3,4,5,6}

# ON states 3 and 5 go to history state 4 if they don't survive
g,i,j,k,l,m,n,o,a,4

# Otherwise ON states die and become the history state
q,i,j,k,l,m,n,o,a,2

@COLORS

1    0  255    0
2    0    0  128
3  216  255  216
4  255    0    0
5  255  255    0
6   96   96   96
At least, if the old definition of the 'a' variable were being used for the last two lines, state 1, 3, or 5 ON cell surrounded by ON cells should stay on instead of turning off -- but they don't.
User avatar
rowett
Moderator
Posts: 4597
Joined: January 31st, 2013, 2:34 am
Location: UK
Contact:

Re: Life tag testing

Post by rowett »

Build 463 is now available on the lazyslug server

Enhancements in this build:
  • added hexagonal and one dimensional neighbourhood @TABLE runtimes
  • added improved error reporting for invalid @TREE or @TABLE rules
Fixes in this build:
  • allow var redefinition in @TABLE rules
  • fixed colours for @TREE or @TABLE rules with only 2 states
User avatar
dvgrn
Moderator
Posts: 12053
Joined: May 17th, 2009, 11:00 pm
Location: Madison, WI
Contact:

Re: Life tag testing

Post by dvgrn »

rowett wrote: November 29th, 2019, 1:18 pmIt turns out it was temporary.
Impressive! Guess I'll have to try getting foodshapeloop working now.

Of course the next step would be to go one better than Golly, and support Nutshell transpilation...

I haven't dared to look at the code to see how painful it would be to port it to Javascript. Apparently there's an online transpiler.
User avatar
rowett
Moderator
Posts: 4597
Joined: January 31st, 2013, 2:34 am
Location: UK
Contact:

Re: Life tag testing

Post by rowett »

Build 464 is now available on the lazyslug server

Enhancements in this build:
  • improved @TABLE runtime performance
User avatar
dvgrn
Moderator
Posts: 12053
Joined: May 17th, 2009, 11:00 pm
Location: Madison, WI
Contact:

Re: Life tag testing

Post by dvgrn »

Okay, foodshapeloop appears to run correctly -- I think. Some of these rules have so many versions that it's hard to be sure the posted loops are behaving exactly the way they're supposed to. But they're certainly behaving more or less like shapeloops.

I'm currently having trouble with foodshapeloop2 for some reason. Test patterns are half a dozen posts below the rule definition post. Same issue with shapeloop2a -- hard refresh in Chrome via Ctrl+F5 or Ctrl+Shift+R doesn't have any effect.

-- MIght this be because there are other patterns on the same page with rules that aren't defined in the LifeWiki? I'm seeing a couple of

Code: Select all

/wiki/Rule:2armshapeloop2-a:1 Failed to load resource: the server responded with a status of 404 (Not Found)
in the developer console, but I'm not sure if LifeViewer also stops trying to load the shapeloop2a rule after encountering these errors.
User avatar
rowett
Moderator
Posts: 4597
Joined: January 31st, 2013, 2:34 am
Location: UK
Contact:

Re: Life tag testing

Post by rowett »

dvgrn wrote: December 1st, 2019, 9:49 am I'm currently having trouble with foodshapeloop2 for some reason. Test patterns are half a dozen posts below the rule definition post. Same issue with shapeloop2a
It's because they both have "Var" with a capital V and LifeViewer is expecting lower case. If "Var" is valid then I'll make LifeViewer case-insensitive. Please let me know.
dvgrn wrote: December 1st, 2019, 9:49 am I'm seeing a couple of

Code: Select all

/wiki/Rule:2armshapeloop2-a:1 Failed to load resource: the server responded with a status of 404 (Not Found)
in the developer console, but I'm not sure if LifeViewer also stops trying to load the shapeloop2a rule after encountering these errors.
No it doesn't stop.
User avatar
dvgrn
Moderator
Posts: 12053
Joined: May 17th, 2009, 11:00 pm
Location: Madison, WI
Contact:

Re: Life tag testing

Post by dvgrn »

rowett wrote: December 1st, 2019, 10:01 amIt's because they both have "Var" with a capital V and LifeViewer is expecting lower case. If "Var" is valid then I'll make LifeViewer case-insensitive. Please let me know.
Ah, right, sorry. My memory is suspiciously sieve-like sometimes.

I haven't seen this "Var" aberration anywhere outside of the Shapeloop thread yet, and it only shows up accidentally there, in the first couple of lines that seem to have been copy/pasted to lots of variants of the rule.

Maybe if there's an easy way to complain about the "Var" but still allow it, that could be an option? Obviously Golly allows a capitalized "Var", but it seems slightly ugly to let them hang around. I don't remember offhand if a capitalized variable name is considered to be a different variable from a lowercase one, but if so, then people should be paying careful attention to capitalization.
User avatar
rowett
Moderator
Posts: 4597
Joined: January 31st, 2013, 2:34 am
Location: UK
Contact:

Re: Life tag testing

Post by rowett »

dvgrn wrote: December 1st, 2019, 10:14 am Maybe if there's an easy way to complain about the "Var" but still allow it, that could be an option? Obviously Golly allows a capitalized "Var", but it seems slightly ugly to let them hang around. I don't remember offhand if a capitalized variable name is considered to be a different variable from a lowercase one, but if so, then people should be paying careful attention to capitalization.
Golly is case insensitive for that match and others but case sensitive for variable names so I'll have LifeViewer follow suit.
User avatar
rowett
Moderator
Posts: 4597
Joined: January 31st, 2013, 2:34 am
Location: UK
Contact:

Re: Life tag testing

Post by rowett »

Build 465 is now available on the lazyslug server

Fixes in this build:
  • case insensitive keyword match for @TREE and @TABLE decoding
User avatar
rowett
Moderator
Posts: 4597
Joined: January 31st, 2013, 2:34 am
Location: UK
Contact:

Re: Life tag testing

Post by rowett »

Build 466 is now available on the lazyslug server

Enhancements in this build:
  • decode RuleTable @ICONS section (no render)
  • improved @TABLE runtime performance
Fixes in this build:
  • IE compatibility fixes
  • fixed reading RuleTables with missing final new line
  • reset pattern type flags before RuleTable decode
  • fix quotes in comments for tokenizer
  • allow empty @TABLE or @TREE section for -shared rules
User avatar
rowett
Moderator
Posts: 4597
Joined: January 31st, 2013, 2:34 am
Location: UK
Contact:

Re: Life tag testing

Post by rowett »

Build 467 is now available on the lazyslug server

Enhancements in this build:
  • parse built in icon sets
Locked