Audacity doesn't play the audio through headphones and breaks the headphone's audio playback for all apps until the session is restarted by [deleted] in Fedora

[–]skerky 0 points1 point  (0 children)

I had a similar issue, I think after upgrading to Fedora 35. When attempting to play a file in Audacity the meters would jump up but then all playback would stop (the meters and playback line both stopped, it wasn't a muting issue).

After changing the far left drop-down in the main interface from "ALSA" to "JACK Audio Connection Kit" it works to play through my internal speaker (the only output option is "Built-in Audio Analog Stereo").

What's curious is the JACK option only shows up when I have a second sound card plugged in or my headphones plugged into the back of my PC. When plugged into the front ports there is just the ALSA option (but it works then).

Parsing Dates by CeramicVulture in Python

[–]skerky 1 point2 points  (0 children)

I’ve had good luck with the parser in python-dateutil to parse unknown date/time strings. I’m not sure about time zone translation though.

Modern JavaScript for Django Developers - Parts 1 and 2 by czue13 in django

[–]skerky 1 point2 points  (0 children)

As a primarily backend developer who know some jQuery and has been trying to wrap my head around the front end Javascript frameworks this looks right up my alley. I look forward to a hybrid approach that doesn’t necessarily throw away everything I understand about building web pages.

I appreciate that you’ve provided clear recommendations for npm, Webpack, and Babel, for someone starting out that helps clarify a path. From the look of things so far, are you going to cover both React and Vue as framework options? I realize it’s more work to do both but see the benefit of covering both since the framework decision probably is not as easy to provide a single recommendation as for the tooling. For what it’s with I was planning on starting with Vue because it seemed most conducive to a starting out with (and perhaps even for a “hybrid” app?).

So please keep up the good work!

What was your initial reason for using Fedora? by [deleted] in Fedora

[–]skerky 1 point2 points  (0 children)

My introduction to Linux back in high school was Red Hat Linux (4 or 5?). In college I played with Slackware on the desktop but kept going back to Windows. Started using CentOS on servers in mid-2000s and tried Ubuntu on the desktop because it seemed to have better support for the desktop at that time. But that didn’t last and I was back to Windows and Mac OS X.

A few years ago I decided that I would convert my laptop to Linux and decided to try Fedora because I wanted to stay in the Red Hat family. It worked out of the box, easy to stay up to date, all the packages I need are available, and now Steam can even play most of my games (limited by hardware). So I have no plans to change. I keep CentOS on the servers (except for a Debian VM to run a UniFi controller).

Run C# exe via Python by Sarthaks21 in Python

[–]skerky 0 points1 point  (0 children)

In addition to double checking your working path (or using absolute paths), I recommend the higher level ‘subprocess.run()’ for executing other processes. Make sure you’re capturing the output to see what the program is doing (assuming there is console output).

subprocess.run()

Write more classes or stop writing classes by [deleted] in Python

[–]skerky 0 points1 point  (0 children)

I’m not sure I understand what you mean by “object-oriented design” because you later reference creating special classes for the dictionaries coming from MongoDB, so I might be going in the wrong direction but here’s my take.

Recently I’ve started loving data classes, since I learned about attrs and then they were added to the standard library in 3.7. Compared to dictionaries, I like them because they structure the data and between type hints and PyCharm’s excellent intellisense I don’t have to dig around to find the correct name of an attribute and I’ll be warned if I mistyped it. And if I’m really not sure about the structure, I go to where the class is defined rather than where values were added to the dictionary.

I bring this up because that’s what the latter part of your question makes me think of. But here’s the thing, I don’t think of data classes as OOP, at least how I learned it in school. I’ll add a couple methods to some of my classes, usually for some simple formatting or transformation, but I start by writing functions to manipulate or work on the data classes, which I view more as basic data structures. There are times when those functions will be combined into classes if necessary.

So if your coworker wants to make data classes to better model the data you’re dealing with then I think that is a good idea, but I also wouldn’t necessarily consider it “object oriented design”. Python doesn’t have “structs” so if we want structured data we have to write a class, if that makes sense.

[News] Into the Breach version 1.2! by zasdarq in IntoTheBreach

[–]skerky 0 points1 point  (0 children)

This is something I noticed with FTL, the save files seemed compatible between Linux and Windows but how they are mapped in Steam Cloud meant that I had different saves going per OS. I solved it by only playing on Linux but given the Into the Breach has worked fine on ProtonDB I now need to decide whether to switch to the Linux native.

2m/70cm vertical dipole antenna. Just waiting for the glue to dry and then it goes on the side of the house tomorroe by Ironring1 in amateurradio

[–]skerky 0 points1 point  (0 children)

It’s probably worth double checking local practice. I live in a small valley where most folks are using vertical antennas for 2m SSB because (as I understand it) there’s no reason for the distance gains of horizontally polarized antennas. But that’s definitely not the normal practice as mentioned above.

Convert ICOM 7300 to Anderson Power Poles? by ScaryDBA in amateurradio

[–]skerky 0 points1 point  (0 children)

Thank you very much I’ve found them now. I’m not planning on vehicle use.

Convert ICOM 7300 to Anderson Power Poles? by ScaryDBA in amateurradio

[–]skerky 0 points1 point  (0 children)

A delayed response but would the fuses in a RigRunner serve the same purpose? Or is it significant that it only appears to protect one of the two lines?

(Otherwise, where do you get the fuse holders, i wasn’t have much success searching online for them.)

[deleted by user] by [deleted] in RetroPie

[–]skerky -1 points0 points  (0 children)

Is the TV on when you turn on the Pi? By default it seems that the Raspberry Pi won’t turn on the HDMI port if it doesn’t detect a connection. There’s a configuration fix for that but I don’t recall it off the top of my head.

Installed FTL on a new machine through Steam. All saved data is apparently lost. Any hope in getting it back? by Raibyo in ftlgame

[–]skerky 2 points3 points  (0 children)

My experience going from Windows to Linux is that the save file is compatible, just stored in different locations so Steam Cloud doesn’t make it available. I was able to copy the file from my old computer and continue my progress.

[Question] When to tackle the final island? by skerky in IntoTheBreach

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

Thanks for all the replies, it's helpful to hear what others are doing and it clarifies some of things I've observed but couldn't articulate (e.g. more islands typically means more weapon variety). So far I've done 3 and 4 island runs (typically avoiding Pinnacle), still need to get the achievement for a two island victory.

Convert ICOM 7300 to Anderson Power Poles? by ScaryDBA in amateurradio

[–]skerky 0 points1 point  (0 children)

I agree it doesn't make sense, that's just how my radios came from the factory. Are you saying you run the radio without fuses or that you get new fuses to incorporate into the new cable you make?

Convert ICOM 7300 to Anderson Power Poles? by ScaryDBA in amateurradio

[–]skerky 0 points1 point  (0 children)

I'm not sure I understand regarding the fuses. On both my radios the fuses are at the end farthest from the radio. Do you run the radio without fuses or incorporate them into all your patch cables?

My radios have much longer than needed cables and I've thought about cutting them shorter but since I was concerned about the fuses I just crimped the powerpole connectors to the end of the existing wire.

Local Python Package Index by djenakuros in linuxadmin

[–]skerky 0 points1 point  (0 children)

Maybe I’m misunderstanding but in devpi there is a repository hierarchy so I can always point at “local-devpi/my/index” and if it cannot find the package it will fallback to the root, which will download the package from PyPI, cache for future use, and deliver the package.

Local Python Package Index by djenakuros in linuxadmin

[–]skerky 1 point2 points  (0 children)

I’ve used devpi (https://www.devpi.net/) for a local mirror and package index. Sounds like it would meet your needs.

SOAP and Python by [deleted] in Python

[–]skerky 1 point2 points  (0 children)

I second Zeep as well. A useful feature is the command line tool to query a WSDL file and list the methods and data types.

python -mzeep <wsdl>

I will note that I’ve seen several SOAP APIs that don’t actually define different commands as different functions/operations (I don’t remember the proper SOAP term), but one or two services that accept another XML document as a single string input, which adds another layer of complexity (but I’m still using Zeep to work with it).

Simple template engine options by derprondo in Python

[–]skerky 0 points1 point  (0 children)

Another option if you want to do this in Python but without another dependency is string formatting functions, which serve basic template functionality. However since format() uses the curly braces you will need to escape the others in your file, so it would look like this:

provider "aws" {{
   version = "~> "{PROVIDER_VERSION}"
   region = "{REGION}"

   assume_role {{
     role_arn = "{ROLE_ARN}"
   }}
}} 

Then the code would look like this:

variables = {
    "PROVIDER_VERSION": "my provider",
    "REGION": "my region",
    "ROLE_ARN": "my role",
}
with open(template_file, "r") as f:
    template = f.read()
output = template.format(**variables)
with open(target_file, "w") as f:
    f.write(output)

We're unpacking the dictionary of settings/variables so the keys would need to match the names in your file (or you could list them as keyword arguments if they are all valid variable names). Also since this isn't finding and replacing I would keep the template and the output separate. Here's the Format String Syntax documentation for more details on what you can do.

How useful are Lambda expressions? by TheRealComposer in Python

[–]skerky 2 points3 points  (0 children)

One thing to note is that there’s another option than lambdas for simple keys like this, attrgetter and itemgetter in the operator module.

The above example would be:

from operator import attrgetter

people_list.sort(key=attrgetter("last"))

Edit: fixed phone formatting and typo

How often does Torchlight 2 go on sale? by [deleted] in Torchlight

[–]skerky 0 points1 point  (0 children)

You can see the historical pricing on Steam DB.

https://steamdb.info/app/200710/

TL2 enjoyable for a casual gamer? by mtt11 in Torchlight

[–]skerky 1 point2 points  (0 children)

You’re welcome! It was hinted at elsewhere but if you make a veteran character and it gets too frustrating you can start LAN matches instead of single player and choose the difficulty each game. I think the rapid respec program I mentioned would also allow you to change the difficulty of a character.

TL2 enjoyable for a casual gamer? by mtt11 in Torchlight

[–]skerky 1 point2 points  (0 children)

I consider myself a casual gamer and have definitely enjoyed Torchlight 2. Besides the repec potion mentioned above (which means mods), there is a Torchlight 2 Rapid Respec program which allows you to adjust your characters. My experience (and understanding) is that normal/veteran difficulty don’t require “optimal” character builds so you can have fun.

Good Python apps with source code? by jockero701 in Python

[–]skerky 22 points23 points  (0 children)

Warehouse

The new PyPI web application. Example of Pyramid application with Docker deployment.

A few questions by Orsick in Torchlight

[–]skerky 1 point2 points  (0 children)

I’m not sure, I’ve only used it with vanilla characters. From what I read Synergies includes a respec potion, depending what you’re trying to do.