[e-lang] E 0.9.1b Breaks Old Code

Toby Murray toby.murray at comlab.ox.ac.uk
Thu Feb 21 19:57:58 EST 2008


Hi e-lang,

I've got some old E code that fails to run correctly on newer versions
of the E runtime (specifically with the current stable 0.9.1b and
current svn head). 

The specific problem seems to be that remote captp URIs are being
resolved to null, rather than far references.

Example code below:

$ cat testClient.e
def getObjectFromURI(uri) :any {
    introducer.sturdyFromURI(uri).getRcvr()
}
introducer.onTheAir()
def uri := interp.getArgs()[0]
println(`connecting to $uri`)
def remote := getObjectFromURI(uri)
remote <- run("test message")
interp.blockAtTop()

$ cat testServer.e
introducer.onTheAir()
def [sturdyHandle, _, _] :=
  identityMgr.makeKnown(println)
def uri := introducer.sturdyToURI(sturdyHandle)
println(`Clients can connect here on: $uri`)
interp.blockAtTop()


When running the client to connect to a running server, I get

=== 2008-02-22T00:53:06.745Z (PendingEvent.report:PendingEvent.java:107)
WRN
causality: Problem in turn <<Vat start in <runs in start>>,46>:
--vvvv--
<null>.run/1


java.lang.NoSuchMethodException: <null>.run/1
        at org.erights.e.elib.prim.VTable.shorten(VTable.java:197)
        at org.erights.e.elib.prim.E.callAll(E.java:163)
        at
org.erights.e.elib.vat.PendingDelivery.innerRun(PendingDelivery.java:96)
        at org.erights.e.elib.vat.PendingEvent.run(PendingEvent.java:74)
        at
org.erights.e.elib.vat.HeadlessRunner.run(HeadlessRunner.java:174)
        at java.lang.Thread.run(Thread.java:595)

--^^^^--


Adding  

pragma.syntax("0.8")

to the client fixes the trouble.

What "syntax" changes occurred between 0.8 and 0.9 that the semantics of
resolving captp URIs to far refs has changed? How can I make my old code
compatible with new E runtimes?

Cheers

Toby



More information about the e-lang mailing list