Skip Navigation
Project Kuiper: Amazon's answer to SpaceX's Starlink passes 'crucial' test
  • Call me a socialist, but the moment the tech was proven either the US or some UN based org should have eminent domained and brought Starlink.

    That way there wouldn't be multiple companies sending tens of thousands of satellites into space. And hypothetically there would be a greater expectation of equal access. Oh and access wouldn't be at the whim of a pretty billionaire.

  • *Permanently Deleted*
  • Ha, I did the same thing. Was getting really tired of pip issues and attempting to use pyenv and messing up a lot. Figured I'd start clean.

    Didn't realize so much depended on python and ended up needing to rebuild the whole thing.

    Now I don't mess with python on my host and only use VMs for Dev or messing around.

  • Return Generic Type in Rust
  • SOLUTION:

    Here is the solution I came up with:

    pub struct Configuration {}
    
    impl Configuration {
        fn get std::str::FromStr>() -> Result {
            Ok(T::from_str("1234");
        }
    }
    
    fn main() {
        let my_conf_val = Configuration::get();
    }
    
  • Return Generic Type in Rust
  • Afraid this might have been the case, if Ogeon's suggestion doesn't work out, I'll probably end up with multiple getters, one per type. There aren't that many anyway

    Thank you!

  • Return Generic Type in Rust

    Background: I have a large serde_json value that I want to be read-only (the authoritative source is an encrypted SQLite DB and should only be updated when that gets updated)

    The issue, I would like a single get function that returns a generic type

    ```rust use serde_json;

    pub struct Configuration { config: serde_json::Value, }

    impl Configuration { async fn get(&self, key: &str) -> Result { let tmp_value: = &self.config["test"];

    // This would be repeated for String, bool, etc if tmp_value.is_i64() { match tmp_value.as_i64 { Some(x) => Ok(x), Err(e) => Err(()), } } else { Err(()) } } } ```

    However I get: "mismatched types expected type parameter T found type i64"

    Is it even possible to return multiple types from a single function?

    EDIT: SOLUTION

    Here is the solution I came up with:

    ```rust pub struct Configuration {}

    impl Configuration { fn get std::str::FromStr>() -> Result { Ok(T::from_str("1234"); } }

    fn main() { let my_conf_val = Configuration::get(); } ```

    8
    Linux way way slower than Windows?
  • Any Ubuntu affiliated distro is required to use snaps, so Kubuntu will use them. Startup times are terrible, but running performance should be the same.

    Another simple distro to try would be either Mint or Pop-OS. Both are still Ubuntu based, but without snaps

    Mint's interface (Cinnamon) is similar to Windows, Pop-OS uses a modified GNome

  • Is there a Linux based OS for public computers, such as at a library or a PC cafe?
  • I'm not sure of exactly how they manage everything, but my county library system uses Debian with an XFCE interface.

    Not sure if it's because it's been this way long enough now, or it just looks close enough to Windows, but I haven't known anyone to complain (and my in-laws complain about everything else)

  • *Permanently Deleted*
  • Self hoster of Invidious, I've just setup a docker instance with a Watchtower docker container running too for auto updates. No real maintenance needed.

    NewPipe on Android

    There are definitely times where things will stop working for a bit (due to Google shananagans) but the devs seem on top of it. So it doesn't take too long before it's working again.

  • Purchase Advice

    Looking to get new headphones since the battery is now shot in my Corsair

    I'm looking for:

    • Mostly listening to music, some online meetings, some single player games (I am not an audio file)
    • Bluetooth that can save multiple devices
    • Over ear
    • Noise cancelling (preferably adjustable, but not necessary)
    • Microphone (preferred but not necessary)
    • Under 300 (preferably under 200)

    Whenever I search online the lists are always "here is the best for 500 - 1000, or really affordable, but with no features"

    Thank you in advanced!

    4
    Calculating Interest on a "Virtual" Savings Account
  • This seems like the best answer, it's still not exact since interest changes daily (at least in the U.S) and interest compounds monthly.

    But I changed the interest formula to:

    Number of Days * Interest Rate * (Last Balance + Deposit) / 365

    That seems to be more accurate.

  • Anyone doing plain text accounting here?
  • I wanted to go this route, but for the current stage of my life, I couldn't go that granular. I currently have a spreadsheet that keeps track of totals in each bank account (short term, long term, college, retirement savings and checking) as well as total (net) income and expenditures (broken into "essential" and "non-essential").

    I then setup formulas to calculate total saved, (as well as necessary only saved, in case of financial stress to see what we can cut out), total assets, and compares those assets to the previous month and year.

    While I want to get more granular, that is all I can do for now.

  • Personal Finance @lemmy.ml wulf @lemmy.world
    Calculating Interest on a "Virtual" Savings Account

    So for our kids, who are still quite young, instead of opening an entire other savings account for them, we decided to do "virtual" savings accounts.

    Essentially, we have a spreadsheet with what money they have gotten from birthdays and other events, then we just deposit it in our savings. They can withdraw whenever they want.

    In this spreadsheet, I've been trying to keep track of interest (in a basic way), to show how saving can also help them "earn" money. However, I don't think I'm doing it correctly.

    See Google sheet: dates are not correct and interest rates are not accurate. I just wanted to show that we are attempting to give the "correct" interest rate for the given date. (I know interest rates fluctuate all the time, just trying to not make it not too difficult to maintain)

    https://docs.google.com/spreadsheets/d/1rwwIFVOGYt-lIx8Dtuv_6PGz28jSNQbH7LcZG2qKlfg/edit?usp=sharing

    Thank you for taking a look, I've been trying to get this right for a while.

    8
    Xfce appreciation post
  • Using gnome now, but have always enjoyed Xfce. Was going to use it for my current setup, but at the time it didn't support Wayland. It looks like it's getting close, but not quite there yet.

    Maybe once Wayland is fully supported I'll give it a shot again.

  • Can you drive a manual transmission?
  • Yep, I'm 36, mid Atlantic US, started driving stick when I was 18. I inherited this little Geo Metro for college, so it was learn stick or no car. (I really liked that car dispite it not having air conditioning, no tachometer, and manual everything)

    Next car I bought was a manual. Now since my spouse can't drive stick we only have automatics.

    Whenever we need a new car it'll be electric, which unfortunately (by design) are not manuals. So no more stick for me.

  • InitialsDiceBearhttps://github.com/dicebear/dicebearhttps://creativecommons.org/publicdomain/zero/1.0/„Initials” (https://github.com/dicebear/dicebear) by „DiceBear”, licensed under „CC0 1.0” (https://creativecommons.org/publicdomain/zero/1.0/)WU
    wulf @lemmy.world
    Posts 3
    Comments 16