mikifus / padland

Padland is a tool to manage, share, remember and read collaborative documents based on the Etherpad technology in Android.
Apache License 2.0
62 stars 15 forks source link

Can't add existing pad - pad name not accepted #46

Closed eternalbit closed 6 years ago

eternalbit commented 6 years ago

Created this pad: https://etherpad.wikimedia.org/p/thisisonlysomerandomtestcase

When I try to add the pad to Padland (note: I've added the wikimedia Server to my server list) by entering thisisonlysomerandomtestcase in the field Pad name and press Create or go to I get this message The pad name contains invalid characters and the pad is not opened.

Is the name maybe too long?

mikifus commented 6 years ago

I just tried that same pad you mention. It works. Maybe you added a space at the end without noticing?

eternalbit commented 6 years ago

Maybe you added a space at the end without noticing?

I checked again, no unintended space at the end. I entered thisisonlysomerandomtestcase and got the message mentioned above.

My server settings: name wikimedia url https://etherpad.wikimedia.org Etherpad Lite checked url bad prefix /p/ jquery-plugin supported checked

Actually I tried omitting the /p/ ... which led to the pad being added to my list. But when padland tries to open it I get an error message net::ERR_NAME_NOT_RESOLVED and clearly the url is bad: https://etherpad.wikimedia.orgthisis...

mikifus commented 6 years ago

I tried again. I pasted exactly the data you provided. Still can't reproduce it.

The error happens when the whole URL is not valid: https://github.com/mikifus/padland/blob/6967659657304f727a8d1e865cf9216114a4c1bd/app/src/main/java/com/mikifus/padland/NewPadActivity.java#L194

This means that the error can be on your server definition, not on the pad name. I insist on the white space as the Android text fields make the keyboard add spaces automatically.

mikifus commented 6 years ago

Hi, there's a new beta version where name and URL parsing was improved.

Can you try and tell me about results? https://github.com/mikifus/padland/releases/tag/v1.4-beta

schumaml commented 6 years ago

I found that this happened due to not ending the server address with a / - when I changed this (I'm using etherpad.gnome.org) it started working for any pad name I had created

mikifus commented 6 years ago

This is indeed fixed in the beta. I need some more testing before publishing a new release.