[Seaside] Seaside 3.2: WAUrl absolute: signals primitiveFailed
jtuchel at objektfabrik.de
jtuchel at objektfabrik.de
Tue Feb 28 15:26:47 UTC 2017
Hi there,
I am trying to port a Seaside Application from VA Smalltalk 8.6. to
8.6.3. That includes porting from Seaside 3.0 (?) to Seaside 3.2.
After some troubles with addLoadScript:, which needed documented
changes, I now am at a point where most of my Ajax callbacks don't work.
I debugged a little and found out that the callbacks really aren't found
in the callback registry.
The reason seems to be WAUrl which parses URLs incorrectly. At least I
think so.
Please try this in your image:
WAUrl absolute:
'/Buchhaltung?_s=F4N82ZReQEV2M1cP&_k=spf8TDq4kzHfrPCi&48&searchText=kas'
(48 is the key of my Ajax callback, as you might have guessed)
This works in VA Smalltalk 8.6 and in Pharo 5 with Seaside 3.0.
# In VAST 8.6.3 it yields a strange result:
The queryFields of the resulting WAUrl have the following keys: ('_s'
'_k' '48&searchText' 'searchText' nil nil)
--> That seems to be definitely wrong!!! The keys should be ('_s'
'_k' '48' 'searchText' nil nil)
# In Pharo 5 with Seaside 3.2, the above expression yields a debugger
with a primitiveFailed Error, because it tries to create a ByteString of
Size -12.
So WAUrl parses the callback (48) wrongly
Here is what I loaded into Pharo 5 (50770):
Metacello new
configuration: 'Seaside3';
repository:
'http://www.smalltalkhub.com/mc/Seaside/MetacelloConfigurations/main';
version: #'release3.2';
load.
Is this a known issue? Is there a fix for it? Has the logic for
registering and finding callbacks changed between 3.0 and 3.2, so do I
have to change my javascript code that issues ajax callbacks?
Thanks for reading,
Joachim
More information about the seaside
mailing list