-
Notifications
You must be signed in to change notification settings - Fork 41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Document and enforce what characters can be used in dataset names #497
Comments
A more complete list of things we should disallow:
In addition Windows seems to have some interesting ideas about file names; to prevent Windows checkouts from going awry perhaps we should also adhere to some/all of these:
|
Could just ban |
I'm +1 to disallowing certain characters that are likely to cause problems, but -1 to having an extra list of banned tokens due them not working as intended on certain OS's - that would mean the idiosyncrasies of that OS have now spread to another OS via kart. |
yeah, that's reasonable. So let's skip the handling of I think disallowing |
this one's kind of annoying to implement, since it depends on the repo - unlike the other rules which depend on nothing except the path you're supplying them. I'll skip it for now. |
TBC, we're talking dataset names/paths only here. Note that macOS filesystems are case-insensitive by default. NTFS is case-sensitive, but parts of the Win32 API aren't. I think for avoiding obvious & inevitable footguns we should very much try and help people not to do that. I don't see any particular need for using any of the reserved characters for Win32 ( Our primary goal with this is to help users avoid bad experiences for them and others — we will get a bug report when a repo doesn't work on a different OS, and blaming the OS isn't a helpful solution for the user (especially when it's not their repo). If we did this checking strictly at creation time then at least it's all in one place? |
one more restriction I discussed with @rcoup offline: we should only allow alphabet characters for the first character (no numerals or symbols). This will make it easier to support a wider variety of databases / working copies. |
It's currently possible to import a dataset with a colon (
:
) in its name.This breaks at least one current feature of kart:
kart diff
accepts filters in the formatDATASET[:PRIMARY_KEY]
; since string PKs can contain colons the parsing is ambiguousWe should specify that dataset names don't contain colons, and reject them during import if they do.
The text was updated successfully, but these errors were encountered: