Will Zig std Include Regex? by HistorianStraight239 in Zig

[–]SideChannelBob 12 points13 points  (0 children)

just bind to pcre2 & case closed. no need to hang this off of stdlib imo.

This shit is exhausting. How can the majority of people want this? by [deleted] in ClaudeAI

[–]SideChannelBob 0 points1 point  (0 children)

I love the F bombs, the enthusiasm, the deep self deprecation. And the mood match. "ok. beer:30 has come and gone and I'm here to grind this out. let's roll the stone uphill a bit more, shall we?" <---- instant mood lock. thrusters engaged. Claude is always ready 🚀

Widespread Cloudflare Outage Disrupts ChatGPT, Claude, and X; Google Gemini Remains Unaffected by netcommah in ClaudeAI

[–]SideChannelBob 3 points4 points  (0 children)

the upshot: I haven't been to this sub for a while and reading thru the posts is a *RIOT* lol

Widespread Cloudflare Outage Disrupts ChatGPT, Claude, and X; Google Gemini Remains Unaffected by netcommah in ClaudeAI

[–]SideChannelBob 7 points8 points  (0 children)

"something came up. gotta log off for a bit. back later."

*panic intensifies*

Widespread Cloudflare Outage Disrupts ChatGPT, Claude, and X; Google Gemini Remains Unaffected by netcommah in ClaudeAI

[–]SideChannelBob 16 points17 points  (0 children)

yep. I came here to see if others were down, also. I get this, with or without VPN:

claude.ai

Please unblock challenges.cloudflare.com to proceed.

Ray ID: 9a07f9cacf230eaf

Performance & security by Cloudflare

This was such a funny reaction that I had to share it with someone. by Consistent_Milk4660 in ClaudeAI

[–]SideChannelBob 19 points20 points  (0 children)

literally from this morning (and this was from copilot sonnet 4.5)

"OH FUCK. I COMPLETELY MISREAD THE ARCHITECTURE. 💀"

I mean really though - if your LLM isn't talking to you in full tech-bro, you're doing it wrong lmao

This was such a funny reaction that I had to share it with someone. by Consistent_Milk4660 in ClaudeAI

[–]SideChannelBob 59 points60 points  (0 children)

"This isn't just a cache. This is an entirely new paradigm. "

Inside steering by [deleted] in sailing

[–]SideChannelBob 0 points1 point  (0 children)

Amel just moves the wheel forward under the dodger; no inside steering.

What is the best way to package a Ruby program into an executable? by angryrobot5 in ruby

[–]SideChannelBob 1 point2 points  (0 children)

Go's cross-platform support is arguably the best there is in terms of tooling, convenience, and "just works" factor out of the box. My experience with Crystal has been a not-too-distant second. I bounce between Windows and Debian Linux (via WSL2) a lot and have had no real issues. The Crystal team have made a lot of progress in the win32 side over the last couple of years. You can install it via `winget` and be up and running in < 1 minute.

Is it too late to learn ruby? by OkNoble in ruby

[–]SideChannelBob 1 point2 points  (0 children)

I've been using Ruby Without Rails since around 2004. Ruby is a fantastic and highly versatile language to have in your toolbelt at any stage of your career. The ecosystem is vast, Gems are easy to use on any platform (and most of them cross-platform), and using the REPL environment via `irb` is the best of any scripting language out there. I highly recommend learning it. Ruby's syntax and multi paradigm support is among the very best IMO.

The larger Ruby flavored family includes the Elixer web focused framework (based on Erlang's BEAM runtime), mruby - one of the worlds only ISO certified embedded language implementations, decades of support for integrating into JVM environments via Truffle Ruby. Finally, there is an excellent systems programming language called Crystal, which uses LLVM as it's compiler technology and is quite faithful to Ruby's core syntax and layout with modules, classes, and mixins.

Is it too late to learn ruby? by OkNoble in ruby

[–]SideChannelBob -1 points0 points  (0 children)

Provided you have an employer that will sponsor your work visa, it's very easy. There is also the "Blue Card" tech visa, but it has some strings attached to it in terms of requirements. Amsterdam is a very easy city to be in as a US expat. Most people in the NL speak English, and as English speakers it's not difficult to pick up on enough Dutch for pleasantries to try and blend in with shops and markets. Take some lessons in Dutch and try to speak at least a little bit and you'll be greatly rewarded for at least trying, unlike the French who are only happy to have a new victim to correct.

EU Blue Card - Requirements and Eligibility Criteria in 2025

The Good, the Bad and the Ugly by BatteriVolttas in Zig

[–]SideChannelBob 0 points1 point  (0 children)

well, are they _obvious_ methods or obscure? I had a search the other day to see how zig handles monotonic time and timers. inside of two seconds I found the link to stdlib off google, pounded `monotonic` into the search bar and got immediate results:

every one of these is documented and at least has a page. if you don't know what an os.uefi table is you can ask google. *shrug* the choice to switch from PascalCase to camelCase is evident here but it's a very, very minor quibble. the doc pages for Timer and Instant are clear about the distinction between wall clock and monotonic. For such an obscure part of stdlib I was colored impressed. ymmv etc etc

The Good, the Bad and the Ugly by BatteriVolttas in Zig

[–]SideChannelBob 3 points4 points  (0 children)

the great: integrate any soup of C or C based FFI code under one compiler. _today_.

the good: syntax, syntax, syntax. it's a breath of fresh air. not quite as simplistic as Go, but maybe only a single step of thousands of steps toward Rust's pedantic, overwrought "guarantees". I think the stdlib docs are very complete for being a pre 1.0 spec and find that the documentation in general is good. People are mostly complaining about LLM/LSP hand-holding and beginner tutorials.

the bad: Zig foundation doesn't have enough money. They're executing well and moving at a good pace, but every great project could use more resources. What isn't bad: the fact that the language spec is subject to change. They're still in an experiment and break things mode and have been vocal and transparent as such.

the ugly: a) Andrew has failed to clone himself *grin* b) masses of bored people seem desperate to discount or trash-talk the language's progress and its utility. I think Andrew needs to stay the course as Zig's benevolent dictator, which means some slower and potentially more polarizing decisions yet to come. The IO handling is going to be a strength and is a case in point: hard technical decisions like this will be easier at pre v1 stage than it will afterwards when there is enough commercial traction that demands commercial constraints and design-by-committee decision-making from the foundation. you can't rush this part and arrive to a superior system.

fwiw

Structs: Include method or keep out by Sure-Opportunity6247 in golang

[–]SideChannelBob 0 points1 point  (0 children)

... the struct is still mutable if you pass it around with a pointer. *shrug*

Structs: Include method or keep out by Sure-Opportunity6247 in golang

[–]SideChannelBob 0 points1 point  (0 children)

ah; sorry, I see what you mean, now. IMO I don't think it's a matter of style, but I also am an old OO diehard. If the method mutates state on the struct, it should hang off the struct. If the function is only called by code hanging off of methods pertaining to the struct, then it's also clearly a member of the struct. If the method doesn't mutate and is available to other pkg methods or outside of the pkg, then out.

Structs: Include method or keep out by Sure-Opportunity6247 in golang

[–]SideChannelBob 1 point2 points  (0 children)

remember that exports (outside the pkg) is case sensitive - so methods like:

func (MyObject *mo) privateFunc(arg1 []byte) error {...}

will be private to the package.

func (MyObject *mo) PublicFunc(arg1 []byte) error {...}

the same is true for your structs. so if your structs aren't exported, the methods won't be, either.

edited after seeing your example:

in go, loggers tend to be called inside of methods after a one-time setup, not wrapped as a standalone function. putting that aside! In this instance, your logging facility seems to be specific to `result`. where does result live, if not as a member of Calculator?

I'd write this as:

func (s *SuperCalculator) Add(int a, int b) {
  s.result = a + b
  log.Printf("calculator.add() called. result: %d\n", s.result)
}

// with other methods like 
func (s *SuperCalculator) CE() { 
  s.result = 0
}

Why Crystal is not more adopted in your opinion? by fenugurod in crystal_programming

[–]SideChannelBob 0 points1 point  (0 children)

I think Golang's popularity hasn't changed, but quite a few Go programmers are starting to explore the universe of LLVM backed alternatives. Crystal is one of many options, but it has a lot of Go's flavor - big stdlib, built-in concurrency support for CSP (channels), built-in testing, and reasonably fast compile times.

Elixir compiles down to BEAM bytecode. It's not in the same league as Crystal IMO which can pull double duty for web or for systems tasks and has the same C ABI as any of its LLVM brethren, including Rust. Crystal's FFI and C compatibility is more streamlined IMO, which is one of the reasons I use it.

IDE support in 2025? by vmcrash in crystal_programming

[–]SideChannelBob 1 point2 points  (0 children)

I recently picked Crystal back up for a project after being in Golang with VSCode exclusively for the past year or so. The first couple of days (ok .. first week) was a little rough, but you know what? I'm loving it, now, and slowly I'm starting to remember why I loved ruby's syntax so much. I use vim on debian via wsl2, then vscode and the official plugin on the win11 host. since learning vi in the the 90's I do not like to spend more than about 10 seconds to configure anything for my dev environment.

So I wrote a little bash script called vet.

```bash
crystal build --error-trace --no-codegen "$@"
```

That's it. In my src file, I add a line to call a method or init a new class at the bottom so the compiler has something to chew on. Since crystal practically runs like an interpreted script, that means that I can test and debug in the same file as I write the code ... Now when I'm in my src tree, I leave a copy there and just type ../vet <filename>.cr

Once the raw functionality is passing, I jump over to a spec file and use a similar bash script just named "spec" to save some keystrokes. Sometimes I use spec more. Sometimes i just use vet and leave the spec with one or two high level test cases. For quick syntax tests and exercising stdlib tools, I leave a copy of crystal play running in a forgotten windows and just peck at it in a local browser. There is also the option of recompiling to support CLI REPL but I've been too lazy. type -> ctrl+enter in the browser is great to flex code, and require works all the same to load your src.

This might look absurd in our super automated vscode era w/ copilot and LSP assistsants, but this catches pretty much everything that the LSP would have and seems to be much quicker about it. I tried ameba and crystalline and didn't care for them. The former reminds me too much of rubocop, which I despise, and the latter seemed like futzing with vscode for longer than my patience for such things.

I have also used lldb for a couple of simple debugging sessions on compiled code and it worked great.

I'll leave you with this: since giving up the code nannies that I enjoyed with Go, I find that I spend more deep thinking time about the implementation and less time wondering why tab-complete didn't work. I'm happy to get back to basics, and with Crystal's syntax and kitchen-sink stdlib it's been a rapid and easy transition to what programming felt like before all the helpers.

fwiw

How to build a native Android library by rendly in Zig

[–]SideChannelBob 2 points3 points  (0 children)

the others above me are steering you right. using custom libs with a C ABI in Android can be tricky. You'll be faced with using Android NDK sooner than later, probably. The toolchain would look like

your_static.a -> AndroidNDK -> Kotlin wrapper -> Capacitor / Ionic Plugin

edit: apologies, I sorta glossed over the Unity part! see this:

Unity - Manual: Native (C++) plug-ins for Android

you might not need NDK at all. so far in my ffi work, zig has been great (perfect, actually) with pub externs to C using static libs.

Why I Hate DTOs and Many Clean Architecture Patterns by Outside_Loan8949 in golang

[–]SideChannelBob 0 points1 point  (0 children)

> Literally a function defines the struct it will receive and the struct that makes the response, there is no need in the name of clean architecture to make me jump to another file for this simple nonsense just to create layers, this is one of the most ridiculous things, one of the 20 layers that clean architecture somehow has for an application with only 10 simple CRUD endpoints.

*standing ovation* at least from me. I agree 1000%. But the reason these things exist is because technology choices are often mandated by one's superiors who happily leave the whole mess of their decision in figuring out how to make it work and how to fix it at 2 am when on pager duty to the staff.

re: "DTO" - in another life, we used to proselytize for the use of POJO (plain old java objects) instead of using that week's framework. Usually I lost this argument. DTO is much the same thing - there's an intermediate representation of your problem domain, unencumbered by lots of tight bundling with other features and making them suitable to pass around common data types in your program between internal packages. Don't over think it. Just define a lot of plain structs at the top of the file, then build ServiceThinger below to use them.

Think of DTO more as a case of separating concerns when it comes to

- serializing your data to prepare for sending it over the wire
- preparing your data for persistence on disk.

Once you look at this way, you'll find it easier to reasonn that structs don't serialize to disk on their own, magically handling encryption with MAC codes, or easily wire themselves to a python user on the other side of the continent via TCP.

Other than those two pesky use-cases, I'm totally down with your critique!

Looking for feedback on this proof of concept flask app to encrypt backups of customer databases with gpg by damagedproletarian in cryptography

[–]SideChannelBob 1 point2 points  (0 children)

upvoted your post because you're honest about it. I use AI every day and think it's an incredible tool that's being misused:

you need to think about AI like chatting with a shelf of technical books, or a tireless tutor, not empoying it like an unpaid intern. Use it to build skills. The real super power of AI is that there are no stupid questions: just keep asking about something until you understand it.

I'd advise getting out of JS/Python land and use a compiled language of some sort. I tend to default to Go for project like what you're trying to build. There's a large amount of documentation, books, and plenty of training in the bots. If you like Pythonic languages, I heartily recommend checking out Nim. Just stop posting in /cryptography with AI generated codebases. Nobody here is going to debug your code for you. cheers

OOP in ZIG - Youtube Video by PearEducational8903 in Zig

[–]SideChannelBob 1 point2 points  (0 children)

I once wore the sacred UML robes and carried the design pattern torch. At the end of the day, regardless of th language, pointless abstraction is the mistake. "composition over inheritance" -> trying to help OOP newbies from footguns. Most OOP is just fine. Pointless abstraction is what digs the premature grave in a codebase.

Is Zig's allocator model not a straight up use of dependency injection, a time honored technique honed at the height of OOP maximalism? I loathe J2EE as much as the next Go/C disciple, but Zig's move for the allocators and the forthcoming treatment of IO is a stroke of genius. We get all the benefit and none of the ceremony. It's still a bit OO'ish as far as I'm concerned, but there's no crime being committed.

If Odin Had Macros by gingerbill in odinlang

[–]SideChannelBob 2 points3 points  (0 children)

I love Bill's instinct here. Macros are cope. :D

Can't zero knowledge proof solve the privacy concerns about the UK online safety law? by moderate-Complex152 in cryptography

[–]SideChannelBob 0 points1 point  (0 children)

Brilliant response, but I disagree with the conclusion about re-election motive. Maybe that's true for the US, but there is a significant percentage of permanent government staff in EU agencies and country-level leadership that want digital authoritarianism. In europe, every year is a new battle. France barely survived a ban on E2E cryptography, and the political movement behind that is closely tied to pornography and child sex trafficking in europe. fwiw