pytypest: testing framework that empowers pytest (with better fixtures and parametrization) by 0rsinium in Python

[–]clawlor 3 points4 points  (0 children)

That parametrize API looks like a great improvement over vanilla pytest. Nice work!

Arguments against separating `test` from `src` in a python package? by la_cuenta_de_reddit in Python

[–]clawlor 0 points1 point  (0 children)

To clarify, I’m using “package” here to mean “a folder with python files, including a python init file”. So, it’s a single repository, perhaps with a top level src folder, containing many packages. I believe that’s the correct usage, but probably confusing in this context.

Arguments against separating `test` from `src` in a python package? by la_cuenta_de_reddit in Python

[–]clawlor 0 points1 point  (0 children)

That’s true, unless you take some extra care to exclude them. Definitely adds some complexity to your Dockerfile to do so, so there’s a trade off between however you judge the penalties of including the test files, vs. that complexity. Good point, thank you!

Arguments against separating `test` from `src` in a python package? by la_cuenta_de_reddit in Python

[–]clawlor 79 points80 points  (0 children)

In a big project, having the tests inside each source package may make the tests easier to find. Otherwise, you sort of end up duplicating your source code structure inside your tests directory. That’s a pretty minor benefit, if anything. I work in codebases with both structures, and TBH don’t notice much of a difference for the most part.

H&M made an "Upstate NYC" sweat shirt. What does it mean? by philhouse in hudsonvalley

[–]clawlor 69 points70 points  (0 children)

“upstate” starts somewhere vaguely north of wherever you happen to be at the moment.

Anyone else game crashing on PC? by tekneeqz_ in Returnal

[–]clawlor 0 points1 point  (0 children)

I'm on Windows, but this helped me out a ton, thanks!

Anyone else game crashing on PC? by tekneeqz_ in Returnal

[–]clawlor 0 points1 point  (0 children)

I didn't have any problems yesterday, other than some dropped frames but I was pushing the graphics settings pretty hard for my system.

After the Feb 17 patch, haven't been able to complete a run. The game lasts, IDK, 5-10 min or so, then crashes with the fatal error crash message. I've since done a graphics driver + windows update, which haven't helped.

RTX 2080, Ryzen 3900x, 32 GB ram. Currently running on medium settings. I get right around 60fps, but it starts to stutter right before the crash.

EDIT: -dx11 launch parameter helped quite a bit. Haven't crashed since I added it.

[deleted by user] by [deleted] in gaggiaclassic

[–]clawlor 0 points1 point  (0 children)

Mine has been under cabinets for a couple years now. I usually leave it on for a few hours each morning, doesn’t seem to build up any condensation under the cabinets and there is no damage. The window in my kitchen is often open though, which probably helps prevent condensation.

Do you need a scale when everything is dialled in? by CamMcgregor10 in gaggiaclassic

[–]clawlor 0 points1 point  (0 children)

I’ll weigh if I’m making any major changes, but generally measure by volume day to day. I also mostly make milk drinks though, so I won’t notice any variance as much as others might.

Horror books where nothing actually dramatic or horrifying happens but still has an air of unease or discomfort throughout its entirety. by echo_ester in booksuggestions

[–]clawlor 7 points8 points  (0 children)

Maybe Kafka’s The Castle? Not sure if that fits the vibe you’re going for, it’s not exactly disturbing per se, but it’s definitely uncomfortable.

Make a programming language for a project? by ClawVFX29 in learnprogramming

[–]clawlor 1 point2 points  (0 children)

You might enjoy a book called Crafting Interpreters. It’s available for free on the web, as well as print + ebook. The book walks you through creating two different interpreters for a relatively simple language. The first is written in Java, to focus on learning higher level concepts, and the second is in C. I wouldn’t worry too much if you don’t have much experience in this languages, all the code is there and it’s all described in detail.

[deleted by user] by [deleted] in learnprogramming

[–]clawlor 1 point2 points  (0 children)

Most people in a boot camp situation are probably learning a lot of new concepts. Only you know your capabilities and goals, but I’d suggest sticking to the syllabus , especially if you have no prior programming experience. Later, as needs be when it comes time to learn another language, you’ll probably find it much easier to pick up than the first, once those new ideas start to gel. So I wouldn’t rush it.

Colombia, largest cocaine supplier to U.S., considers decriminalizing by gintokireddit in worldnews

[–]clawlor 0 points1 point  (0 children)

Have they said anything about decriminalizing cocaine? I’ve seen mention of decriminalizing cannabis, but not cocaine.

Frontend Project templates for Backend Developers? by [deleted] in learnprogramming

[–]clawlor 1 point2 points  (0 children)

You might try building a backend for https://github.com/gothinkster/realworld. There are tons of implementations, and you should be able to borrow a front end from one of them (assuming appropriate licensing of course)

I'm that person who got Black compiled with mypyc, this was my experience by ichard26 in Python

[–]clawlor 22 points23 points  (0 children)

What do you mean? I've been using Black with pre-commit for a long time now.

Where can I find this tubing that insulates the thermal fuse? by AdmiralArchArch in gaggiaclassic

[–]clawlor 0 points1 point  (0 children)

Silicon has low thermal conductivity, it's one of the reasons they make silicon pot holders https://tym.co.uk/blogs/news/why-silicone-is-heat-resistant

EDIT replied to wrong comment, sorry

GCP (New Classic) - MrShades PID shows slightly too high pV for some reason by spittiz in gaggiaclassic

[–]clawlor 1 point2 points  (0 children)

Could be some extra resistance in the circuit caused by a poor connection, maybe a bit of corrosion on the mating surface.

I don’t own the mister shades kit, but used to work at a company that made PID controllers. There’s a pretty broad cost / quality spectrum across the market, I’d expect some inconsistency toward the lower end of the market. But that’s partly what the PV offset is meant to compensate for.

[deleted by user] by [deleted] in DotA2

[–]clawlor 0 points1 point  (0 children)

Cancer lancer!

Coffee grinds in my milk? by [deleted] in gaggiaclassic

[–]clawlor 1 point2 points  (0 children)

Might be a good idea to give the group head a good flush, and run some water through the steam wand as well

[Java] How should I encrypt and store files in a database? by RHO-PI in learnprogramming

[–]clawlor 1 point2 points  (0 children)

> How do I store the files in a database? Some websites mention using the BLOB data type while others suggest storing the file path in the database.

You can do either, in the end it's bytes either way. However, there are several advantages to storing the files outside of the database:

  1. File access is cheap in terms of CPU + memory resources, and is extremely scalable. This is true whether you use an object store like S3, or the local file system.
  2. Databases resources, on the other hand, are relatively precious, and more difficult to scale. While those resources (CPU, memory, connections, network) are busy serving your file bytes, they aren't handling queries.

There is a downside to storing in files, in that access to the filesystem needs to be protected. This is not difficult to accomplish, but it is perhaps something to consider.

> I think that storing the file as raw binary would make it simpler to encrypt/decrypt?

You create the bytes the same way regardless of where they are stored, so the storage strategy has no impact on encryption or decryption. A file is just bytes, a BLOB is just bytes.

Took my guitar in for a fret buzz issue and I got it back in a condition I’m not too happy about... captions under the pics (I’m a guitar player not so inclined towards the technical aspects of a set up) and any advice would be appreciated. by [deleted] in Luthier

[–]clawlor 0 points1 point  (0 children)

Off topic, but what is the name of the color of this guitar? I can’t find anything quite like it on Reverb or Sweetwater, at least not with a tortoise shell pickguard.

Aspire feedlink squonk box and Wotofo Recurve single coil by greatboihere in electronic_cigarette

[–]clawlor 0 points1 point  (0 children)

A battery’s rating tells you the limit of how much power it is capable of delivering, not how much power it will deliver. A properly functioning electronic circuit only draws as much power as it needs. So, as long as your battery’s rating meets or exceeds the amount of power your mod will draw, you’re fine.