Whenever I try to access some form component of the model. Whether in
Pier or in my own testing of Magritte, I this error.
"Error: My subclass should have overridden #build:"
I've searched the documentation. Yet, I couldn't find anything about
how to override "build:". Also because it is happening in Pier, not
just my own implementation of Magritte. I'm assuming something else
is at fault.
Anyone have any ideas. Thanks.
--
Jason Yates
jaywhy(a)gmail.com
>>> I am opening the widgets like so:
>>>
>>> openWidget: widget titled: title
>>>
>>> self call: (PRCurrentContext use: self during: [
>>> ((widget)
>>> context;
>>> addDecoration: (WAWindowDecoration new
>>> title: title);
>>> yourself)
>>> ]).
>>>
>>
>> Mhh, this certainly does not work, since the component is called
>> outside the scope of the dynamic-variable. Thus it should work if
>> you move the dynamic-variable outside the call:
>>
>> openWidget: widget titled: title
>> PRCurrentContext use: self during: [
>> self call: (widget
>> context;
>> addDecoration: (WAWindowDecoration new
>> title: title;
>> yourself);
>> yourself) ]
>
> I attempted the fix you suggested, but no luck.
Obviously this is a bit trickier than I first thought to get the
stack right. In fact Seaside is using the same technique to get
access to the current session ...
Try this, this should finally work, I hope :-)
openWidget: widget titled: title
PRCurrentContext use: self during: [
WARenderLoop new call: ((widget
addDecoration: (WAWindowDecoration new
title: title;
yourself);
yourself) ]
Cheers,
Lukas
--
Lukas Renggli
http://www.lukas-renggli.ch
This looks like a problem with backward compatibility with one of my
latest changes in the Pier-Security package: What I did is to add
permissions to be able to control the commands on a much fine-grained
bases, not only on command level. For example that anonymous people
are only able to add Pages, but not components or resources.
Now the problem is that the security decoration does not expect
command classes anymore, but Permission instances. Permission
instances basically reference a command class together with some
additional constraints. To fix you problem you need to reset the
security model. If you are still able to access the 'Change Group',
'Change Owner' and 'Change Other' commands simply reassign all the
rights recursively. Else something like
PUSecurity allInstances: [ :each |
each
groupPermissions: nil;
otherPermissions: nil;
ownerPermissions: nil ]
might do the trick.
Sorry for the inconvenience, but sometimes a change like that is
unavoidable ;-)
Cheers,
Lukas
On 19 Oct 2006, at 02:58, Keith Hodges wrote:
> I get this walkback commonly when using Security commands
>
> this is before I have added any users.
>
> Keith
>
>
> MessageNotUnderstood: PUAddPermission>>do:separatedBy:
>
> * PUAddPermission(Object)>>doesNotUnderstand: #do:separatedBy:
>
> self Add Component
> *temps*
> aMessage do: [] in
> MAStringWriter>>visitMultipleOptionDescription: {[:each |
> self
> object: each during: [s...etc...
> *inst vars*
> properties nil
> command PRAddCommand
> structure PRComponent
>
> * MAStringWriter>>visitMultipleOptionDescription:
>
> self a MAStringWriter
> *temps*
> aDescription a MAMultipleOptionDescription label:
> 'Permissions' comment: 'Defines the set of permissions used
> tog...etc...
> each nil
> *inst vars*
> stream a WriteStream ''
> object Add Component
>
> * MAMultipleOptionDescription>>acceptMagritte:
>
> self a MAMultipleOptionDescription label: 'Permissions'
> comment: 'Defines the set of permissions used tog...etc...
> *temps*
> aVisitor a MAStringWriter
> *inst vars*
> properties a Dictionary(#attributes->a WAHtmlAttributes
> #comment->'Defines the set of permissions used
> together...etc...
> accessor (MASelectorAccessor read: #permissions write:
> #permissions:)
> reference a MAPriorityContainer label: 'Permission'
> comment: nil
> options [an Array(Add File Add Page Add Component Edit Copy
> Move Remove View Environment Settings Change Group Change
> Other Change Owner)]
>
> * MAStringWriter(MAVisitor)>>visit:
>
> self a MAStringWriter
> *temps*
> anObject a MAMultipleOptionDescription label: 'Permissions'
> comment: 'Defines the set of permissions used tog...etc...
> *inst vars*
> stream a WriteStream ''
> object Add Component
>
> * MAStringWriter(MAWriter)>>write:description:to:
>
> self a MAStringWriter
> *temps*
> anObject Add Component
> aDescription a MAMultipleOptionDescription label:
> 'Permissions' comment: 'Defines the set of permissions used
> tog...etc...
> aStream a WriteStream ''
> *inst vars*
> stream a WriteStream ''
> object Add Component
>
> Send instant messages to your online friends http://
> uk.messenger.yahoo.com
--
Lukas Renggli
http://www.lukas-renggli.ch
In order to produce a full installation of Seaside-Magma-Pier the
configuration script is now available at.
http://smallwiki.unibe.ch/smallwiki/pier/installationofseasidemagmaandpier
To use it, open a vanilla image, open a workspace and 'doit'.
as always feedback would be welcomed.
best regards
Keith
-----
p.s. thanks to Simon for inspiring this approach and spurring it along
___________________________________________________________
Try the all-new Yahoo! Mail. "The New Version is radically easier to use" The Wall Street Journal
http://uk.docs.yahoo.com/nowyoucan.html
I have little experience with Pier. I don't understand why, when I
select the "Environment" selection, I receive and error:
"MAOptionDescription is abstract"
This comes from:
MAOptionDescription >>error:
"Create a new instance of the receiving class and checks if it is
concrete."
self isAbstract
ifTrue: [ self error: self name , ' is abstract.' ].
^ super new
I don't understand the error when looking thru the debugger thread. Any
help? Where can I look?
brad
Hi Keith,
> I am strugging to merge your new security widgets into
> PRPierControlPanel.
>
> Have you looked at PRPierControlPanel at all?
no sorry, I didn't had the time to look at or merge it yet. Indeed
this it is a bit difficult, since you changes to PRPierMain break all
my productive applications.
Also I have some problems with the way you write code: Personally I
pay a lot of attention to the way the source is formatted, especially
that it is properly indented, that there are no unnecessary
statements or brackets. Especially that it is readable, nice looking
and well fitting with the existing code.
I started to like the approach with the widgets and worked on that.
In fact, my initial concerns were certainly not valid. The latest
changes I committed came all from the requirements when setting up a
new productive server for a lecture here in Bern.
> PRPierControlPanel runs in the context of WADispatcherEditor, and
> so has to create a Pier like context if it wishes to display any
> pier widgets.
For a productive setup behind Apache there is no access to the
configuration application from outside the local network anyway. How
would you change the settings then?
> This did work with the previous Users/Groups control panel that you
> have replaced. However the new widgets do not seem to be getting
> the Current context.
I started from your code and extended it and added a superclass to
share some functionality. Just lately I also added a browse view to
navigate around the structures and to have an overview of the
permissions, users and groups (like the unix ls -la).
> I am opening the widgets like so:
>
> openWidget: widget titled: title
>
> self call: (PRCurrentContext use: self during: [
> ((widget)
> context;
> addDecoration: (WAWindowDecoration new
> title: title);
> yourself)
> ]).
Mhh, this certainly does not work, since the component is called
outside the scope of the dynamic-variable. Thus it should work if you
move the dynamic-variable outside the call:
openWidget: widget titled: title
PRCurrentContext use: self during: [
self call: (widget
context;
addDecoration: (WAWindowDecoration new
title: title;
yourself);
yourself) ]
Cheers,
Lukas
--
Lukas Renggli
http://www.lukas-renggli.ch
Dear All,
I have updated the repository with all of my mods. I do hope you like
them. I sincerely apologize in advance that my code quality may be
fairly appalling at times. (... myriad of excuses snipped....) I rest in
the knowledge that Lukas' is likely to be fairly tough on anything that
makes it through into the mainstream. I have tried to be gentle on the
core, indeed I have backed out some of my more radical changes.
I have begun to think about providing/using a framework for testing, and
so there is much more scope for improving things now.
To load Pier-Magma with tests you will also need Magma-sunit , a new
package in MagmaTester upon which PRMagmaPersistencyTest depends.
dont forget that for the faint hearted there is a preloaded image with
all of this in (see previous emails)
best regards
Keith
Send instant messages to your online friends http://uk.messenger.yahoo.com
Hi,
I am moving to another flat the coming weekend, therefor I won't be
able to respond to mails and my server will be offline starting
Saturday morning. This also means that the Magritte and Pier
repositories won't be accessible for a couple of days.
The server will be put online again as soon as possible, however it
might take a while to get things settled with the new internet
provider. I hope to be online at least on Wednesday next week, but
one never knows what happens.
Please continue with all the nice enhancements and extensions to Pier
and Magritte, we can merge them back into the main branch after the
server comes up again ;-)
Have fun,
Lukas
--
Lukas Renggli
http://www.lukas-renggli.ch
Hallo Michael,
if you use a newer windows machine you can try to use the IIS (the build-in webserver of windows). There you can copy the css-file from Lucas and after this change the hard coded style to your local adress of the IIS.
Hope this helps.
Cheers,
Frank