sqlitebrowser / dbhub.io

A "Cloud" for SQLite databases. Collaborative development for your data. ๐Ÿ˜Š
https://dbhub.io
GNU Affero General Public License v3.0
372 stars 39 forks source link

Newbie Thoughts #71

Open chrisjlocke opened 7 years ago

chrisjlocke commented 7 years ago

There is an option to create a certificate, but from a 'Newbies' point of view, what do I want with a certificate? Do I need one now? Do I need one per database? If I create a certificate, will the other ones be deleted? What if mty cat eats it? What if I lose it?

Yes, I know its pre-filled in, but if thats an example, can't it actually be filled in? (if that makes sense). As in, "yup, I don't want to give me address, so I'll go with your suggestion ... which I now have to type again...". I blindly clicked 'next' as the suggestion given was great, but of course, it wasn't filled in. Maybe a "if emailAddress = "" then emailAddress=suggestedEmailAddress'.......

image

image

A minor thing, but 'pulls you out of the experience', if you know what I mean....

When you view someone elses databases, then want to view your own again, it would make more sense (? or not....) that the '/' would go to 'your' home, not 'the' home, which you can get to via the main 'dbhub.io' icon. Again, the 'where are my databases?' is tucked away at the top.... from a newbies point of view, its not that clear....

chrisjlocke commented 7 years ago

Type a description, think, "ooh, markdown", click the link then lose what you've typed, as the markdown page opens....

chrisjlocke commented 7 years ago

image

Edit: Aah, double lines? This doesn't occur in this box though. image

image

justinclift commented 7 years ago

Awesome, thanks Chris! This is very appreciated, having "new user" eyes on this should definitely help with the initial intro experience. ๐Ÿ˜

Will there be a page explaining what the certificates is about?

Definitely. I was thinking to do something animated-gif style later on today for new-user walkthroughs, and putting it in the start of a "Docs" section (on wiki) + add that to the currently-empty top menu bar.

Hmmm, it'd probably be useful to have a "new user intro" page which pops up the first time someone logs in, offering to point them at the new user content.

Related to this we probably need to add stuff to the DB4S wiki to show how to use the Remote panel. Animated gif style thing there would probably be optimal too. Hmmm... you seem to have a knack for that kind of thing... interested?

Can the 'preferences' have a link to the preferences?

Oops. Definitely. :smile:

'Email address can't be blank' - but it wasn't.... ;)

Oh, hadn't thought of it from that point of view. Yeah, seems pretty do-able.

I presume its just a bit of CSS (says me...) but the text in menus has an I beam, not an arrow.

Ahhh, yep, pretty sure that can be adjusted fairly simply. Will do.

Home isn't home. Clicking the '/' is the same as the main icon above it.

Thanks. The concept hadn't occurred to me (I was so used to just using it for navigation to a root list of users pre-front-page). Now we have a front page though, I can definitely see how that makes sense. Should be trivial to adjust. :smile:

Can the 'markdown' link open in a new tab?

Yep. :smile:

When typing in the description, etc, newlines don't seem to be working?

Gah. Hadn't noticed that. That'll definitely need looking into as well. :smile:


k, going to go through and fix the easy ones right now.

chrisjlocke commented 7 years ago

When you create a new tag, a 'new tag' button would be handy, otherwise, to add another tag, its a lot of 'back' button pushing.... ;)

image

chrisjlocke commented 7 years ago

you seem to have a knack for that kind of thing... interested?

Of course.... once I work it out myself! ;) ๐Ÿ’ Throw down some text, and I can pad it out with screenshots and stuff. ๐Ÿ“ธ

having "new users" eye on this should definitely help with the initial intro experience.

I get this at work - code an application, and because I know the workflow, don't always appreciate it from someone who doesn't know whats going on! The user says, "do I have to click this and then that?" "Yes, isn't it obvious? Why would you even click that other button first?" .... redesigns GUI...

chrisjlocke commented 7 years ago

image

I clicked delete (as you would) and the release just deleted. An 'are you sure?' screen would be handy...although I appreciate they're a bitch to add.... (mroe screens, etc)

chrisjlocke commented 7 years ago

It wasn't entirely obvious how to create a new commit. On the 'commits' screen, it lists the current ones, but no 'new'. Maybe add an 'upload database' button? I'm guessing its being more driven by DB4S than the website? (I'm just website tinkering at the mo...)

Linked to this, if you have several databases uploaded, if you do add a database and it adds it as a commit, could this be confirmed to the user? If they upload 'dingle.db' which just so happens to be in their repository from 3 years ago, it might not be obvious this is a seperate database and not a commit related that database.... (if that makes sense....)

/re-adjusts newbie hat.... ๐ŸŽฉ

chrisjlocke commented 7 years ago

Downloading a database with spaces in it, creates a filename with pluses in it instead. Is this by design?
image

(and brackets are HTML'ed)

chrisjlocke commented 7 years ago

image

From a newbie point of view (which is why I've stuck it in here again) but are releases/branches/tags per database, or per commit?

I've created some branches from 2 different commits, but its showing as having branches/tags/releases overall, rather than per commit (or branch) as I'd have expected.... I guess it would be too confusing to have Tags: 1 (3) (as in 1 tag in this commit, 3 overall), etc.... I'm just muddying the waters, aren't I..... ;) ๐Ÿ„

justinclift commented 7 years ago

Create tag button on tags page

Sure. I'm trying to think of what it should do though... take the user to the commits page so they can go from there, or something else? :smile:

justinclift commented 7 years ago

delete releases needs an 'are you sure?'

Ahhh. Yep, didn't even occur to me. Will do. :smile:

justinclift commented 7 years ago

new commit ... a newbie would (could) scratch their head a lot

Kind of like adding a "Create new commit" button on the commits page, and then hmm... maybe show an info thing saying something like "To create a new commit, just upload a database using the same name as the existing one. The new version of the database will be added as a commit." + maybe a button to continue to the upload page?

justinclift commented 7 years ago

Linked to this, if you have several databases uploaded, if you do add a database and it adds it as a commit, could this be confirmed to the user? If they upload 'dingle.db' which just so happens to be in their repository from 3 years ago, it might not be obvious this is a seperate database and not a commit related that database.... (if that makes sense....)

Makes sense. Some kind of feedback to make sure the user knows what's going on.

Hmmm... maybe adding some kind of notification/status message thing to the database page when it bounces there after the upload.

Or maybe bounce to the commits page instead + also show that "some kind of status message" thing to let the user know?

chrisjlocke commented 7 years ago

Ahhh. Yep, didn't even occur to me. Will do.

($10 bonus if you can find the issue you referred to! ;) )

I'd be interested in looking at (like you've done for the 'deleete database?') how you do it, just to grasp the underlings of the code and what to do - the little things like that would be handy for me to chip in and help ( or hinder.... haha!)

justinclift commented 7 years ago

Downloading a database is +'d

Yeah, this one I've struggled with a bit already. I'm not sure how to get spaces working in the "Content-Disposition" header

It might be as simple as embedding single quote characters around the %s.csv, which I thought I'd already tried... but maybe I missed that somehow. :smile:

chrisjlocke commented 7 years ago

Create tag button on tags page

Sure. I'm trying to think of what it should do though... take the user to the commits page so they can go from there, or something else? ๐Ÿ˜„

Yes, as if they'd clicked the 'new tag/release' button, so goes to the 'create new tag / release' screen. Should be as simple as sending them back to the '?commit={guid guid guid}' page ...

justinclift commented 7 years ago

I'd be interested in looking at (like you've done for the 'deleete database?') how you do it, just to grasp the underlings of the code and what to do - the little things like that would be handy for me to chip in and help ( or hinder.... haha!)

Yep, no worries. What info format and level of detail do you want? :smile:

chrisjlocke commented 7 years ago

I'll have a look at your 'delete database' code, and if it makes sense, try and replicate.... if I struggle, I can yell loudly for some hand holding! ;)

justinclift commented 7 years ago

From a newbie point of view (which is why I've stuck it in here again) but are releases/branches/tags per database, or per commit?

They're per database. Hmmm, I've been thinking it'd be useful to put this in some picture friendly doc, but haven't yet gotten around to it. :wink:

justinclift commented 7 years ago

Just to point out, my code isn't exactly a model of fantastic Go code. It's more "workman like" than "craftsman like" (so far).

That being said, sure, have at it. :wink:

chrisjlocke commented 7 years ago

From watching some OiTube vids, there is only one way to write Go.

image

Unless you'ev found #2..... ;)

chrisjlocke commented 7 years ago

Newbie question, so I've filed it in here where it won't get laughed at.... ;)

I've a db with a number of commits and branches.

image

In DB4S, I've only got one commit.

image

Is this right? I can't access other commits or branches ?

justinclift commented 7 years ago

Yep, thus far DB4S doesn't yet understand branches, nor the commit history. It just sees the latest commit for the default branch.

@MKleusberg It should be fairly easy to add stuff to the DB4S end point providing that info if it'd be useful.

eg:

It's easy to provide the full tag and release list info too if useful.

Performance wise, all of the above is no issue. Branch, commit, tag, and release info is all stored in the single (same) database record. So it's trivial to grab any (or all) of those bits of info in just one database call. ๐Ÿ˜

justinclift commented 7 years ago

@chrisjlocke With the "Home isn't home" item above, should we just remove the leading slash altogether? That way, breadcrumb trails will look like this:

without_slash

... instead of this:

with_slash

justinclift commented 7 years ago

Hmmm, I'm going to remove those leading slashes and we can see how it goes. :smile:

justinclift commented 7 years ago

The db4s-beta website now has those leading slashes removed. Seems better. ๐Ÿ˜

justinclift commented 7 years ago

Just fixed the problem with spaces (and other chars) in download file names being converted to pluses (and others) in 37b2e668bc5a68cef4ed833e3fdc15d7b3c13bac.

Now live on the beta server. :smile:

chrisjlocke commented 7 years ago

Yes, that looks more esthetic. Nice. :)

justinclift commented 7 years ago

Just fixed the "'Email address can't be blank' - but it wasn't...." thing. Using that exact logic too. :smile:

eg if email == empty then use the suggested one

chrisjlocke commented 7 years ago

Excellent. Looking at the code, loggedInUser+".cert.pem", is there any 'limit' on creating a username? Again, was thinking is there anything to stop someone creating a username of 'hello+jim!!"ยฃ$', etc.... haven't tried that yet..... eg, they can create a usernsame which would create an illegal filename.

edited by justinclift

Sorry! ;)

justinclift commented 7 years ago

is there anything to stop someone creating a username of 'hello+jim!!"ยฃ$', etc....

Yep. Probably overly paranoid validation gets done at the moment, which likely needs relaxing to accept a broader range of characters. For example, it doesn't yet allow even commonly accented characters.

Fixing that to allow a better set of characters is definitely an important item. I'm suspecting it'll be a can of worms though, so have been putting it off in preference for other stuff. :smile:

chrisjlocke commented 7 years ago

As its only for filename generation, that would be dependant on OS, right? ie, a username is specified in the Auth0 signup, so whatever that authenticates/allows, must be good. Windows filenames are more strict than Linux ones, so if the user does create wacky!"'..;;;;;7& as a username, they won't be able to create the cert, which is just OS based. ie, it doesn't matter if its an invalid username as far as dbhub.io is concerned?

justinclift commented 7 years ago

Hmmm, yes and no.

Thinking about it, if the filename given to the browser contains wacky characters that the OS doesn't like... I'm not sure what the behaviour of the browser will be. Hopefully it just tell the user "fix this filename else you can't save it!" type of thing, but I really have no idea. Different browsers may even handle that differently.

With the auth0 signup part, not exactly. The username in Auth0 is different to the username in our system. That's because by using Auth0 a person could be signing in from Google, GitHub, LinkedIn (etc). Or if they're not wanting to use a social media sign in, then they create a specific account in our Auth0 hosted database (called "Test2DB" atm from memory). What that does is gives us a user-specific handle (eg github|12312312. That's not human friendly though, thus getting people to choose their own username. :smile:

Thus... we have our own validation rules for what's acceptable for usernames. Ideally we'd accept anything that that's valid character info (eg no control characters, SQL special characters), minus things like special words we reserve, and also minus some level of "bad words we don't like". That last one can be a bit grey area/dodgy though, so may be better to keep clear of for now (unsure).

chrisjlocke commented 7 years ago

if the filename given to the browser contains wacky characters that the OS doesn't like

Windows just throws up the standard 'Save As' dialog, with the filename pre-filled in.

image

(albeit that filename is valid)

If it was invalid, clicking 'Save' would throw up an error.

image

justinclift commented 7 years ago

Can the 'preferences' have a link to the preferences?

It turns out this isn't as easy as expected. At the moment our errorPage() function (used to display that message) sanitises all html/css/javascript (etc) in error messages. It's just in case someone manages to sneak some javascript or similar into a page variable, it won't be repeated back in the resulting error message. Doing otherwise could cause us XSS problems, which don't want.

We'll need to rewrite that errorPage() function anyway to be more user and admin friendly. But not just yet. So, it's a task for a later date. :wink: