jeffhykin

joined 2 years ago
[–] [email protected] 1 points 2 years ago

Its easy for me to say "just start writing JSON in the yaml. It doesn't get more simple than JSON", but actually I do think there's a small point with the unquoted strings.

Back before I knew programming, I was trying to change grammar settings sublime 2, which uses yaml. I had no idea what yaml was. The default setting values used unquoted strings fot regex. I knew PCRE regex and escapes, but suddenly they didnt work, and when I tried to match a single quote inside of regex that also didn't work. I didn't know I was editing yaml file (it had a .tmLanguage extension). Even worse, if I remeber correctly, unparsable settings just silently fail. Not only did I have no errors to google, I didn't have any reason to believe the escapes were the cause of the problem (they worked in the command line). Sometimes I edited the regex and it was fine, and other times it just seemed to break. I didn't learn about quoting in YAML until years later.

For me that was an unfortuate combination, which was exacerbated by yaml unquoted weirdness. But when you're talking about "did you read the spec" that's a whole other story. .nan for nan, tabs vs spaces, unquted string weirdness, etc should just be one error message+google away. I think they're a small hiccups with what is overall a great format.

[–] [email protected] 69 points 2 years ago* (last edited 2 years ago) (1 children)

For context, Tea (the cli tool) was created by the author of homebrew. But for some reason he changed the name to pkgx and made tea into the crypto thing: From the creator of Homebrew, Tea raises $8.9M to build a protocol that helps open source developers get paid

He's probably interested in blocking these kinds of PR's.

[–] [email protected] 44 points 2 years ago* (last edited 2 years ago) (7 children)

I have read the 1.2 spec (I'm trying to make a round trip parser for JS, and I do maintainance on a fork of the rumel yaml python package). I actually think its very well thought out, with things I hadn't considered like future extensibility, streaming applications, and data-corruption detection.

The diagrams, color coding, and less-formailty of the spec was much appreciated. Especially compared to something like the ECMA Script spec, which reads like a math textbook had a child with a legal document.

I'm not saying YAML is perfect; round trip (the thing I'm working on) is nearly impossible because it wasn't a design goal. It has a few too many features (I've never seen a declaration in the wild), but it does a good job at accomplishing the creators goals, and the additional features basically only slow down parser-implementers like me. I often pick it because of the tag support, which I've struggled to find an equivalent for in other serialization languages. I use anchors in recursive data structures, and complex keys for serializing complex data structures (not human readable). The "document end" marker has been nice when I'm worried about detecting partial-writes. And the merge key is nice for config files.

The application/perspective matters. Yaml might be bad for you but its not bad for everyone.

[–] [email protected] 2 points 2 years ago* (last edited 2 years ago)

(After seeing your edit) to be fair, there are a ton of overblown hype articles that are actually built on nothing. The opposite side of skepticism (jumping onto the outrage bandwagon) is worse and more common than being skeptical. Its a shame things are not easier to verify.

[–] [email protected] 5 points 2 years ago* (last edited 1 year ago) (2 children)

Also

I've exhausted every EXE-generating option I could find [for python]

Unfortunately software is one giant mess right now. You'd think things like compiling to an EXE for python would be standard. They're not. One day, maybe 15 years from now, we will have Nix be user friendly, a single line installer for everything, and have it all "just work". But until then, almost everything is hacked together.

Overview of (basically) all GUI systems

I believe Flutter, React Native, and Android studio are the only major ones I don't have experience with.

EDIT! (2024-4-30) .NET Avalonia seems like a great modern option that I have not gotten to try. Its C# and fully cross platform. It could be a real game changer compared to the options I've listed below

  • Yes as far as I know theres no good exe maker for python. Python without dependencies (or async) is great, a nice little scripting lang for prototyping or data analysis. Python with dependencies is terrible, truly awful for packaged user-applications.
  • C++ / C are and effectively will always be miserable IMO. You'll basically never be able to automate it without nix. Make, cmake, autoconf, pkg-tools, ant, etc they're all a mess. For example, biggest blocker to python packaging is that many python packages are wrappers around C/C++ packages. The most annoying thing about one of the tools I'm about to mention (electron) are the dependencies that secretely use C++.
  • The most modern, consistent, and cross platform graphical systems right now are Electron and Tauri, which are literally browsers with URL bar/buttons removed. Electron is what Discord, Spotify, and VS Code use. Its bulky but theres a lot of support/tutorials. Tauri is the new, faster/cleaner kid on the block and uses the Rust language, which has good dependency management. But Tauri doesn't have the tutorials or ecosystem yet. Also Rust is a very hard language. For both you'll need to learn Javascript/HTML/CSS, which is probably good. But you'll also need the terrible npm ecosystem, and get introduced to javascript frameworks which seem great until theyre not. That said, basically every cross platform not-browser GUI I know of (JavaFX, QT, TCL/TK, WxWidgets, FLTK) has exactly the miserable experience you're getting; lots of dependency hedaches, and weird graphical differences between operating systems. Also that list is in order, with FLTK being untouchable garbage, and JavaFX being the least-bad in my experience.
  • Even if you're okay with using a broswer, (which solves lots of dependency/setup problems, and is the most useful/flexible UI system I've used) it still has stupid API problems because HTML was originally made to display documents (like microsoft word documents). It wasn't meant to be a full blown UI system; it just became that over time. Stuff like styles and positioning in HTML has edgecases, like "fixed" meaning absolute and "absolute" actually meanting "relative to parent" and "relative" meaning "relative to where the element would normally be".
  • Unity game dev (uses C#, which is similar to Java, but better IMO) might actually be worth looking into for your case. First check the unity API's for your images and GPS tasks. The good news is they support packaging up applications for every OS. The bad news is you can't automate the setup because its proprietary. The (very good) open source alternative is Godot.
  • The final alternative is, just don't go cross platform. This is the only not-mess, not hacky, intentionally-designed toolset approach I know of. MacOS has Swift and XCode, Microsoft has Visual Studio and C#. Neither are great but they're both the "this is how we expect you to do it" approches. You might be able to adapt these to other platforms (swift has been gaining some cross platform support and the .net runtime for C# can be cross platform).

My perfect setup would be Tauri (with all security disabled), with Deno accessible on the front end, all installed/setup by Nix. But alas, that doesnt exist yet. Even with +3 years of nix experience I can't even get Tauri running in Nix.

[–] [email protected] 3 points 2 years ago* (last edited 2 years ago)

I'd like directions on how to set up a software project with dependencies, so that future contributors can pitch in with the least amount of set-up required when they clone the repo

Unforunately that kind of task, with our current tools, is not a junior level task. I have worked on automating project setups for almost a decade; creating a single command that is cross platform install of all dependencies, project ENV setup, and in a way that doesn't break the users existing system(s), or causes the project to bitrot. The only real way at the moment is through Nix (nixpkgs), which is unfortunate because Nix is very difficult to setup and use. If you start a small project in nix its not too bad, but adapting an existing project often is, especially anything with graphical tooling.

I made Deno gulliotine to help with first step of cross-platform setup, but once the setup begins to install packages/languages it all needs to be done with nix to be reliable.

Also FLTK is miserable. I'm not a huge fan of QT, but it is at least definitively better than FLTK. Wx Python is also miserable, avoid it like the plague.

[–] [email protected] 92 points 2 years ago* (last edited 2 years ago) (1 children)

What really bothers me is the "measuring foot traffic". I already refuse to use vending-machines because of the pricing and unhealthyness, but you're telling me I need to make GDPR takedown requests just for walking to class?

[–] [email protected] 274 points 2 years ago* (last edited 2 years ago) (36 children)

It gets worse :/

I looked up the brand (Invenda). Their PDF includes "using AI", "measuring foot traffic", and gathering "gender/age/etc" e.g. facial recognition to estimate a persons age and gender

And in terms of "stored locally" this is straight from their website

The machine comes with a “brain” – Invenda OS – and is connected to the Invenda Cloud, which allows you to manage it remotely and gather valuable environmental, consumer and transactional data. The device can be branded according to your requirements to further enhance your brand presence.

The marketing also so fricken backwards that it reads like satire:

For a consumer, there’s no greater comfort than shopping pressure-free. Invenda Wallet allows consumers to browse, select and pay for products leisurely and privately 🤦‍♂️

[–] [email protected] 9 points 2 years ago (2 children)
[–] [email protected] 17 points 2 years ago* (last edited 2 years ago)

Its not really local only either, the cameras exist for the point of data harvesting, just look at their marketing. They only mean they're not streaming video to a server for recognition. The after-recognition data is still sent to a server https://www.invendagroup.com/vending-machines

[–] [email protected] 48 points 2 years ago* (last edited 2 years ago) (1 children)

Go to the vendors website, and not only see hole for yourself, but look at them claiming to use AI to detect demographics.

PDF Link: https://a.storyblok.com/f/184550/x/e7435c019e/brochure-svm_generic-dark-netflix-ui.pdf

Their website: https://www.invendagroup.com/vending-machines

Here's my own screenshots in case the vendor takes their pdf down from bad press.

Hole: https://photos.app.goo.gl/rTk8fUWynmXgw7Zc6

AI Features: https://photos.app.goo.gl/RiF1Phrroj65tMdd7

view more: ‹ prev next ›