You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@wicket.apache.org by Korbinian Bachl <ko...@whiskyworld.de> on 2006/10/25 11:48:51 UTC

Possible Bug

Hi,
 
yesterday i showed the concept of omponents to a friend and stumled into
something i dont understand and think it might be a bug. 
 
I have a small panelcompoment that holds a searchform (textfield + submit)
nothing special here, the code behind looks like: 
 
 @Override
        public void onSubmit() 
        {
            String suchFeld = getSuchfeld();
            if(suchFeld.length()>0)
            {
                PageParameters params = new PageParameters();
                params.add("finde",suchFeld);
                setResponsePage(Suche.class,params);
            }
            else
            {
                setResponsePage(getPage().getClass());
            }  
      }
 
the component is put into a "BasePage":
 
 public BasePage() {
        ....    
        add(bar);
        add(new SuchPanel("SuchPanel"));
        .....
}
 
wich is then extended by the real page:
 
public class Foo extends BasePage{
    
    /** Creates a new instance of Zigarren */
    public Foo() {
        }
 
wich works all fine, however if the class name contains non ascii letters
(e.g: ö ä ü etc.) it gives me a bug if nothing is entered into the search
and the part
 
public class Zubehör extends BasePage{
    
    /** Creates a new instance of Zubehör */
    public Zubehör() {
    }
 
"setResponsePage(getPage().getClass());" comes to action, the trouble is
that the page might have the URL:
?wicket:bookmarkablePage=:de.whiskyworld.shop.pages.Zubeh%C3%B6r
but the form tries to go to : 
wicket:bookmarkablePage=:de.whiskyworld.shop.pages.Zubeh%F6r
 
wich results in a CODE 404 in the App Server 
 
im on wicket 1.2.2, and now wonder if this is a bug in wicket or if "im the
bug" by calling classes Zubehör etc. - wich shouldnt be a problem in java, i
thought.
 
Best regards,
 
Korbinian

AW: Possible Bug

Posted by Korbinian Bachl <ko...@whiskyworld.de>.
yeah, i put it in... was just to blind to find the link to jira :O 
 

> -----Ursprüngliche Nachricht-----
> Von: Juergen Donnerstag [mailto:juergen.donnerstag@gmail.com] 
> Gesendet: Mittwoch, 25. Oktober 2006 16:10
> An: wicket-dev@incubator.apache.org
> Betreff: Re: Possible Bug
> 
> I've ssen you create the jira bug already. With respect to 
> the code where the encoding has to happen, I actually don't 
> know either. Not even sure it is a single place in code base. 
> Unfortunately I'm not able to look into it right now, but may 
> be one of the other devs do know it?
> 
> Juergen
> 
> On 10/25/06, Korbinian Bachl <ko...@whiskyworld.de> wrote:
> > Hi Jürgen,
> >
> > can you please point me to the URl for the wicket jira ? and if 
> > possible show me the place this happens in wicket code ? im 
> not sure 
> > if im good enough to fix it yet, but ill try.
> >
> > Best Regards,
> >
> > Korbinian
> >
> >
> > > -----Ursprüngliche Nachricht-----
> > > Von: Juergen Donnerstag [mailto:juergen.donnerstag@gmail.com]
> > > Gesendet: Mittwoch, 25. Oktober 2006 12:00
> > > An: wicket-dev@incubator.apache.org
> > > Betreff: Re: Possible Bug
> > >
> > > Yes, sounds like a bug. We are not automatically url/base64 
> > > encoding/decoding all query parameters. Please create a jira bug 
> > > report to make sure it gets not forgotten. Of course if 
> you were to 
> > > provide a patch, that would be even better.
> > >
> > > Juergen
> > >
> > > On 10/25/06, Korbinian Bachl <ko...@whiskyworld.de> wrote:
> > > > Hi,
> > > >
> > > > yesterday i showed the concept of omponents to a friend and 
> > > > stumled into something i dont understand and think it 
> might be a bug.
> > > >
> > > > I have a small panelcompoment that holds a searchform 
> (textfield +
> > > > submit) nothing special here, the code behind looks like:
> > > >
> > > >  @Override
> > > >        public void onSubmit()
> > > >        {
> > > >            String suchFeld = getSuchfeld();
> > > >            if(suchFeld.length()>0)
> > > >            {
> > > >                PageParameters params = new PageParameters();
> > > >                params.add("finde",suchFeld);
> > > >                setResponsePage(Suche.class,params);
> > > >            }
> > > >            else
> > > >            {
> > > >                setResponsePage(getPage().getClass());
> > > >            }
> > > >      }
> > > >
> > > > the component is put into a "BasePage":
> > > >
> > > >  public BasePage() {
> > > >        ....
> > > >        add(bar);
> > > >        add(new SuchPanel("SuchPanel"));
> > > >        .....
> > > > }
> > > >
> > > > wich is then extended by the real page:
> > > >
> > > > public class Foo extends BasePage{
> > > >
> > > >    /** Creates a new instance of Zigarren */
> > > >    public Foo() {
> > > >        }
> > > >
> > > > wich works all fine, however if the class name contains 
> non ascii 
> > > > letters
> > > > (e.g: ö ä ü etc.) it gives me a bug if nothing is 
> entered into the 
> > > > search and the part
> > > >
> > > > public class Zubehör extends BasePage{
> > > >
> > > >    /** Creates a new instance of Zubehör */
> > > >    public Zubehör() {
> > > >    }
> > > >
> > > > "setResponsePage(getPage().getClass());" comes to action,
> > > the trouble
> > > > is that the page might have the URL:
> > > > ?wicket:bookmarkablePage=:de.whiskyworld.shop.pages.Zubeh%C3%B6r
> > > > but the form tries to go to :
> > > > wicket:bookmarkablePage=:de.whiskyworld.shop.pages.Zubeh%F6r
> > > >
> > > > wich results in a CODE 404 in the App Server
> > > >
> > > > im on wicket 1.2.2, and now wonder if this is a bug in 
> wicket or 
> > > > if "im the bug" by calling classes Zubehör etc. - wich 
> shouldnt be 
> > > > a problem in java, i thought.
> > > >
> > > > Best regards,
> > > >
> > > > Korbinian
> > > >
> > > >
> > >
> >
> >
> 


Re: Possible Bug

Posted by Juergen Donnerstag <ju...@gmail.com>.
I've ssen you create the jira bug already. With respect to the code
where the encoding has to happen, I actually don't know either. Not
even sure it is a single place in code base. Unfortunately I'm not
able to look into it right now, but may be one of the other devs do
know it?

Juergen

On 10/25/06, Korbinian Bachl <ko...@whiskyworld.de> wrote:
> Hi Jürgen,
>
> can you please point me to the URl for the wicket jira ? and if possible
> show me the place this happens in wicket code ? im not sure if im good
> enough to fix it yet, but ill try.
>
> Best Regards,
>
> Korbinian
>
>
> > -----Ursprüngliche Nachricht-----
> > Von: Juergen Donnerstag [mailto:juergen.donnerstag@gmail.com]
> > Gesendet: Mittwoch, 25. Oktober 2006 12:00
> > An: wicket-dev@incubator.apache.org
> > Betreff: Re: Possible Bug
> >
> > Yes, sounds like a bug. We are not automatically url/base64
> > encoding/decoding all query parameters. Please create a jira
> > bug report to make sure it gets not forgotten. Of course if
> > you were to provide a patch, that would be even better.
> >
> > Juergen
> >
> > On 10/25/06, Korbinian Bachl <ko...@whiskyworld.de> wrote:
> > > Hi,
> > >
> > > yesterday i showed the concept of omponents to a friend and stumled
> > > into something i dont understand and think it might be a bug.
> > >
> > > I have a small panelcompoment that holds a searchform (textfield +
> > > submit) nothing special here, the code behind looks like:
> > >
> > >  @Override
> > >        public void onSubmit()
> > >        {
> > >            String suchFeld = getSuchfeld();
> > >            if(suchFeld.length()>0)
> > >            {
> > >                PageParameters params = new PageParameters();
> > >                params.add("finde",suchFeld);
> > >                setResponsePage(Suche.class,params);
> > >            }
> > >            else
> > >            {
> > >                setResponsePage(getPage().getClass());
> > >            }
> > >      }
> > >
> > > the component is put into a "BasePage":
> > >
> > >  public BasePage() {
> > >        ....
> > >        add(bar);
> > >        add(new SuchPanel("SuchPanel"));
> > >        .....
> > > }
> > >
> > > wich is then extended by the real page:
> > >
> > > public class Foo extends BasePage{
> > >
> > >    /** Creates a new instance of Zigarren */
> > >    public Foo() {
> > >        }
> > >
> > > wich works all fine, however if the class name contains non ascii
> > > letters
> > > (e.g: ö ä ü etc.) it gives me a bug if nothing is entered into the
> > > search and the part
> > >
> > > public class Zubehör extends BasePage{
> > >
> > >    /** Creates a new instance of Zubehör */
> > >    public Zubehör() {
> > >    }
> > >
> > > "setResponsePage(getPage().getClass());" comes to action,
> > the trouble
> > > is that the page might have the URL:
> > > ?wicket:bookmarkablePage=:de.whiskyworld.shop.pages.Zubeh%C3%B6r
> > > but the form tries to go to :
> > > wicket:bookmarkablePage=:de.whiskyworld.shop.pages.Zubeh%F6r
> > >
> > > wich results in a CODE 404 in the App Server
> > >
> > > im on wicket 1.2.2, and now wonder if this is a bug in wicket or if
> > > "im the bug" by calling classes Zubehör etc. - wich shouldnt be a
> > > problem in java, i thought.
> > >
> > > Best regards,
> > >
> > > Korbinian
> > >
> > >
> >
>
>

AW: Possible Bug

Posted by Korbinian Bachl <ko...@whiskyworld.de>.
Hi Jürgen,

can you please point me to the URl for the wicket jira ? and if possible
show me the place this happens in wicket code ? im not sure if im good
enough to fix it yet, but ill try.

Best Regards,

Korbinian


> -----Ursprüngliche Nachricht-----
> Von: Juergen Donnerstag [mailto:juergen.donnerstag@gmail.com] 
> Gesendet: Mittwoch, 25. Oktober 2006 12:00
> An: wicket-dev@incubator.apache.org
> Betreff: Re: Possible Bug
> 
> Yes, sounds like a bug. We are not automatically url/base64 
> encoding/decoding all query parameters. Please create a jira 
> bug report to make sure it gets not forgotten. Of course if 
> you were to provide a patch, that would be even better.
> 
> Juergen
> 
> On 10/25/06, Korbinian Bachl <ko...@whiskyworld.de> wrote:
> > Hi,
> >
> > yesterday i showed the concept of omponents to a friend and stumled 
> > into something i dont understand and think it might be a bug.
> >
> > I have a small panelcompoment that holds a searchform (textfield + 
> > submit) nothing special here, the code behind looks like:
> >
> >  @Override
> >        public void onSubmit()
> >        {
> >            String suchFeld = getSuchfeld();
> >            if(suchFeld.length()>0)
> >            {
> >                PageParameters params = new PageParameters();
> >                params.add("finde",suchFeld);
> >                setResponsePage(Suche.class,params);
> >            }
> >            else
> >            {
> >                setResponsePage(getPage().getClass());
> >            }
> >      }
> >
> > the component is put into a "BasePage":
> >
> >  public BasePage() {
> >        ....
> >        add(bar);
> >        add(new SuchPanel("SuchPanel"));
> >        .....
> > }
> >
> > wich is then extended by the real page:
> >
> > public class Foo extends BasePage{
> >
> >    /** Creates a new instance of Zigarren */
> >    public Foo() {
> >        }
> >
> > wich works all fine, however if the class name contains non ascii 
> > letters
> > (e.g: ö ä ü etc.) it gives me a bug if nothing is entered into the 
> > search and the part
> >
> > public class Zubehör extends BasePage{
> >
> >    /** Creates a new instance of Zubehör */
> >    public Zubehör() {
> >    }
> >
> > "setResponsePage(getPage().getClass());" comes to action, 
> the trouble 
> > is that the page might have the URL:
> > ?wicket:bookmarkablePage=:de.whiskyworld.shop.pages.Zubeh%C3%B6r
> > but the form tries to go to :
> > wicket:bookmarkablePage=:de.whiskyworld.shop.pages.Zubeh%F6r
> >
> > wich results in a CODE 404 in the App Server
> >
> > im on wicket 1.2.2, and now wonder if this is a bug in wicket or if 
> > "im the bug" by calling classes Zubehör etc. - wich shouldnt be a 
> > problem in java, i thought.
> >
> > Best regards,
> >
> > Korbinian
> >
> >
> 


Re: Possible Bug

Posted by Juergen Donnerstag <ju...@gmail.com>.
Yes, sounds like a bug. We are not automatically url/base64
encoding/decoding all query parameters. Please create a jira bug
report to make sure it gets not forgotten. Of course if you were to
provide a patch, that would be even better.

Juergen

On 10/25/06, Korbinian Bachl <ko...@whiskyworld.de> wrote:
> Hi,
>
> yesterday i showed the concept of omponents to a friend and stumled into
> something i dont understand and think it might be a bug.
>
> I have a small panelcompoment that holds a searchform (textfield + submit)
> nothing special here, the code behind looks like:
>
>  @Override
>        public void onSubmit()
>        {
>            String suchFeld = getSuchfeld();
>            if(suchFeld.length()>0)
>            {
>                PageParameters params = new PageParameters();
>                params.add("finde",suchFeld);
>                setResponsePage(Suche.class,params);
>            }
>            else
>            {
>                setResponsePage(getPage().getClass());
>            }
>      }
>
> the component is put into a "BasePage":
>
>  public BasePage() {
>        ....
>        add(bar);
>        add(new SuchPanel("SuchPanel"));
>        .....
> }
>
> wich is then extended by the real page:
>
> public class Foo extends BasePage{
>
>    /** Creates a new instance of Zigarren */
>    public Foo() {
>        }
>
> wich works all fine, however if the class name contains non ascii letters
> (e.g: ö ä ü etc.) it gives me a bug if nothing is entered into the search
> and the part
>
> public class Zubehör extends BasePage{
>
>    /** Creates a new instance of Zubehör */
>    public Zubehör() {
>    }
>
> "setResponsePage(getPage().getClass());" comes to action, the trouble is
> that the page might have the URL:
> ?wicket:bookmarkablePage=:de.whiskyworld.shop.pages.Zubeh%C3%B6r
> but the form tries to go to :
> wicket:bookmarkablePage=:de.whiskyworld.shop.pages.Zubeh%F6r
>
> wich results in a CODE 404 in the App Server
>
> im on wicket 1.2.2, and now wonder if this is a bug in wicket or if "im the
> bug" by calling classes Zubehör etc. - wich shouldnt be a problem in java, i
> thought.
>
> Best regards,
>
> Korbinian
>
>