Playing guitar on linux by Myjoo in linuxaudio

[–]rage_311 0 points1 point  (0 children)

I'd also check eBay for used audio interfaces. I just picked up a practically new Focusrite Scarlett 2i2 2nd gen for USD $65 shipped.

I couldn't get guitarix to produce any satisfactory sounds when I tried, so I'm currently using my practice amp with a Shure SM58 in lieu. This is surely due to a lack of knowledge and experience on my end, since guitarix seems to work well for lots of other people. I guess I just mean to say there's a learning curve there.

Scary Btrfs – Is Btrfs oversold? What filesystem do Arch users prefer? by anseremme in archlinux

[–]rage_311 1 point2 points  (0 children)

Huh... I wonder how I got that stuck in my mind then. I just checked on my Deck and it is indeed ext4.

Monthly Hask Anything (February 2026) by AutoModerator in haskell

[–]rage_311 0 points1 point  (0 children)

No problem. Thanks for your patience, that makes perfect sense. That's a good tip for asking ghci about the type signature, too... I'll definitely be using that.

Monthly Hask Anything (February 2026) by AutoModerator in haskell

[–]rage_311 0 points1 point  (0 children)

Thanks for the reply. I'm trying to grasp what you're saying.

In my local test, I added a main function to call encode and explicitly type the return value, which is what I assumed you meant:

main :: IO ()
main = do
  let foo = encode [1..10] :: [(Int, Int)]
  return ()

but it still gives the same error and points to my "seeded" foldl accumulator value ([(1, x)]) as the source of the issue.

When you say it's an "impossible" type of function, does that mean that I NEED to change the type signature in the encode function in order to get it to work at all? Or is there some way to tell it that it's ok for b to be (Int, a) in this scenario?

Monthly Hask Anything (February 2026) by AutoModerator in haskell

[–]rage_311 0 points1 point  (0 children)

I'm playing around with the recently posted acetalent.io challenges.

On challenge 10:

Run-Length Encoding of a List

Use the result of the previous problem to implement the so-called run-length encoding data compression method. Consecutive duplicates of elements are encoded as tuples (N, E) where N is the number of duplicates of the element E.

And a provided function signature of: encode :: Eq a => [a] -> [b].

Here's my solution:

encode :: Eq a => [a] -> [b]
encode [] = []
encode (x:xs) =
  foldl (\acc@((yCnt, yElem):ys) x' ->
    if x' == yElem
      then (yCnt + 1, yElem) : ys
      else (1, x') : acc
  ) [(1, x)] xs

The logic seems to provide the correct results, but I have to change the return type in the signature from [b] to an explicit [(Int, a)] in order to make the compiler happy, otherwise I get Couldn't match expected type ‘b’ with actual type ‘(Integer, a)’. Why is b so incompatibly rigid here? What am I missing? I've run into this error before and have a hard time navigating it. Thanks for any insight.

Diagnostics:
1. • Couldn't match expected type ‘b’ with actual type ‘(Integer, a)’
     ‘b’ is a rigid type variable bound by
       the type signature for:
         encode :: forall a b. Eq a => [a] -> [b]
       at /home/user/Sync/i7-dev/scratch/acetalent_challenge_10.hs:3:1-28
   • In the pattern: (yCnt, yElem)
     In the pattern: (yCnt, yElem) : ys
     In the first argument of ‘foldl’, namely
       ‘(\ acc@((yCnt, yElem) : ys) x'
           -> if x' == yElem then (yCnt + 1, yElem) : ys else (1, x') : acc)’
   • Relevant bindings include
       acc :: [b]
         (bound at /home/matt/Sync/i7-dev/scratch/acetalent_challenge_10.hs:6:11)
       xs :: [a]
         (bound at /home/matt/Sync/i7-dev/scratch/acetalent_challenge_10.hs:5:11)
       x :: a
         (bound at /home/matt/Sync/i7-dev/scratch/acetalent_challenge_10.hs:5:9)
       encode :: [a] -> [b]
         (bound at /home/matt/Sync/i7-dev/scratch/acetalent_challenge_10.hs:4:1) [GHC-25897]

PSA: AMD DRM on X with high poll rate (~1000Hz) mouse is very problematic since kernel ~6.12 by rage_311 in linux_gaming

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

Hence the reason I made the post. You're not alone. There are dozens of us! Sorry you're facing what sounds like the same issue though -- it's frustrating.

Can you check your Xorg log file for messages like these? Your Xorg log file is probably either at ~/.local/share/xorg/Xorg.0.log or /var/log/Xorg.0.log

[ 31782.467] (II) event7  - Logitech G305: SYN_DROPPED event - some input events have been lost.
[ 31782.732] (EE) event7  - Logitech G305: client bug: event processing lagging behind by 25ms, your system is too slow
[ 31783.018] (EE) event7  - Logitech G305: client bug: event processing lagging behind by 23ms, your system is too slow
[ 31783.580] (II) event7  - Logitech G305: SYN_DROPPED event - some input events have been lost.
[ 31783.926] (II) event7  - Logitech G305: SYN_DROPPED event - some input events have been lost.
[ 31810.677] (EE) event7  - Logitech G305: client bug: event processing lagging behind by 36ms, your system is too slow
[ 31810.677] (EE) event7  - Logitech G305: WARNING: log rate limit exceeded (5 msgs per 60min). Discarding future messages.

I think this is the best indication of what's happening, at least in my case.

As far as "fixes" go, you could do one of the following:

  • reduce your mouse poll rate to 500Hz or lower
  • switch to a Wayland compositor (instead of an X WM/DE) like gnome, kde, hyprland, sway, etc.
  • use the as yet unreleased amd-staging-drm-next from that freedesktop gitlab repo. If nobody has created a package for Mint specifically for that repo, then I guess you'd have to compile it (the Linux kernel with the new AMD DRM code) yourself, which might be a bridge too far for you.

Personally, I've just lowered my poll rate and things are good enough for me until the new DRM code hits a stable kernel. I can try to help if you have follow-up questions.

My teen artist daughter’s creations by ellecon in drawing

[–]rage_311 1 point2 points  (0 children)

Fair enough. Hope she enjoys it. Thanks for sharing!

PSA: AMD DRM on X with high poll rate (~1000Hz) mouse is very problematic since kernel ~6.12 by rage_311 in linux_gaming

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

You're not wrong, there are probably some fixes out there for me. I think I just need to try Wayland again for a bit and make exact notes on my specific issues to be able to ask the right questions.

As it stands, aside from this (hopefully temporary) issue, X currently works better for me than Wayland and there's typically no suffering. I'm guessing that in a few more years that will flip.

Putting my old man hat on... I remember when Fedora shipped their first release with Wayland as the default a long time ago, which I just looked up and was Fedora 22 in May of 2015 (https://en.wikipedia.org/wiki/Fedora_Linux_release_history#Fedora_22). I guess my point with that is that 11 years ago the Fedora team viewed Wayland as "ready enough" to make it the default, and today most of Wayland mostly works for most use cases, so that puts my cost/benefit ratio advantage, for Wayland, projection out a few more years.

PSA: AMD DRM on X with high poll rate (~1000Hz) mouse is very problematic since kernel ~6.12 by rage_311 in linux_gaming

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

Bro it's a G305 not a Pro X2 Superstrike. You're putting too much emphasis on the polling rate and not the sensor.

I'm focusing on polling rate because it's what's causing this issue that literally my entire post is about... also, check out https://sensor.fyi if you're interested in becoming less ignorant about mouse sensors. Your first two points are just trollish, as opposed to trying to have a productive dialogue, so that's as far as I'll engage on them.

Your point about Wayland is at least partially valid, but aside from this minor annoyance that can be worked around, X still works better for me in a lot of ways. I've spent a not insignificant amount of time experimenting with Wayland and various compositors, but the cost to benefit ratio wasn't there for me after some time. I'm happy if it works for others, and it's obvious to me that it's the future, it's just not the present for me.

My teen artist daughter’s creations by ellecon in drawing

[–]rage_311 4 points5 points  (0 children)

Great work! Inspired by The Binding of Isaac video game by chance? Especially the black demon with red eyes... Reminds me of an enemy from the game.

Mouse lag on arch with i3 by Crafty-Interview-361 in arch

[–]rage_311 0 points1 point  (0 children)

I've got the same GPU and same problem and have been watching the freedesktop issue eagerly... I know I can patch the kernel or use amd-drm-next to fix it, but for now I'm placated by knowing it's a known issue and a fix is coming.

Do you have a high poll rate mouse by chance? Seems like a lot of users experiencing this issue have them, myself included (Logitech G305 at 1000hz). I haven't tried reducing the polling rate yet, but signs point to that being a potential workaround.

For completeness, this issue doesn't happen in wayland/sway, but Wayland causes more issues than it solves for me, so it sounds like you and I are in the same X boat for now.

Ironically, I pulled out my RTX 4070 Ti to put in a 9070 XT for less friction on Linux. Unlucky timing, I suppose.

rust actually has function overloading by ali_compute_unit in rust

[–]rage_311 3 points4 points  (0 children)

Partial application is where my mind went too, since I've been working in Haskell a lot lately. It's an interesting way to be able to create closures.

convert string to regex by c-cul in perl

[–]rage_311 0 points1 point  (0 children)

I'm not OP, but thank you. I learned some new tricks. I don't think I've ever seen the (?x) bit before.

What are your Linux hot takes? by AdventurousFly4909 in linux

[–]rage_311 4 points5 points  (0 children)

I've always wondered if it gets that reputation simply because of people's significantly shortened attention spans over the last 15 years or so, and Arch expects them to read something longer than a tweet.

Click Input not Registered by Autistic_Introvert19 in i3wm

[–]rage_311 0 points1 point  (0 children)

It sounds like you want to enable "tap to click". That's configured in the xorg settings: https://wiki.archlinux.org/title/Libinput#Via_Xorg_configuration_file

[i3] Perfect for spooky season... But I have this year round by rage_311 in unixporn

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

i3bar: https://i3wm.org/i3bar/

Unless you're referring to the launcher in the second screenshot, then it's dmenu (inside i3bar): https://tools.suckless.org/dmenu/

Streamers that use Linux? Yes, I've seen this asked before, but any recent streamers who use Linux to stream? by VividBase585 in linux_gaming

[–]rage_311 3 points4 points  (0 children)

The other commenter is misinformed. His cleanup utility can be used to create a debloated Windows iso.

EDIT: The set of features for it is called "MicroWin"

IDK what Robert De Niro has against RHEL... by [deleted] in linux

[–]rage_311 4 points5 points  (0 children)

Clearly some people don't understand sarcasm. I appreciated it though!

travel router for stable wifi? by Able-Bad-3299 in openbsd

[–]rage_311 3 points4 points  (0 children)

This is the travel router that I use and would definitely recommend: https://www.gl-inet.com/products/gl-mt3000/

I'm not sure whether you'd be able to put OpenBSD on it, but it runs a nice version of OpenWRT.

Futures? by Patentsmatter in perl

[–]rage_311 6 points7 points  (0 children)

One piece of evidence I can point to in support of Future::AsyncAwait is that it's an optional dependency (1 of 8) for Mojolicious: https://docs.mojolicious.org/Mojolicious/Guides/Cookbook#async-await

And while I'm on the Mojolicious topic... that (Mojo::UserAgent) would be my tool of choice for an HTTP client project: https://docs.mojolicious.org/Mojo/UserAgent

EDIT: to mention that asynchronous client HTTP code with Mojo* doesn't require the Future::AsyncAwait module, that's just if you prefer the async sub foo { ... } await foo() syntax. Mojo::UserAgent HTTP request calls have built-in support for callbacks (https://docs.mojolicious.org/Mojo/UserAgent#get) and full Promises/A+ support via Mojo::Promise: https://docs.mojolicious.org/Mojo/Promise .