Skip Navigation

Posts
29
Comments
165
Joined
2 yr. ago

  • BBC is not the UK government. I'm not sure if there's a difference or not. (Also please accept my apologies for using this post for a quick federation test)

  • This was excellent and actually something I was looking for. Thank you so much <3

  • That graph is great. Very easy to understand. Thank you!

  • The Hot timeline becomes stale if the lemmy server isn't restarted every 6 hours or so, which takes 10 seconds but can't be done on larger instances such as lemmy.world because it kills the queue of outgoing activity.

    This is a known bug and is being worked on. For the time being you should try with "top 6 hours" and "top 12 hours" sorting.

  • Sorry for the late reply. If you're interested in music, you could give both javascript or C# a try. C# works integrated with the operating system and is not sandboxed by the browser, which means that you could do nifty things like actual sound processing and interact with sound devices etc.

    In general you will want to start with a console application that receives user input, does something and even prints the output. Let me give you an example of playing an audio file in C#

    LINE 1: System.Media.SoundPlayer myAudioPlayer = new System.Media.SoundPlayer(@"c:\mywavfile.wav");

    LINE 2: myAudioPlayer.Play();

    In the first line we are calling a pre-existing blueprint (library) that knows how to create an audio player. This blueprint can be located in System > Media > SoundPlayer within the collections of libraries. We are giving this virtual audio player a name and called it "myAudioPlayer". Then, after the "=" sign we are giving it the instruction to be created with a preloaded file that would be found in "C:\mywavfile.wav".

    In the second file we are commanding our newly created virtual audio player and telling it to play the file. Please note that this audio player would not have a visual interface yet. You would hear audio coming from the speakers but no way to pause. Fortunately C# / .NET (.NET are the pre-existing libraries that you can use), has a drag-and-drop way to create windows application interfaces with buttons via the "Visual Studio" editor, so you could potentially create a drag-and-drop interface and bind a button with a Stop symbol to the instruction "myAudioPlayer.Stop();"

    This is just a very very basic example, but object oriented programming often boils down to this: create virtual representations of something and then command them to do something.

    If this has peaked your interest check out this playlist of a full complete programming course in C# which is what I used to learn programming years ago. https://www.youtube.com/watch?v=umAcMO3d9_E&list=PLFqasLx4-AErVMCWiIyJe9uA3yQMPBukG

    In the end it's all about creating a series of instructions that the computer will follow. The trick is to learn what these instructions mean and to not be scared by their syntax, because behind every scary looking syntax there's just an instruction that can be explain in human language.

  • If you visit their homepage. You can fetch your local post if you take that url from their homepage and paste it in the search page of your instance.

  • Activitypub signatures that each user and group sends out their messages with.

  • No, the signatures wouldn't match.

  • Wrong community?

  • Oh I had to zoom in before I got hit. Hell no.

  • Oh yeah, apologies for the above comment. C# is definitely a good option, especially if you use windows and love messing around with the OS

  • I'm not sure I fully agree with that approach for most people since C++ resources and tools seem to not be the user friendliest but then again if it worked for you that is amazing.

  • Try "the Odin project", which has an amazingly active community.

    But before you try too much, once you've learned to set up any programming tools, just use them to have fun. Find a way in which you can use programming in relation to your hobbies.

    With JavaScript you can manipulate any webpage you see or create your own interactive webapp. Even if it's just a few ugly buttons and text fields, you could make an app that calculates good builds for a videogame you like, for example.

    If you want to interact with a windows operating system you can't go wrong with C# using visual studio. This will literally allow you to manipulate files, folders or automate anything you want from the operating system.

    Try to find something that is fun and just enjoy yourself with small apps before you try to go too fast.

  • They're suing for not allowing the sale of refurbished articles, which was contrary to the agreement signed by the people who sold the refurbished articles.

  • Panem et circenses to calm the masses and also to improve search results for the term 'reddit'.

  • What I do is create a new live snapshot before doing any changes to the server. I don't use digitalocean, but I think their snapshots cost 6 cents per GB/month, and are only charged like that if you retain them the whole month.

    If everything goes well after a change and you delete the snapshot a day or two later (or after the next backup), it's basically free or very cheap. I think it's just a minimum of $0.01 per snapshot.

  • Yes, let me logging to my server and try to retrieve the exact query I used. BRB

    Edit: here it is, the table is actually called activity

    DELETE FROM activity where published < '2023-06-27'; Just make sure to change the date to whatever you need. Leaving two weeks is more than enough to detect and refuse duplicates.

    In order to get access to the database you should probably be able to run docker exec -it midwestsocial_postgres_1 busybox /bin/sh. And then access postgres with psql -U username, the default username is 'lemmy'.

    Then connect to the database with \c lemmy

    You can list tables with \dt and view definitions for each table with \d+ tablename. For example \d+ activity.

    You can get some sample data from the table with select * from activity LIMIT 10; You'll see that the activity table holds activitypub logs and should be cleared out regularly as mentioned by dessalines in this post: https://github.com/LemmyNet/lemmy/issues/1133

    Important

    After deleting the entries (which could take some minutes depending on how much data it holds) you will not see a difference in the filesystem. The database keeps that freed up space for itself but you should see backups being much lighter and of course, the file system itself will stop growing so fare until it has reached the previous levels.

    If you want to free up that space to the filesystem you need to do a "vacuum full" but that will require downtime and could take several minutes depending on the space that was used up and the space that is still free. It could take up to an hour. I haven't done this myself since backups have gone down in size and I don't need extra free space in the filesystem as long as I stop the database from growing out of control again.

  • Did you find a solution. The above comment with the database query should work. You can access the docker container where the database is running with docker exec -it instancedomain_postgres_1 busybox /bin/sh and then run psql -U databaseuser which by default is 'lemmy'.

    Check docker ps to know the exact name of the postgres container which in your case likely is lemmytalungorg_postgres_1

  • I can imagine this being a problem for low effort youtube kid shows, like the ones that caused the whole elsagate controversy.

  • Yes, that might actually be the activitypub table in the database. You can safely delete older entries, like from two weeks ago or older. Otherwise it just keeps growing with the logs of all activitypub objects that the server has sent out received.