8 Jun 2025 |
pveierland | Cool, will try my best to accommodate byte strings then :) | 00:36:44 |
| zitrone joined the room. | 01:02:47 |
pveierland | (Details in this crate were quite helpful to understand path encoding handling: https://docs.rs/gix-path/latest/gix_path/) | 02:00:45 |
emily | I wouldn't recommend supporting non-UTF-8 attrpaths in tooling. | 12:57:08 |
emily | you run into the "Makefile problem" (https://wiki.mercurial-scm.org/EncodingStrategy#The_.22makefile_problem.22) quickly – text has to be able to refer to paths | 12:57:37 |
emily | see https://docs.rs/camino/latest/camino/ for a perspective on this as applied to file paths | 12:58:00 |
emily | anyway, nix eval nixpkgs#é and nix eval nixpkgs#'"é"' both behave bizarrely (they interpret nixpkgs as a path for some reason), so I suspect ASCII is the only reliable thing | 12:59:00 |
pveierland | I agree, it would be way easier to just do a possibly lossy conversion of all attrpaths and paths to UTF8, and it would probably result in fewer bugs overall + less code and specialized parsers etc | 13:50:15 |
pveierland | Just trying to avoid losing any necessary representational ability | 13:51:09 |
pveierland | Then again, if a tool like git was rebuilt today maybe it would just insist UTF8 everywhere | 13:51:36 |
pveierland | I guess the issue for tools such as nix and git is that they need to work with such a broad set of environments so it might not be possible to make that assumption yet | 13:53:54 |
pveierland | Redacted or Malformed Event | 13:54:30 |
emily | Nix not doing Unicode properly is just historical reasons I think. | 15:04:07 |
emily | it's not like it makes it handle e.g. UTF-16 better, because it can't do NUL bytes either. | 15:04:20 |
dramforever | well, those should be url encoded, right? | 16:32:45 |
dramforever | i guess it also breaks with non-ascii separately some other way | 16:33:47 |
Las | John Ericsonwhat should I do to get 12668 merged, or has the equivalent work already been done? Haven’t been following development for a bit | 17:02:14 |
John Ericson | equivalent work has not been merged | 17:06:38 |
John Ericson | you can try doing a rebase | 17:06:46 |
John Ericson | and also let me try to find again the rebase I had done before | 17:06:59 |
John Ericson | Las: yeah l-as-goal-direct-io in my repo is a rebase that doesn't quite work of the first commit | 17:11:43 |
9 Jun 2025 |
| @trofi:matrix.org left the room. | 05:27:17 |
dramforever | i can't reproduce this on 2.28.3 | 05:38:22 |
dramforever | $ nix eval '.#è'
4
$ nix eval '.#测试'
3
$ cat flake.nix
{
outputs = { self }: {
"测试" = 3;
"è" = 4;
};
}
| 05:39:26 |
dramforever | oh wait does it have to be registry? | 05:39:30 |
dramforever | oh yeah that's odd. | 05:40:03 |
dramforever | * oh yeah that's odd... | 05:40:06 |
dramforever | so the problem seems to be confined to parsing? i suspect the fix will be easy | 05:41:25 |
dramforever | * so the problem seems to be confined to parsing flake urls? i suspect the fix will be easy | 05:41:33 |
dramforever | oh yeah this is so funny
$ nix registry add test path:$(pwd)
$ nix eval 'test#%C3%A8'
4
$ nix eval 'test#%E6%B5%8B%E8%AF%95'
3
| 05:48:51 |