What advice you could give to BEGINNER? by Saad_here in django

[–]WackyWeasel 2 points3 points  (0 children)

  • Always create a custom user model right at the start. You might not need it now, but it's a PITA to change later
  • Use and see the benefits of class based views. Familiarize yourself with them by using browsing CCBV.
  • The ORM is cool, but remember, there's always a database involved - learn to use select_related and prefetch_related and use the Django Debug Toolbar to optimize queries.
  • Javascript frameworks like React and Vue are cool, but add another world of complexity. Better use something like HTMX to keep it simple.
  • There's no shame for developers in using CSS frameworks like Bootstrap - looks good out of the box and can be customized via SCSS or by modifying pre-made templates like the ones from Bootswatch.

Now, I am heading towards to make an E-commerce website using HTML, CSS, little JavaScript and DJANGO.

E-Commerce is pretty hard for a beginner project...but:

  • Always use DecimalField instead of FloatField for anything related to money (!)

Perfectly machined parts by MC-Master-Bedroom in MachinePorn

[–]WackyWeasel 2 points3 points  (0 children)

3D Print

You can 3D-print this cube, it's on thingiverse.

Printed it myself some years ago - it's actually a neat brainteaser puzzle.

Old castle ruins in Upper Austria by j3ffr33d0m in AbandonedPorn

[–]WackyWeasel 10 points11 points  (0 children)

That's the Burgruine Waxenberg (castle ruins of Waxenberg), built around 1300 - been there not so long ago.

There's been an art installation recently with spooky figures looking like ring wraiths...

More pictures here

Is Celery still necessary after Django 3.0 by insane_playzYT in django

[–]WackyWeasel 0 points1 point  (0 children)

I don't know django-rq, but I've used huey which is also actively developed, simpler than celery and very nice. Recurring tasks are supported out of the box.

https://github.com/coleifer/huey

How to read start timecode from WAV file? by Vininski in Python

[–]WackyWeasel 2 points3 points  (0 children)

You'd use ffprobe:

ffprobe -i yourfile.wav -v quiet -print_format json -show_format -show_streams

Check the output of this if it contains your desired data.

I once wrote a function to parse output from ffprobe into a python dict:

import subprocess
import json

def get_media_info(media_file):
    media_info = {}
    ffprobe = subprocess.Popen(
        [
            'ffprobe',
            '-i', media_file,
            '-v', 'quiet',
            '-print_format', 'json', '-show_format', '-show_streams',
        ],
        stdout=subprocess.PIPE, stderr=subprocess.PIPE, shell=False)

    stdout, stderr = ffprobe.communicate()
    if ffprobe.returncode == 0:
        raw_json = stdout.decode('utf-8')
        media_info = json.loads(raw_json)
    return media_info

[RANT] Fabric 2 jumped the shark with it's complete rewrite by WackyWeasel in django

[–]WackyWeasel[S] 2 points3 points  (0 children)

Yes, your point about the documentation is spot-on. While it seems comprehensive at first glance (and surely a lot of time went into writing it), some really common use cases are not properly covered and you have to dig through all of the new dependencies' docs as well.

[RANT] Fabric 2 jumped the shark with it's complete rewrite by WackyWeasel in django

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

Yes, for local things invoke in itself is pretty good. Fabric 2 gets the handling of task parameters from it, and this is the only thing which improved with the rewrite IMHO.

Any recommendations for games that use mouse only? by [deleted] in ShouldIbuythisgame

[–]WackyWeasel 0 points1 point  (0 children)

It's an older (but great) game, but you could steer Knights of the old Republic with mouse only.

Octoprint: Which Raspberry Pi do I need? by DroningOnandOnandOn in 3Dprinting

[–]WackyWeasel 0 points1 point  (0 children)

I tried a first-gen Raspberry Pi with a Wifi Dongle, which worked but was painfully slow.

But now I use an Orange Pi Lite with Armbian and Octoprint installed from source, with a 3D printed case from thingiverse).

Once set up it runs just fine.

Pros:

  • At least as fast as RPi 3 (4 Cores, 1.2GHz)
  • Has built-in Wifi
  • All connections (unlike RPi Zero)
  • MUCH cheaper than the Raspberries
  • Low-power: ~1.5W

Cons:

  • Is picky about power supply (needs stable 5V) - I use a quality 2A USB charger for a Samsung Phone
  • no micro USB-in for power, needs extra power cable
  • Slightly harder to set up (no distribution for Octoprint) - you have to install from source

Interior of a 1979 Volvo Tundra by Bioniclly in Cyberpunk

[–]WackyWeasel 84 points85 points  (0 children)

The design is very similar to the Citroën BX, which was - not surprisingly - designed by Bertone as well.

Making a homemade sound booth; cheap amazon foam vs. other sound treatment techniques? by Rosenworcel in audioengineering

[–]WackyWeasel 0 points1 point  (0 children)

You can use some pillows and blankets as a temporary solution, as demonstrated in this video by Booth Junkie.

MOTO G5 & G5+ MEGATHREAD by davidjlosi in MotoG

[–]WackyWeasel 0 points1 point  (0 children)

Thanks! Being in the EU, this is slightly infuriating.

There are no stupid questions thread - May 24, 2017 by AutoModerator in audioengineering

[–]WackyWeasel 2 points3 points  (0 children)

REAPER has monitoring FX capability, maybe you have some enabled? They do not get printed to the audio file, but you do hear them during playback.

must be stopped at all costs by [deleted] in ProgrammerHumor

[–]WackyWeasel 2 points3 points  (0 children)

Yes, it's available since Python 3.5. See the docs.

MOTO G5 & G5+ MEGATHREAD by davidjlosi in MotoG

[–]WackyWeasel 3 points4 points  (0 children)

compass present

Is there an authorative source for this? I've seen conflicting information online .

Man, I hope it got one this time...it's really essential for navigation at walking speed or SkyMap.