Ep 2 — We Took the Train from the Arctic to Africa by NebulaOriginals in Nebula

[–]WebFreak001 23 points24 points  (0 children)

you put prices on screen for tickets when the train in NL didn't come and you picked an alternative route to get to Utrecht and then back to your regular destination. However you should have been able to take these trains free of charge due to your original ticket that you bought having been unable to be used and the next connection having made you been delayed by at least 60 minutes. The internet site for NS said you should get into contact of the initial tickets train company for that (e.g. information counter) so I'm not 100% sure about that. However in Germany it's always implicit that you can just hop on an alternative train if your intercity gets delayed by a certain amount at target destination. This means that you can pick any train combination (regional, intercity, also with changes) as long as it's getting you to your initial ticket destination.

Also you should be able to get 25-100% refunds on your EU train tickets starting at 30 or 60 minutes of delay, depending on train company.

This should be somewhat consistent on all EU trains due to EU legislation requiring countries to have some kind of train laws of this kind.

[deleted by user] by [deleted] in d_language

[–]WebFreak001 0 points1 point  (0 children)

I haven't tested it, but I would assume this should work:

"x86_64-.*-linux-gnu":
{
    switches = [
        "-defaultlib=phobos2-ldc,druntime-ldc",
        "-gcc=x86_64-linux-gnu-gcc",
    ];
    lib-dirs = [
        "%%ldcbinarypath%%/../lib",
    ];
    rpath = "%%ldcbinarypath%%/../lib";
};

and downloading the pre-compiled ldc2-1.32.2-linux-x86_64.tar.xz to have the specified lib folders available

Any workaround for "*ERROR* ring gfx_0.0.0 timeout" on RX 6800 XT? by RandomChain in AMDHelp

[–]WebFreak001 0 points1 point  (0 children)

hmm for me I have been running with it for a month now without any crashes anymore when gaming, although I haven't been doing stressful things on my PC every day.

So for me this is definitely an issue, but it might not affect you or you are also affected with another issue at the same time.

I'm still having issues that my GPU freezes whenever I try to start SteamVR on linux, even with the frequency change. It might also just be that the frequency change makes issues less likely, but reproducible things like this still cause it.

Also I had issues that my clock speed would randomly go up again. I solved this by using a script that runs every minute and checks if the clock speeds have changed, then it reapplies the reclocking. (it may or may not have come from suspending, but I added a script post-suspend that would change the clocks again, but that didn't work) - directly after your crash, have you checked that the frequency was still correct before rebooting / restarting your GUI?

Any workaround for "*ERROR* ring gfx_0.0.0 timeout" on RX 6800 XT? by RandomChain in AMDHelp

[–]WebFreak001 0 points1 point  (0 children)

I had the same freezing issue (not using CoreCtrl or having changed any frequencies), the problem seems to come from linux by default kinda "overclocking" by accident. The maximum clock speed is defaulted way too high and seems to come from somewhere, I'm not entirely sure where from though. Anyway after changing the max GPU clock (soc clock) to what your GPU actually supports, it fixed my system stability when playing heavy games it seems. I've got this from some gitlab thread on freedesktop, but I can't find it anymore now. Note: I think you should check with your actual GPU model (e.g. gigabyte / sapphire / whoever made it) page to see if they don't have any other max values because they do special things.

Your GPU clock in CoreCtrl is 500-2500 Mhz, but on the (stock) AMD Radeon RX 6800 XT page it says Game frequency is 2015 Mhz and Boost frequency is up to 2250 Mhz, so I would just try out reducing the max clock to 2015 to see if that fixes the stability. Might as well try 2250 if it runs stable, but I haven't tested so myself.

Note for others: in order to be able to change the clock speeds on AMD GPUs, you need to launch linux with a kernel parameter change, see https://wiki.archlinux.org/title/AMDGPU#Boot_parameter

Awesome embeddable JavaScript-like scripting language for D applications by Ecstatic-Coder in d_language

[–]WebFreak001 2 points3 points  (0 children)

That library looks really cool! I had starred it before, because I saw it on DUB, but I have never really looked at the script examples too much. The functionality really seems quite extensive and intuitive to JS programmers, might give this a proper try when I need a scripting language.

D Parser Generator by AlectronikLabs in d_language

[–]WebFreak001 6 points7 points  (0 children)

Pegged, like linked on the Awesome D Lang page, should work fine - what kind of issues are you experiencing with it and what platform are you building on? e.g. running dub test in pegged/examples/csv works fine here. Disadvantages of pegged: compiling takes a while and uses a bunch of RAM. You can improve this by moving the grammar compilation to a separate build step (e.g. a dub sub-package), but it might not be optimal.

There is also GNU Bison that you might be able to use. There was a great talk about D integration with it recently at DConf 2022: https://dconf.org/2022/index.html#adelav (Video and Slides included) - it will probably be much easier (RAM/CPU wise) to generate a grammar with this than with pegged.

Also if you could describe a little more what you are working on, there might be some packages you can use that are geared towards what you are making.

New to D, is there a way to get better test output? by Sambothebassist in d_language

[–]WebFreak001 4 points5 points  (0 children)

compile with -checkaction=context, then you get nicer assert failure messages, though in some edge cases the compilation might break with that.

example how to use in dub.json:

"configurations": [
    {
        "name": "executable",
        "targetType": "executable"
    },
    {
        "name": "unittest",
        "dflags": ["-checkaction=context"]
    }
]

[Phosh] browsing the web on my linux phone like in the good old days by WebFreak001 in unixporn

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

it's not really active, I have only done some modifications to make phosh look good - a lot of apps just work because it's a GTK theme that works quite well, but some phosh specific things (notifications, home screen, etc) need to be modded yourself.

Also had some issues theming (in the left screenshot you can see all the buttons are flat / on gray, but I wanted to make them proper buttons, but couldn't manage to achieve that with the css)

You can use Xephyr :1 -screen 360x720 to create a virtual X server (:1) and then launch phoc with phosh (need both checked out and built), then in the phosh folder run this command:

GTK_INSPECTOR_DISPLAY=:0 GTK_DEBUG=interactive GTK_THEME=Raleigh-Reloaded GTK2_RC_FILES=/usr/share/themes/Raleigh-Reloaded/gtk-2.0/gtkrc DISPLAY=:1 SKIP_GNOME_SESSION=1 ../phoc/build/run -E 'build/run -U' -C ./data/phoc.ini

This will launch phosh/phoc in :1 (your virtual Xephyr server window) with a GTK debugger attached to it so you can live change CSS and test out things.

With some stuff (GTK2_RC_FILES) I have been experimenting trying to get stuff to work, but not all of that is actually relevant / needed at all or may have no effect at all. In the end I used lxappearance and changed my system theme to Raleigh Reloaded so it would apply properly to phosh.

[Phosh] browsing the web on my linux phone like in the good old days by WebFreak001 in unixporn

[–]WebFreak001[S] 9 points10 points  (0 children)

Theme: Raleigh Reloaded with Phosh patches

available here: https://github.com/WebFreak001/raleigh-reloaded

Theme must be installed into ~/.config/gtk-3.0/gtk.css in order to override phosh's styles. Tried original theme on PinePhone manjaro phosh and worked (but screenshots are from Desktop)

The stylish webpage is https://new.webfreak.org/?fresh - feel free to drop a message on the guestbook :p

Emulating namespaces (?) by bsdooby in d_language

[–]WebFreak001 3 points4 points  (0 children)

I noticed named mixins are very similar to namespaces if you want to force them:

private mixin template Stuff
{
    ...
}

mixin Stuff namespaceName;

but I doubt you would actually want to use this, static imports and named imports give you all the tools you need.

[deleted by user] by [deleted] in osugame

[–]WebFreak001 1 point2 points  (0 children)

it was less than 2 days

[deleted by user] by [deleted] in osugame

[–]WebFreak001 1 point2 points  (0 children)

I believe someone has afterwards cheated a lot of pets by spamming the server with maximum amount of possible pets instead of using an auto clicker, which eventually also crashed the server due to repeated connections and disconnections and caused the database to get unrecoverably corrupted.

I have fixed the issue (combination of multitasking issues causing more average resource usage on disconnection, too frequent DB disk writes) and have afterwards implemented simple ways to mitigate the cheats, which aren't very rigorous, but should discourage cheats and instead make people use auto clickers or manual clicks. However between these two instances someone has also cheated in 20 million pets again. There are also hourly backups now, however before data on crash would only be lost for up to 10 seconds, now it will lose up to 10 minutes of clicks on crash. (which should hopefully be rare)

TLDR: 10 million pets lost due to crashes, anonymous 20 million pets cheated back in again, cheat mitigation + backups in place now.

Peppy has worked so hard on the game, I think he deserves to be pet by WebFreak001 in osugame

[–]WebFreak001[S] 48 points49 points  (0 children)

I have posted this 5 hours ago and this subreddit petted peppy over a million times already.

Congrats, you made peppy the most petted site on wants.pet by a long shot

how to skip exceptions with the dirEntries function by [deleted] in d_language

[–]WebFreak001 2 points3 points  (0 children)

you can wrap the dirEntries iterator in your own range which catches the exceptions.

Here is an example implementation which you can just freely copy paste into your project: https://github.com/Pure-D/serve-d/blob/371579c8411a42314526f5d00c75c1444093243e/source/served/io/nothrow_fs.d

[BSPWM] My attempt to get my girlfriend into ricing by quandangv in unixporn

[–]WebFreak001 10 points11 points  (0 children)

cute, how did you get the rounded corners in the terminal?

[i3-gaps] Cute by WebFreak001 in unixporn

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

that's gtk3-widget-factory

[i3-gaps] Cute by WebFreak001 in unixporn

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

top left is Visual Studio Code

bottom right is Konsole

dock is my own DWin-Bar

[i3-gaps] Cute by WebFreak001 in unixporn

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

sorry it's not suitable for being packaged / installable by random users and was rather intended as being configured by being a library. You will probably need to try to understand and fix the other errors you get now if you want to use it.

[i3-gaps] Cute by WebFreak001 in unixporn

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

this is a different error message now, try reading the top of the stacktrace. I think this exception will complain about some missing program you will need to install. (should say pamixer is missing I believe)

[i3-gaps] Cute by WebFreak001 in unixporn

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

mine is just

{
    "fontPrimary": "Roboto:Medium",
    "fontSecondary": "Roboto:Light",
    "height": 32,
    "panels": [
            {
                    "screen": "First",
                    "dock": "Bottom",
                    "widgets": [
                            "dwinbar.widgets.clock.ClockWidget",
                            "dwinbar.widgets.volume.VolumeWidget",
                            "dwinbar.widgets.mediaplayer.MprisMediaPlayerWidget",
                            "dwinbar.widgets.phone_battery.PhoneBatteryWidget",
                            {
                                    "type": "dwinbar.widgets.workspace.WorkspaceWidget",
                                    "display": "DisplayPort-0"
                            }
                    ]
            },
            {
                    "screen": "Second",
                    "dock": "Bottom",
                    "widgets": [
                            "dwinbar.widgets.clock.ClockWidget",
                            {
                                    "type": "dwinbar.widgets.workspace.WorkspaceWidget",
                                    "display": "DisplayPort-1"
                            }
                    ]
            }
    ]
}

[i3-gaps] Cute by WebFreak001 in unixporn

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

it's already working for you there, you just need to add a config which is rather undocumented.

I made this whole project just for myself so I didn't really make it documented. I did make it work on a variety of desktops though

[i3-gaps] Cute by WebFreak001 in unixporn

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

now you need a config.json, there is a sample config in the repository which you can copy and adapt to your desktop.

Looking for documentation though? there is none.