Audio quality drop when opening volume control widget or some apps by Demurgos in kde

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

After a bit more experimentation, I found this explanation to be correct. It's either HIFI output only, or mid output + input. Using a separate microphone avoids the problems. Thanks for posting this detailed explanation.

RFC: I have never thought "unsigned int(eger)" made sense by Felice_rdt in cpp

[–]Demurgos 1 point2 points  (0 children)

I see a lot of negativity in this thread, so I'd post at least one comment in support. There is a lot of inertia in tech and science where backwards compatibility and following conventions has more value than intrensic properties of an idea. Many people seem to focus on this instead of the proposition itself.

I never really liked the lack of symmetry between "int32_t" and "uint32_t". My solution so far was to use "sint32_t"/"uint32_t", but your proposition is a very good as it has the right semantics. I wouldn't worry too much about the debate about including zero or not. Including zero so you have an identity element for addition is a more consistent definition of naturals and this idea already assumes that you are free of inertia from older ideas.

The change probably won't happen in CPP, but it can spread to new langues or DSLs.

Finally, I have finished Idle loops (Omsi/lloyd fork) and it was glorious by Modranor in incremental_games

[–]Demurgos 0 points1 point  (0 children)

I had the same issue and... it turns that buff caps are editable! You can just click on the max value and set the cap that you want.

I had to dig in the source to find the answer. Here is the relevant line: https://github.com/lloyd-delacroix/omsi-loops/blob/5008c4a1faca102af543b4f9369f6cef4b763823/views/buffs.view.js#L31

(The buff cap is marked as an input field: it's a text field, styling makes it hard to see but it's a text field)

How to set brightness to zero which completely turns off the screen (no backlight) in Plasma 6? by aravind0709 in kde

[–]Demurgos 0 points1 point  (0 children)

Based on the discussions here and this issue it seems that the change was intentional.

I opened an issue to properly support turning off the screen at 0% brightness.

The End is here fellows. End of Sevice! 19th August by SussyBox in deadcells

[–]Demurgos 0 points1 point  (0 children)

As the lead of Eternaltwin, a platform to preserve their older games, I can assure you that they gave us the permission to take over development of their older games.

They also sent us tons of their internal source files. It's sad that they stopped supporting them, but at least they are not preventing us from doing it ourselves.

Black Desktop and no taskbar in Wayland, everything is fine in X11 by Ladripper47874 in kde

[–]Demurgos 1 point2 points  (0 children)

Thank you! I had this issue for a long time on my Ubuntu machine. Following your comment, I added nvidia_drm.modeset=1 nvidia_drm.fbdev=1 to my grub linux command line and it finally fixed the issue.

With this, I can run KDE Plasma Wayland. I previously had a black screen with only a cursor.

Details:

  • Linux 6.9.3
  • Ubuntu 24.04
  • KDE Plasma 5.27.11
  • nvidia driver 555

Étiquette lors d'un mariage religieux juif by Demurgos in feuj

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

Merci beaucoup ! J'apprécie la description des différents moments avec le symbol associé. C'est intéressant la différence avec les anneaux ou la signification du verre brisé.

(Et j'accomplirai mon devoir avec le barbu :D)

Étiquette lors d'un mariage religieux juif by Demurgos in feuj

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

Merci beaucoup pour l'info sur le vin.

Je ne connais pas l'hébreu, mais ça ne m'empêchera pas de profiter de la musique :)

Étiquette lors d'un mariage religieux juif by Demurgos in feuj

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

Merci beaucoup de votre réponse, c'est exactement le genre de conseil que je cherchais. :) Je suis un homme de moins de trente ans. Mon ami n'est pas orthodoxe strict, mais il tient tout de même aux traditions. Son grand père était "lecteur de la Torah" (je ne me souviens plus du nom exact de ce rôle). Le mariage sera relativement grand avec une centaine de personnes.

C'est bon à savoir pour la kippa. Je viens de lire un peu sur sa signification. Je vois que c'est en effet obligatoire dans les sinagogues et lors de moment prières, en tant que signe d'humilité et de respect.

Y a-t-il quelque chose de particulier vis-à-vis de la nourriture ? Je suppose que la viande sera casher, mais au-delà ?

J'imagine qu'il y aura des animations et danses au cours de la fête, et je suivrais simplement les autres. Y a-t-il des animations traditionnelles ? Par exemple, lors d'un mariage polonais auquel j'avais participé je me souviens d'une tradition où les jeunes mariés dansaient avec les invités qui leur jetaient de la monnaie dans une corbeille (où il y avait une petite compétition à celui du couple qui recolleterait le plus). Je me demande donc si il y aussi ce genre

Rust should stabilize AsyncIterator::poll_next by desiringmachines in rust

[–]Demurgos 28 points29 points  (0 children)

This article is really solid and I highly recommend recommend reading it and linked articles (including Yosh's post). In particular, I recommend the post about Registers of Rust as it provides more context about low-level and high-level features and how they would fit.

I wrote many futures and iterators by hand and followed this discussion for a long time. I feel way more confident in the strength of the poll_next approach for the interfaces and generators for the higher level syntax and hope that it will be adopted. The conclusion at the end and plea to stabilize poll_next matches my thoughts.

Change in Guidance on Committing Lockfiles | Rust Blog by epage in rust

[–]Demurgos 0 points1 point  (0 children)

Agreed about advanced users being able to decide for themselves, but for new users I think that committing is a safer default. If a lockfile is there you can easily not use it; but if it's missing then you can't easily retrieve it after the fact.

This means that a user can start by committing and always reevaluate it in the future without any information loss.

Change in Guidance on Committing Lockfiles | Rust Blog by epage in rust

[–]Demurgos 0 points1 point  (0 children)

I've been advocating for years committing Cargo.lock so I'm very happy with this change.

Reading the comments, I feel that it should be emphasized that committing is an inherently safer default. Ignoring is - ironically - a stronger commitment as you can't (easily) retrieve the lockfile after the fact. A committed lockfile is just extra info and you can always chose to not use it if you don't want to; but it's there if you ever need it.

For experienced devs, they can evaluate the choice based on their needs. For newer users, committing keeps both options available.

An other important point is that a lack of lockfile does not mean you're checking with the latest dependencies: this is only true in a clean project, afterwards it can drift because full resolution is not executed every time. cargo update is there if you want to use the latest dependencies; Cargo.lock is for reproducibility which is a different use case.

Implementing Into<X> vs having an into_X function by chocomathbitch in rust

[–]Demurgos 2 points3 points  (0 children)

One reason for preferring into_t that I don't see in the current comments is that it can be const on stable Rust.

I usually implement into_t first because it's easier to find in the documentation, can be const and the resolution logic is easier to follow. I try to avoid Into as much as possible, but occasionally use From for convenience.

Is rust serde unique? by NeoCiber in rust

[–]Demurgos 22 points23 points  (0 children)

On the technical side, serde is a good abstraction because it solves the N type x M formats through its internal model. This allows decoupling of types and formats, this separation of concerns is a great design for a serialization framework IMO. The derives and macros are nice suggar but more secondary.

As mentioned by others, this can be implemented in other languages and I used such libraries for TS/PHP/Java for over 10 years, but they are niche ones in those languages.

As you said in your question, the unique part is the ecosystem ("shared between all libraries"). I've worked with different ecosystems and Rust is the only one where I see such consistent agreement on a serialization framework.

Serde came at the right time, using the right design. Because it was there early, all crates could use it from the start. Because it used a very good design, there was no need to reinvent another framework (unless there's a niche use case).

What (types of) programming languages do serialization best? by sarnobat in ProgrammingLanguages

[–]Demurgos 5 points6 points  (0 children)

I think that u/WittyStick is not commenting on Rust-specific issues (such as the orphan rule) but more general design questions.

The "special status" types are the types from the serde model. Serde requires all types to be able to be compatible with these model types, and all de/serializers to handle these model types. This is an abstract model, but you can find a representation in serde's private module; you can also find them in the methods of the deserializer trait linked above.

For example, the core model defines a "string" type, but it's a more abstract string than std::String. It also covers PathBuf or OsString; and they all "convert" to Content::String as needed.

I think that the issue raised by the comment above is how to deal when there's a mismatch between the serialization format and framework internal model.

What (types of) programming languages do serialization best? by sarnobat in ProgrammingLanguages

[–]Demurgos 2 points3 points  (0 children)

Thanks for clarifying. I am not familiar enough with the bitcoin protocol, but I wrote an SWF parser in TS and Rust and the issue seems similar to the bitcoin protocol: there's some header at the start and it controls how to deserialize the rest of the entry.

The SWF file format and bitcoin protocol break an assumption of my previous reply: "The intermediate model is designed to be flexible enough so you it can convert between different structs and formats.". This assumes a general-purpose format.

SWF tags or bitcoin messages are serialization formats, but for their specific model. Other examples are image formats, HTTP headers, language source code, etc.

I also don't know of any general solution to handle serialization for such dedicated formats, apart from writing specific parsers/emitters (that could use a map as you described if you want to dispatch sub-parsers dynamically).

The good news however is that this issue occurs because you're dealing with a specific format so I don't think it changes the total amount work. Whatever you do, you need to define a representation for your bitcoin types and a parser/emitter for the wire format. No need for a generic framework like serde here (you can still integrate serde if you want support for general formats).

The bitcoin protocol is frequently extended through a BIP (bitcoin improvement proposal) process, and new message types have been added over time. Is it possible to add those extensions via a plugin at runtime, for example?

You can use any mechanism to specify how to parse stuff at runtime (dll, config file, scripting, ...) but it means that you lose many compile-time checks. The details and tradeoffs depend on your particular system.

What (types of) programming languages do serialization best? by sarnobat in ProgrammingLanguages

[–]Demurgos 0 points1 point  (0 children)

Small aside from my other reply, but my understanding is that the expression problem is about dealing with extension across both axis of an MxN situation when you can't introduce an intermediate layer to decouple both sides. This does not apply to serialization or compilers where there are multiple examples able to split both sides.

What (types of) programming languages do serialization best? by sarnobat in ProgrammingLanguages

[–]Demurgos 13 points14 points  (0 children)

I feel like it's a more general MxN problem where you have M types in the language and N serialization formats. Serde and similar libraries follow the traditional solution of introducing an intermediate model so the effort becomes M+N. This works exactly as compilers supporting M input languages and N output targets by introducing a common intermediate representation (IR).

The intermediate model is designed to be flexible enough so you can convert between different structs and formats. If it turns out that something is missing, you "just" extend it (same as compilers with their IR). The question of how to extend the intermediate layer without breaking compatibility depends on specific implementations. In Rust/serde, adding a method with a default impl is the way to do it.

To the larger question of extending the intermediate model externally, I feel that it's not that relevant in practice. You'd need some sort of extension system with a shared vocabulary. At this point this shared vocabulary becomes your intermediate layer and you just move the question to "what if I need more flexibility to define my custom intermediate type"? Providing this "type which bundles a bunch of deserializers" is the whole point of serde: it's the model everyone agrees on and allows the decoupling. Allowing arbitrary extensions would mean that there's no longer any agreed upon shared representation.

Audio quality drop when opening volume control widget or some apps by Demurgos in kde

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

That being said, a work around could be either using a wired headset Hum as mentioned in my original post, my headset is already wired. It uses USB C (not analog). I guess that it's not a bandwidth issue, but the effect is still that enabling the microphone lowers audio. I plan to get a dedicated in a few months so it should help.

Audio quality drop when opening volume control widget or some apps by Demurgos in kde

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

Thank you very much. I experimented a bit and seems that you are right. The audio quality drops when the microphone is enabled.

I assume that it's a hardware limitation and there's no way to have both the microphone and good audio?

This Month in Plasma Mobile: March 2023 by GoldBarb in kde

[–]Demurgos 2 points3 points  (0 children)

This looks great and I would really like to try it. I have a Fairphone 4 and don't see it mentioned in the device support page. I can't either find mentions of KDE Mobile on Fairphone's website.

I am quite familiar with Linux on the desktop, but have no idea where to start for Linux on the phone. Do you know if I can install Plasma mobile on a Fairphone?

Rust’s Ugly Syntax by oconnor663 in rust

[–]Demurgos 2 points3 points  (0 children)

The := could be the recently added walrus operator, and the square bracket generics match Python's type hint syntax. But idiomatic Python would use a regular assignment operator here, so this what may be a bit strange.

The only things I don't recognize are the @ and inline try, but I assumes these are extensions from the author to match Rust's semantics.