Admin of the Bestiverse

  • 1 post
  • 14 comments
Joined 2 years ago
Cake day: September 5th, 2024
  • It looks like that tool is more or less built by a single developer (you already trust their judgment anyways!), and even though the code came through in a single PR it was a merge from a branch that had 79 separate commits: https://github.com/binwiederhier/ntfy/pull/1619

    Also glancing through it a bit, huge portions of that are straightforward refactors or even just formatting changes caused by adding a new backend option.

    I’m not going to say it’s fine, but they didn’t just throw Claude at a problem and let it rewrite 25k lines of code unnecessarily.

  • 130ms is perceivable but still quite small, and you’d only hit it once per domain (per TTL). If you care enough to intentionally use it then I wouldn’t worry about it. You’ll rarely notice the difference.

    There are a few other services with similar ethos that you may want to check out as alternatives. Quad9 is the one I remember off the top of my head.

  • I can’t help, just chiming in to say that I’ve also had that experience with Immich. It’s the one service I’ve used that has somehow managed to break itself multiple times like this.

    No idea how it happens, I don’t do anything weird with the setup and it just breaks. I’d heard that feedback from other people too but didn’t believe it until it happened to me. It’s been a few months so maybe I’ll try again, I’m just not too happy importing hundreds of gigs of photos multiple times.

    So yea just… you’re not alone, good luck.

  • ~15k lines of actual Rust code.

    @   git clone https://github.com/torvalds/linux && cd linux && tokei
    Cloning into 'linux'...
    remote: Enumerating objects: 10655741, done.
    remote: Counting objects: 100% (1067/1067), done.
    remote: Compressing objects: 100% (208/208), done.
    remote: Total 10655741 (delta 961), reused 859 (delta 859), pack-reused 10654674 (from 3)
    Receiving objects: 100% (10655741/10655741), 5.13 GiB | 13.37 MiB/s, done.
    Resolving deltas: 100% (8681589/8681589), done.
    Updating files: 100% (87840/87840), done.
    ===============================================================================
     Language            Files        Lines         Code     Comments       Blanks
    ===============================================================================
     Alex                    2          222          180            0           42
     ASN.1                  15          656          441           87          128
     Assembly               10         5226         4764            0          462
     GNU Style Assembly   1336       372898       271937        56600        44361
     Autoconf                5          433          377           26           30
     Automake                3           31           23            3            5
     BASH                   59         2029         1368          352          309
     C                   34961     24854959     18510957      2766479      3577523
     C Header            25450     10090846      7834037      1503620       753189
     C++                     7         2267         1946           81          240
     C++ Header              2          125           59           55           11
     CSS                     3          295          172           69           54
     Device Tree          5582      1744314      1430810        83215       230289
     Gherkin (Cucumber)      1          333          199           97           37
     Happy                  10         6049         5332            0          717
     HEX                     2          173          173            0            0
     INI                     2           13            6            5            2
     JSON                  894       542554       542552            0            2
     LD Script               8          377          289           29           59
     Makefile             3062        81226        55970        12993        12263
     Module-Definition       2          128          113            0           15
     Objective-C             1           89           72            0           17
     Perl                   61        43843        34461         3909         5473
     Python                280        84204        66996         5198        12010
     RPM Specfile            1          131          111            2           18
     ReStructuredText     3672       761388       577410            0       183978
     Ruby                    1           29           25            0            4
     Shell                 957       187353       130476        23721        33156
     SVG                    79        52122        50727         1303           92
     SWIG                    1          252          154           27           71
     TeX                     1          234          155           73            6
     Plain Text           1455       134747            0       110453        24294
     TOML                    3           47           28           12            7
     Unreal Script           5          671          415          158           98
     Apache Velocity         1           15           15            0            0
     Vim script              1           42           33            6            3
     XSL                    10          200          122           52           26
     XML                    24        22177        19862         1349          966
     YAML                 4545       512759       417504        19285        75970
    -------------------------------------------------------------------------------
     HTML                    2           28           22            3            3
     |- JavaScript           1            7            7            0            0
     (Total)                             35           29            3            3
    -------------------------------------------------------------------------------
     Markdown                1          248            0          177           71
     |- BASH                 1            2            2            0            0
     |- C                    1           20           12            6            2
     (Total)                            270           14          183           73
    -------------------------------------------------------------------------------
     Rust                   91        15207        11065         2248         1894
     |- Markdown            85         7773          747         5253         1773
     (Total)                          22980        11812         7501         3667
    ===============================================================================
     Total               82608     39520940     29971358      4591687      4957895
    ===============================================================================
    
  • Hmm, I could have sworn I had code for this but I’m not able to find it. I wrote a DLX impl many years ago and used it for a few things, and I wrote several different sudoku solvers, but I don’t seem to have ever used my DLX impl to solve sudoku puzzles…

    What you need to do is create a row for every possible entry and location in the puzzle. So you will have a row representing every single possible entry option. 9 options x 81 total squares = 729 total rows.

    The columns in your Exact Cover Matrix represent all the different constraints, where each column must be unique in the solution.

    • You’ll have 81 columns that represent just the location (you can only have 1 number in each of the 81 boxes).
    • For every Row/Column in the Sudoku Puzzle, you will have 9 columns to represent the 9 different numbers. (e.g you can only have a single “5” in every Row of the Sudoku)
    • For every 3x3 box in the Sudoku puzzle, you’ll also have 9 columns for the 9 different numbers.

    So your Exact Cover Matrix will need 324 columns = 81 (squares) + (9 (numbers) * 9 (rows)) + (9 (numbers) * 9 (cols)) + (9 (numbers) * 9 (boxes))

    When you fill out all the rows, you’ll place 1’s in all the columns that that specific entry aligns with. Take the example of the row corresponding to the entry “5” in the Sudoku Puzzles top left box. That row in your Exact Cover Matrix will contain:

    • A 1 in the column representing that specific box.
    • A 1 in the column that represents the number 5 in the first Sudoku Row.
    • A 1 in the column representing the number 5 in the first Sudoku Column.
    • A 1 in the column representing the number 5 in the top left Sudoku Box.
    • 0’s everywhere else

    To feed a specific puzzle into your solver, it kinda depends on the solver, you just need to force the output to contain those specific rows.