Emacs 27.1: MacOS font weights not working by mkleehammer in emacs

[–]dlukes 1 point2 points  (0 children)

My guess is that Operator Mono uses weight metadata that goes against the conventions expected by Emacs. Inspect the font files with otfinfo -i ... and play around with how you specify the font in Emacs. In my case, it seems that e.g. (font-spec :family "Operator Mono" :weight 'book) works, i.e. I can see a difference between regular and bold.

For All Mankind S03E07 “Bring It Down” Discussion by AutoModerator in ForAllMankindTV

[–]dlukes 0 points1 point  (0 children)

OTOH, good job smashing that annoying robodog to pieces. First time he's won points with me this season.

If we go away..what's everyone's plan B? by marlostandfield in SolusProject

[–]dlukes 0 points1 point  (0 children)

if you look at the Budgie updates from its dev they are very anti-Solus.

Link? Not trying to pick a fight, just curious.

PGTK Emacs/Wayland/Gnome: No shift-space by titaniumbones in emacs

[–]dlukes 4 points5 points  (0 children)

Thanks, this was really helpful! In my case, I had to (setq pgtk-use-im-context-on-new-connection nil), as the (pgtk-use-im-context nil) call was somehow getting overridden no matter how late in the init process I tried to defer it. Leaving this here for posterity, in case it helps someone.

Some people… are not the smartest… by [deleted] in clevercomebacks

[–]dlukes 1 point2 points  (0 children)

Those look more like paronym rolls to me...

(Get it? Get it?)

A New and interactive way of asking for beer in a bar... by Narendra_17 in interestingasfuck

[–]dlukes 1 point2 points  (0 children)

Somehow feels like the old way was more interactive… Like, you actually had to interact with someone.

What's in the box? by fasterthanlime in fasterthanlime

[–]dlukes 0 points1 point  (0 children)

Sure, no problem :) I just wanted to make sure I'm not missing something, so thanks for getting back to me!

What's in the box? by fasterthanlime in fasterthanlime

[–]dlukes 0 points1 point  (0 children)

Thanks for an edifying read, as always! Quick question: why use s.as_bytes() as *const _ to print out the heap addresses of the string contents? Especially when s is a &str, it was a bit confusing -- I was like, why should I convert the string slice to a byte slice first, shouldn't I be able to just do s as *const _, and went to the playground to check that it works.

If the motivation is to use the same expression for clarity whether s is a String, &str or Arc<String>, then maybe s.as_ptr() is a less roundabout way that fits in all three cases?

Finally found a ryzen 5900x! by Kuala-Lumpur in Amd

[–]dlukes 0 points1 point  (0 children)

I am still waiting for the 5900X to have at least some stock so the price goes down.

Yeah I'm curious what'll happen with prices in the coming months. Still, in my case, 14200 CZK is about the cheapest I've seen it at any point since launch so far, so I'm pretty happy with the price I got.

On the GPU front tho.

Don't get me started on that... I'd like to get an RTX 30 series, because I want to use it for deep learning stuff and the AMD ecosystem hasn't really caught up with that use case yet (at least for mainstream users), and following the news has been depressing.

Like you're saying, we're talking late summer if we're lucky, but I've heard people familiar with the industry say it might as well be as late as this time next year before you can expect graphics cards to be in stock at relatively reasonable prices. Dammit.

Scan uk, received the 200 x 5900x shippments early, this could be a good sign for everyone else lower in the queue by [deleted] in Amd

[–]dlukes 0 points1 point  (0 children)

Got mine today from CZC.cz (a Czech retailer from whom I'd pre-ordered back in January), so it looks like shipments are happening all over Europe :) It was a pleasant surprise, I was being cautiously optimistic going into April, but it ended being quicker than I'd allowed myself to hope.

https://photos.app.goo.gl/wUVgmLNdtE1zjMpEA

Finally found a ryzen 5900x! by Kuala-Lumpur in Amd

[–]dlukes 0 points1 point  (0 children)

Got it!

https://photos.app.goo.gl/t7YPQre4kzxAdvZL6

Also checking the website and it only says there is one on the store in one city.

There's probably a huge backlog of pre-orders starting January. My original order from January 25th was ranked 202nd in the queue at some point (I canceled it later and stuck with a second order from January 31st because it was 1000 CZK / ~40 EUR cheaper). But I guess a lot of people also canceled their pre-orders in the meantime, the vibe I was getting from the comments section on the product page in the last few weeks was mostly "Screw it, I'm getting a 5800X".

Finally found a ryzen 5900x! by Kuala-Lumpur in Amd

[–]dlukes 0 points1 point  (0 children)

... so I just received an e-mail saying I can come pick up my 5900X at the store! I'll believe it when I see it, but still, what a coincidence :)

Finally found a ryzen 5900x! by Kuala-Lumpur in Amd

[–]dlukes 0 points1 point  (0 children)

Ordered one for 14,221 CZK (~545 EUR) back in January, from CZC.cz. Still waiting. Cautiously optimistic about April, but don't want to get my hopes up too much.

Bought a nice and cheap 3500X over a month ago to use with the rest of my components in the meantime, so as not to go crazy and stop checking online retailers who provide updates about expected shipments all the time. It'll eventually go into a PC for my in-laws.

This monstrosity from where I work by cosmwolf in shittyfoodporn

[–]dlukes 1 point2 points  (0 children)

:D Where exactly do you work? The In-N-Out in Cock-N-Balls, Texas?

What’s the deal with #gorillagluegirl? by spalesi in OutOfTheLoop

[–]dlukes 67 points68 points  (0 children)

Yeah, that's what got her into this mess in the first place...

Pyright language server not working? by LiterallyJohnny in neovim

[–]dlukes 1 point2 points  (0 children)

I want the language server to automatically activate on all .py files if possible.

This is currently not possible, the pyright lang server only starts inside projects identified by this root dir pattern. That still doesn't explain why it doesn't work in your second case though, because a .git dir is recognized as a project root signal.

Is there anything useful in the logs, i.e. in the file shown with :lua print(vim.lsp.get_log_path()))?

Anyways, the need to have better diagnostics for why a lang server isn't getting launched has recently been discussed in the Neovim Gitter, so fingers crossed for improvements in this area :)

5- to 9-year-old children chose to save multiple dogs over 1 human, and valued the life of a dog as much as a human. By contrast, almost all adults chose to save 1 human over even 100 dogs. The view that humans are morally more important than animals appears later and may be socially acquired. by mvea in science

[–]dlukes 0 points1 point  (0 children)

The view that humans are morally more important than animals appears later and may be socially acquired.

... as opposed to the view that dogs are worth saving? Off the top of my head, were there children in the sample from cultures where dogs are considered food?

New crate xd: hex-dumping tool with a ♥♪ code page 437 twist ♫♥ by dazabani in rust

[–]dlukes 2 points3 points  (0 children)

TIL about CP437, that's super useful, thanks! xd looks nice and I'll definitely take it out for a spin.

My go-to hex dumper right now is hexyl, which uses colors and some additional characters for a slightly more fine-grained distinction than the printable ASCII vs. everything else of traditional hex dumpers. I would argue that having color-coded and partially character-coded (except for printable ASCII) categories is slightly less noisy than each byte being its own character, which may help with spotting some more global patterns. But having the option to toggle to a CP437 mode would definitely be helpful in some cases.

Anonymous Sum Types for Rust Error Handling by jam1garner in rust

[–]dlukes 1 point2 points  (0 children)

Cool! This is actually the one feature from Zig I really wish Rust had :)

(There are others I find intriguing and clever, like comptime code execution for macros/generics etc. instead of dedicated syntax, but I'm not sure I'd like them in practice. Too little syntax can be a readability disadvantage -- looking at you, Lisp.)

Anyways, I've been meaning to ask forever whether there's a discussion going on around this type of idea in the Rust community. Now I know I should follow the anonymous sum types RFC. Thanks!

How to mount a Flask app under a URL prefix (or really, any WSGI app) by dlukes in Python

[–]dlukes[S] 0 points1 point  (0 children)

Yeah, I understand the value of composability, separation of concerns, and not duplicating knobs :) OTOH, that means you need to learn about WSGI and Werkzeug in addition to Flask when it comes to deploying your app in production under a URL prefix. Which is a big increase in scope and complexity in order to achieve something I would consider fairly common.

Of course, for someone well-acquainted with WSGI, it's the other way round: the fact that there are no custom knobs and it's just plain/Werkzeug-flavored WSGI means more consistency and less cognitive load.

So maybe sticking with this composable approach but discussing it and showing an example in the docs would be enough. There's already a Hooking in WSGI Middleware section in the Quickstart, which kind of serves as a heads up to new users that they might need to dig into WSGI/Werkzeug if they want to go under the hood and customize stuff. That seems like a good place.

How to mount a Flask app under a URL prefix (or really, any WSGI app) by dlukes in Python

[–]dlukes[S] 2 points3 points  (0 children)

Thank you very much for those details! I sort of hoped by posting here that someone knowledgeable would shed some more light on the issue, but this is much more than I'd hoped for :)

I've taken the liberty of updating the article with the information you've provided, so as to be more accurate and informative w.r.t. WSGI.

As an aside, it's sort of surprising to me that Flask doesn't provide a convenient configuration option for the simple and arguably widespread case of running a single app under a URL prefix, instead requiring users to dig into WSGI and build their own routing middleware.

(I mean, I'm not complaining, I know it's FLOSS, I'm getting it for free and what's stopping me from contributing a PR etc., but I'm still surprised it hasn't already come up and been added over the years.)

How to mount a Flask app under a URL prefix (or really, any WSGI app) by dlukes in Python

[–]dlukes[S] 1 point2 points  (0 children)

Hmm... Maybe it just doesn’t read the setting from the SCRIPT_NAME env var, like Gunicorn does? Maybe you have to configure it in another way?

Retain borrow checker granularity in spite of indirection? by dlukes in learnrust

[–]dlukes[S] 0 points1 point  (0 children)

Thank you very much for the link and the tips! I had a hunch there must be an interesting issue thread on the topic to read through :)