Unfortunately, it's true, most toolchains are stuck in the past, and don't deal with non-ascii characters or even spaces very well. In fact, I just learned that spaces in .deskop files values could cause trouble after a long debugging.
But it's a shame.
In Europe, we do have a lot of non-ascii characters everywhere. Ubuntu puts a "Vidéo" and a "Téléchargements" directory in my $HOME because I'm french. If I were to use my name as my username I would have even more troubles.
I'm careful with not using special chars in names for work, but it feels like I'm a girl trying to not dress sexy in the wrong part of town: necessary, but I shouldn't have to do this, and it's definitely the others to blame.
All in all, I thank the Gods of encoding for Python 3 unicode handling. Having a scripting language that does the right thing out of the box is wonderful on this side of the pond.
"The right thing" for filesystem entries is transparently copy, do not evaluate. A file path is a mem-copied, length value sized block of identifier you don't ever mangle. If you must mangle it, touch only the necessary areas as directed. (E.G. join with os.pathsep and do not normalize anything).
Want to offer Unicode validation? Sure having that as an OPTION is fine. Forcing it means I can't rely on that tool to handle real world data which happens to not be valid but is still a valid file-system address.
One thing I've noticed is that ext, xfs, btrfs and zfs all explicitly store a length field alongside the filename. There's nothing inherent in the disk layout of these filesystems preventing them from supporting filenames with embedded slash and nul characters - those limitations are imposed by the kernel's VFS implementation. It would be nice to have a special version of open, exec etc. where one could specify a filepath as a length-prefixed array of length-prefixed strings.
ODBC (ISO 9075-3) got it right 30 years ago: all strings are accompanied by the length argument, which also accepts the sentinel value NTS, when you mean a null-terminated string.
- if you want to treat paths like unicode strings, you can. Which is great for simple scripts where you don't want to deal with complexity. And 99% of the time, it's enough with modern OSes.
- if you want to threat path as bags of raw bytes, you can. Which is necessary to transparently copy and do not evaluate, as you said, for covering edge cases.
- if you need to actually deal with those as strings but don't want to loose data for edge cases, so a mix of the 2 above, you can use surrogate escapes
Where does that filepath come from? A config file; are you going to do your text processing, and interaction, with other modules in byte[] arrays in Python 3+?
Python 2's unicode model was _closer_ to correct, the trivial coercion between byte[] and Unicode.
Conversion also shouldn't imply, force, or check Validation nor Normalization. Labeling a bytestream with an Encoding and validating / normalizing that encoding should be options. Operations on bytestreams with encoding related attributes should set them to either 'unknown' result or to a proper output type if they're aware the manipulations will still yield a valid encoding.
Normalization is more complex, since Unicode strings can be normalized in different ways, then combined, and still be a valid string but no longer uniformly normalized.
It's not only an awesome technical achievement, but it has also so much potential to be useful.
And yet, something at the back on my head is screaming:
WARNING!
I have the intuition that, on the long run, using more and more tools that are not on your own machine will create a dependency on systems big companies control. And something tells me we are going to pay for it in the end.
So I'll stay away.
Maybe I'm getting paranoid, but I don't regret not having ever created a Facebook account, or not getting on the 2010 hype train of magical SAAS services like Firebase that lock you in eventually.
This is my personal opinion. I don't imply in any way or form that my point of view is right. You can down-vote, call me names, or ignore what I am sharing. I don't care.
Since Apple CSAM attempt, something at the back of my head screamed: Regroup. React. Change. Now.
Two months after Apple's "postponing for better implementation": My company runs on Arch/Manjaro (over old MacBooks Pro without T chip, custom PC's, etc). There is no iPhone in sight - my colleagues/employees found personal alternatives. I use DeGoogled Android device for banking app and flip phone.
Designers are with powerful Linux boxes: Windows VM - mainly Figma (I don't like it, but this is production standard now) and Affinity Designer/Photo.
We use mainly Vim/Emacs/VSCodium/Sublime.
Vendor lock-in is inevitable, SaaS business logic is based on this premise. I don't care how cool it is, or how 'trendy', there is no way my company production code to be served as a "free petrol" for some monopolistic/"good intention" scheme which will feed AI advancements geared towards removing of skilled professionals.
I don't like SaaS apps direction at all.
We have powerful hardware now, there are proven ways of collaboration with FOSS, moving everything in the browser is utterly insane.
I cannot hide how I feel about the lack of critical thinking in designers and developers today.
They are always ready to jump on the bandwagon just to feel 'cool and important'.
Call me crazy, or paranoid. In 5 years time all will be transparent and obvious even for the most "optimistic" ones.
We are back at UNIX/VMS/mainframe timesharing infrastructure.
SaaS direction is the only way people have found out to extract money from open source tooling that devs don't want to pay for, it is either SaaS or hardware, so there you have it.
> We are back at UNIX/VMS/mainframe timesharing infrastructure.
It is worst. We are in the new times of "surveillance economy", "data hoarding", politically driven business decision making, 4th industrial revolution, real-time data driven "psyops" and "marketing", "AI advancements", you will own nothing and you will be happy.
I will gladly return to UNIX/VMS times with low connectivity, real human connections and minimal dark patterns in design and product implementation:)
It's already that way. It's immensely hard to "develop on an airplane / desert island". eg: even documentation is at best something like "dash" => https://kapeli.com/dash ... forget about anything more complicated than SQLite, and if you're lucky docker-compose for occasionally connected use.
My experience? Chromebook / Crouton, usually offline with occasional network access. I ended up leaning hard towards SPA's + javascript, with most of the documentation being "legit" available. (JS, HTML, CSS, DOM, etc.) ...occasionally researching + pulling in libraries on occasion.
This is running on your machine though. The browser downloads vscode as a SPA-style thing, and runs the editor in the browser sandbox, and can edit local files/directories.
Sure. And the google map api is free to use, you can send tweet using sms, facebook doesn't show ads and web services never change policies once they get enough users.
Good thing it's running on your machine and you can see and control when it updates.
My way to work around this is to make a zipapp that contains several files, hence the entry point can do the checking and import another file that contains the code. But since its a zipapp, it behaves like a single file script: https://docs.python.org/3/library/zipapp.html
Yes, by paying for things and people. Because that's more valuable than paying taxes.
However, that only works if one's willing to forego paying shareholders dividends (which are paid out of net). Lots of people are not willing to do that.
> Was that paragraph meant to be clickable or extendable?
The next four sections expand on it: see what apps are using the mic and camera, option to give apps only approximate location data, app permissions dashboard, and the local computation for some data.
True, though one may turn that around to say Cue's scope is too large while Jsonnet's is more "pure" while still enabling the larger scope.
Schema that describes data is itself just data and Jsonnet can describe both. While the various Jsonnet compilers do not "know" about any specific meta-schema in which to express schema nor of course any way to apply that schema to data for validation, one can create such systems with Jsonnet as the language and its compilers as a component.
True, CUE has quite the inspirational scope right in the name. It is actually what draws me to the language. I also like the theoretical foundations in being turing-incomplete. Functions and computation make configuration harder to understand and reason about.
I mostly generate yaml and json now that I've been using CUE. The cool thing about CUE is that it's really doing both at the same time. Types and values are just points along a spectrum of specificity, going from types to constraints to concrete values.
I found CUE because I needed something better than Yaml for generating code, or declarative application code. (https://github.com/hofstadter-io/hof). It was similar to when I found Go and replaced a bunch of C++. I gained way more functionality in my application while shedding more than 50% of my LOC.