• 9 Posts
  • 39 Comments
Joined 1 year ago
cake
Cake day: October 14th, 2023

help-circle
  • It’s no reddit in terms of quantity but honesty I’ve had higher quality topics and discussions here than there. Lemmy/kbin might not have taken off in the mainstream to offer a variety of subjects but when it comes to tech and software I think it’s covered well enough and people are generally nicer about it. The main problem is lack of (remotely) good seach function, I dont think the threads are getting indexed by google and the on-site search is atrocious.

    I don’t know of any discord programming communities, I wish forums were still a thing but the only live one I know of is the jellyfin one after they moved from reddit. Other than that it’s here or the various subreddits






  • Ok, I’ll just default to flathub for app search instead, thanks.

    Wish I wasn’t already running into bugs with it though - I started installing vscode and logseq with flatpak, it opened them in Mint’s Software Manager and there’s a spinny thing now indicating work is being done, but when I click on it it just says “Currently working on the following packages” and then… nothing, blank screen. No idea if it’s stuck or actually doing something in the background, but it’s been a while (way longer than those would usually require to be installed).

    Not a good first impression for sure




  • I wonder what kind of support for development do you get? Honestly I’ve only had obstacles when I switched, for example the docker installation was much more complicated on linux than on windows+wsl. Even installing python was problematic because apparently ‘upgrading it yourself can brick the system’, at least if an older version comes with the OS?

    And lastly it’s the simple thing that pretty much all tools work on windows natively but on linux you have to find workarounds, which is definitely a problem when it comes to productivity.

    So what are the benefits, what does linux have that windows doesn’t in this context?







  • I’m not that familiar with newer c# code and only recently started with result pattern but tbh, I can’t tell what is this code supposed to do. Does opt resolve to true or false in this case? Why do you want TestStringFail to always execute, and what should it return? Why is opt.None true when it was initialized with a valid string value, what does None even mean in this context?




  • You can kinda see this in things like modding communities or anything piracy related too. Users just want easy solutions even if it’s at the expense of creators, and creators are doing it more and more for money rather than any personal drive or satisfaction. I can’t believe we’ve reached a point where even mods are being locked behind paywalls, need to be commissioned or sometimes have entire teams funded by patreon to work on them, it’s just another business nowadays.



  • The switch case was based on an enum but it is what I want to get rid of. In the end I ended up doing what you wrote there, expect instead of casting I’m just writing

    case Type.Int: return MyTypedMethod<int>(args)
    case Type.IntNull: return MyTypedMethod<int?>(args)
    // etc for another 10+ different types
    

    It just feels like I’m doing something wrong if i have to manually handle every case in a switch (or if else) statement and I was wondering how could I write, for example, a method that would do the conversion from Type.Long to System.Int64 for me, and then I just pass that type into the generic method instead of having to manually translate it into a type every time it is used.

    However, if I have to use reflection maybe hardcoding it manually every time is actually faster and easier to debug so maybe i’m just overthinking it.

    That c# 7 structure looks interesting but not sure it solves my issue, I need to get to the part where i have the generic type T in the first place. I dont know how to get a “T” out of a custom field indicating type, so to speak.

    edit: as for the invalid code, i just wrote it quickly as example but you are right. Pretend it says switch (field.SomeType) instead of it being a method