Cheat Code for Drawing: The NeoLucida Lets You Trace 3D Objects onto Paper

https://s3files.core77.com/blog/images/1183774_81_108682_o4TAclEfe.jpg

A camera lucida is an old-school device that uses a lense and a mirror to let you trace a 3D object in front of you onto a piece of paper below you.

In 1999 artist David Hockney purchased one. After experimenting with it and a camera obscura as well, Hockney released his controversial book Secret Knowledge, where he laid out a case for how old masters–da Vinci, Caravaggio, Ingres, etc.–may have used optical devices to produce their realistic drawings. This became known as the Hockney-Falco thesis, and it’s fascinating.

Portrait of Mme. Baltrad, 1836, Ingres. Traced?

Having read Hockney’s book, in the 2010s artists Pablo Garcia & Golan Levin created, Kickstarted and began selling affordable mass-market camera lucidas to encourage people to experiment with them themselves. Their initial NeoLucida device was tiny and can still be purchased here; they’ve partnered up with Big Idea Design to keep them in production.

They even set up a Facebook group where NeoLucida users could share their work.

More recently they’ve released a larger version called the NeoLucida XL, designed to make the drawing experience a bit more comfortable.

Here’s what it looks like when you look through the device to trace a 3D object onto paper:

It’s better seen in video:

The small NeoLucida is $39, and the NeoLucida XL rings in at $75.

Core77

Defending yourself in a progressive, left-wing environment – Part 2

 

In the first part of this series, I said I’d experienced in several countries the failure of the justice system to support the rule of law, and seen how it was overturned (and in some cases replaced) by the rule of the mob.  We’re seeing precisely that in several US cities right now, so I’d like to present the "lessons learned" in other countries to see whether there are ideas we can use locally.

I’ll start with South Africa from the late 1970’s to the mid-1990’s.  This was a time of massive unrest, not unlike a rolling civil war at times.  Troubles would break out in one place, be suppressed, and then break out in another.  The issue was the white government of the country and its racially discriminatory policies known collectively as apartheid.  They included many laws that criminalized what any democracy would regard as normal and legitimate activities.  Denied any political avenue to protest, opponents of apartheid became more and more radicalized, and turned to the former Soviet Union for inspiration and support.  Increasingly isolated and paranoid, the apartheid government declared itself under a "total onslaught" from external sources, and developed a siege mentality.  Ordinary citizens, particularly black people, became so much cannon fodder for both sides.

For ordinary people like you and I, this was an extraordinarily difficult situation.  They could be living their normal lives, only to find from one day to the next that their residential area had become a battleground.  Outside forces would move in and try to force them to behave in a certain way, or support a particular movement.  If they did not, they were "sellouts" or "stooges".  The government forces would push back, demanding their support for "law and order" (the same law that classified many of them as, effectively, sub-human).  If they objected, or tried to avoid getting caught up in the struggle, they were automatically regarded as suspicious, and might be targeted by both sides.

I recall one incident for which I’ll forever feel guilty.  A labor organizer (illegal under South African law, where trades unions for black people were banned at the time) was arrested by the police.  I knew him, and donated money to his family to help them keep body and soul together while he was in detention.  Tragically, I was seen giving money to his wife;  and township informers immediately assumed that if she was getting money from a white man, it could only mean that she was a police informer.  That night a group of thugs from the local resistance dragged her out of her house, gang-raped her in front of her three children – hacking off her arms at the elbow when she resisted – then poured gasoline over an old tire, put it around her neck, and set fire to it (the dreaded "necklace").  Her horrified children were forced to watch as she burned to death.  They didn’t matter, of course – they were children of a "sell-out".  If only I’d taken greater care not to be seen giving her money, she might still be alive, and they would not have been mentally and emotionally scarred for life by seeing what they did . . . but that was Africa, and it still is in many places.  Human life is still dirt-cheap there.

Many simply "hunkered down" and tried to live through the chaos.  They had no means to resist, and were too afraid to try.  They chose to endure, and many became victims.  Those who had the courage and initiative to stand up against the violence, and try to defend themselves and others against it, took a greater risk, and some paid dearly for it;  but at least they were able to protect their families and groups of like-minded people against the chaos.  I was in the thick of those evil years, and I’ve written about some aspects of them in previous articles:

The first thing that had to be done was to ensure local law and order by keeping as many criminals as possible at a distance.  This wasn’t easy.  In such a lawless environment, many local gangsters set themselves up as warlords, dominating their areas and exacting a toll on residents to fund their criminal lifestyles.  Any resistance was met with savage reprisals.  Sadly, that meant the resistance also became more and more savage.  The Golden Rule tells us to "do to others as you want them to do to you".  If gangsters behave brutally, they must expect brutality in return – and they got it, in spades.

(One example:  A group of young thugs from the so-called Mass Democratic Movement, or MDM, mostly from the Xhosa tribe, decided to attack a meeting of the women’s auxiliary of the Inkatha Freedom Party [a Zulu political organization].  They ran in a loose gaggle up the street, surrounded the hall where the meeting was taking place, and began to force their way in.  Nothing loth, the women [who were typical Zulu "mammies", large, well-muscled and pugnacious] poured out of the hall and gave as good as they got.  I was there, and watched them literally rip fence posts out of the ground to beat up the interfering MDM youngsters.  A group of cops were standing there, watching, enjoying the spectacle [because the MDM was "the enemy" as far as they were concerned].  I asked them why they weren’t intervening to stop the violence, only to receive horrified looks at my stupidity in wanting to intervene in what was a tribal, as well as political, fight.  Several on both sides were severely injured, and a lot of blood was shed – but the MDM’s bully-boy tactics were decisively defeated, at least on that occasion.)

Resisting the gangsters didn’t mean challenging them for control.  There were usually too many of them and not enough resisters.  However, if an area could be made too expensive for them to dominate – because they lost too many people there, or had to commit an inordinate amount of resources to maintain control – they would look for easier pickings elsewhere.  Thus, the gang’s local people were targeted, and beaten up or even killed.  Any replacements met similar fates.  The gangs would try to retaliate, but if they met a united front, they would generally back off.  They had too much to lose, and too much to gain in weaker areas.

Of course, such resistance ran the risk of ending up as a new gang, also performing criminal acts.  This happened with an Islamic group, first calling itself Qibla, then forming PAGAD (People Against Gangsterism And Drugs).  The latter started off as a Muslim welfare society and mutual defense association, but rapidly degenerated into a criminal gang itself.  There were many such, in all communities in South Africa.  It took strong, determined leadership from people such as Inyati to prevent that happening, and keep the group focused on its original purpose – and such leaders were in short supply.

Resistance meant that weapons had to be obtained from somewhere, and defensive positions prepared.  The weapons were usually locally made, unless firearms could be bought, or captured from the opposition and turned against them (a frequent occurrence).  Pangas (a local term for machetes) were acquired (examples made from the leaf springs of heavy trucks were particularly prized for their superior performance);  spears (so-called assegais) were manufactured, in both throwing and stabbing varieties;  and bows and arrows were produced.  I remember one group that made three heavy-duty crossbows from truck leaf springs, including a hard-to-crank windlass to cock them, and rebar projectiles that were sharpened on a grinding wheel.  They were absolutely deadly at short to medium range, with enough power to drive a bolt right through a human body.  Knobkerries, clubs with rounded heads, were very often encountered, and the traditional Zulu isihlangu, a leaf-shaped cowhide shield mounted on a central wooden shaft, was often carried to provide some protection against similar weapons.  Finally, sjamboks – thick, heavy whips traditionally made from hippopotamus hide, but later from other materials, including plastic replicas – were not uncommon, being used by police as well.  A skillful wielder could cut flesh from bone with one of them.

Those weapons might not have been very effective against the AK-47’s and SKS’s of terrorists;  but the battlefield could be "shaped" to aid the defenders and hinder attackers.  Caltrops were a common tool for the purpose, scattered in areas that couldn’t be monitored constantly, or where thick cover like long grass or bushes prevented observation.  They could be easily made from heavy-duty wire or rebar, soldered or welded together by local blacksmiths.  Screams of pain from those impaled on them were useful warnings to pay attention to where they’d been sown.  Molotov cocktails were used to deter vehicles, or to throw at groups of attackers.  The sight of a man turned into a human torch was a very effective dissuader.  Arrows were sometimes used as a deterrent, to keep enemies at a distance.  If, despite all those measures, the enemy managed to get dangerously close, it was time for an attack against them.  A sudden charge from cover, or out of concealment in nearby houses, turned many a fight into a rout.

Of course, casualties had to be expected in such fights.  The defenders were as much at risk as the attackers, and injuries and deaths were simply something to be expected.  However, well-organized groups of defenders, who knew their local area well, had prepared it for defense, and were as well-armed as they could manage, were often able to keep the bad guys at a safe distance.  Knowing they would pay in blood if they tried to intrude, they usually chose areas that were less dangerous.

The South African police were at the time pretty much the enforcement arm of apartheid.  Many of their members were overtly racist, and they didn’t try very hard to protect black townships against this sort of internecine violence.  As far as they were concerned, if blacks turned on other blacks, it worked to their advantage, so why not just let them have at it?  That was no comfort at all to law-abiding citizens in the black townships, of course . . . which is where groups like that with which I worked came into play.  We tried to help the victims of violence, without any political motivation or overtone.  That made us enemies both of the apartheid state, which wanted to "divide and rule", and of the terrorists trying to overthrow apartheid, who wanted to rule by terror and didn’t want anyone being given any hope unless they supported the "resistance".  We lost a lot of dead and injured people in those years.

The lesson we learned was that if you offered no resistance, you would be steamrollered by the forces of violence.  They had no compunction about forcing themselves on entire communities, ruling by violence, intimidation and brutality.  They knew no other language, and would not tolerate any resistance.  One could avoid them in one place by moving to another, but sooner or later they’d turn up there as well.  The only sure defense was to organize with like-minded people to defend one’s families and neighborhoods.  It was literally "fight or die".  Communities that didn’t do that were rapidly overrun, and became victims.

Many of the lessons we learned in South Africa can be applied to the USA as well.  If you look at a Black Lives Matter or Antifa demonstration, they appear to be nothing more or less than the deliberately organized intimidation of white Americans.  The demonstrators know that the authorities are very unlikely to act against them;  rather, the authorities may target those who resist them, as we discussed yesterday.  Therefore, they’re emboldened to become even more provocative, violent and aggressive.  I don’t think that most US police forces are yet at the point where they’ll refuse to intervene to stop major violence against the suburbs, but I think that may be coming.  For example, Minneapolis police reportedly won’t come to your aid if you’re at or near George Floyd Square – they’ll demand that you come to meet them in a safer area.  What happens if you can’t?  It sounds to me as if in that case, you’re on your own.  In how many other cities is that happening?

The form which resistance takes is obviously a troubling factor.  I’m not suggesting that US citizens should become as violent as we encountered in South Africa;  but that will depend very much on how violent the rioters become.  You can’t put out a raging fire by throwing a thimbleful of water at it.  You need sufficient water, at sufficient volume and pressure, to put it out.  The scale of the threat will determine the scale of the response.  However, any major response may well lead to a politically correct justice system targeting the defenders, rather than the attackers.  This applies particularly if they’re stigmatized as "militia" or "right-wing", as seen again just last week.  Again, we discussed this yesterday, and in many of the articles linked there.  This will call for extreme discretion, wherever possible, on the part of defenders.  If they aren’t witnessed or recorded defending themselves or their neighborhood, they can’t be charged with any crime, real or politically trumped-up.

South Africa is just one example where people were forced to rely on themselves to keep the peace.  In the next article in this series, we’ll discuss more cases, from more extreme environments.

Peter

Bayou Renaissance Man

Where do the Russian Accident videos come from?

http://img.youtube.com/vi/fFjl65Sz4Xs/0.jpg

Reader Weetabix asked a most proper question:

Does Youtube just equip all cars in Russia with cameras so they don’t run out of these videos?

My response:

You’d think so. Russia had a gigantic rash of insurance scams in the mid 2000s IRRC. You can actually still find videos of people throwing themselves at cars stopped at lights and to say they got run over and collect big fat settlements. Russians started to install cameras as precaution and thus began the era of the Russian Vehicular Spectaculars.

And here are a couple of compilations.

And they are still at it.

I am thinking very seriously about installing a camera myself. It solves the “He said/ He said” arguments for the insurance.

10 PDF Cheat Sheets for Programmers

https://blog.finxter.com/wp-content/uploads/2018/10/CheatSheet-Python-4-Classes.png

A couple of years ago I fell into the habit of creating cheat sheets when exploring certain areas in the programming space. Over time, hundreds of thousands of Finxters have downloaded and used them in their own learning journeys. However, the cheat sheets are largely scattered around many different locations on the Finxter ecosystem. And even though I share all of them with my beloved Finxter community of ambitious coders and subscribers to my free computer science email academy, join us! 🙂, they may not be accessible at all times for all Finxters. Time to change that!

In this article, I collect all Finxter cheat sheets and links to their PDF download locations. Feel free to share it with your hacker friends and coding mates!

👉 Click each image to open the high-resolution PDF in a new tab!

The Ultimate Python Cheat Sheet

This is my absolute favorite cheat sheet because it teaches you the basics of three fundamental cheat sheets that I just condensed into this single one. Look for yourself:

Python Ultimate Cheat Sheet

Python Keywords Cheat Sheet

Python keywords are reserved words with a special meaning. Make sure to understand all of them by heart!

Python Basic Data Types Cheat Sheet

Programming mastery comes from two things: data and functions. This cheat sheet is about the former!

Python Complex Data Types Cheat Sheet

The complex or container data types in Python are lists, sets, dictionary, and tuples. We’ve written an in-depth guide on each of those if the cheat sheet is too shallow for you:

And here’s the cheat sheet:

Python List Methods Cheat Sheet

A big part of mastering lists is to master the methods provided by the list data structure. You can do this in the cheat sheet or in my in-depth course on Python list methods here.

Python Set Methods Cheat Sheet

Let’s move on to one of the most underutilized data structures in Python: sets. They’re far more efficient than lists—if you can handle the reduced expressiveness. You can find all set methods explained in detail in the Finxter Academy course.

Python Set Methods Cheat Sheet

Python Object Orientation Terminology Cheat Sheet

We need to use the right words to communicate effectively with other programmers. This cheat sheet will show you all the words you need to know in object orientation!

Python Classes Cheat Sheet

Let’s really dive into two concepts of object-oriented programming: classes and objects. These things are must-knows for you as an effective programmer!

Python Functions and Tricks Cheat Sheet

CheatSheet Python 5 - Functions and Tricks

Python Interview Questions Cheat Sheet

Python NumPy Cheat Sheet

Python Book Simplicity Cheat Sheet

Python 6 Machine Learning Algorithms Cheat Sheet

Python Support Vector Machines Cheat Sheet

Python Git Cheat Sheet

Git Cheat Sheet

Python Plotly Dash Cheat Sheet

Python Plotly Dash Cheat Sheet

That’s it for now—I’ll keep updating new cheat sheets as I produce them. Stay tuned to make sure to be informed about each new Cheat Sheet I publish on the Finxter blog.

You can also check out these interesting blog articles about cheat sheets—many with videos:

Thanks for checking out the whole article—let’s round this up with the standard Finxter “post footer”. 😉

The post 10 PDF Cheat Sheets for Programmers first appeared on Finxter.Finxter

How to Replace Your Pistol Sights

https://www.recoilweb.com/wp-content/uploads/2021/05/replacing-pistol-sights-11.jpg

Most handguns come with factory sights that are pretty rudimentary, and they’re often the first thing to be replaced. Perhaps you want to see your pistol sights better in diminished light, to acquire them quickly in bright daylight, to use them to rack the slide, or even to adjust them on the fly. There are many aftermarket options for most pistols; find one that best suits your intended use of your handgun. 

If you plan on shooting competitions at your local outdoor range, a thin, front fiber-optic sight might work best. However, if you also want to take the gun to tactical shooting courses where you’ll be racking the slide off barricades and treating
your gun like a Harbor Freight tool, you might want something a bit beefier. Choose pistol sights that are a good fit for you, because even a great handgun can be ruined with a poor aiming system. 

BASICS

The majority of pistol sights are secured in a dovetail cut — an isosceles trapezoid shape cut from left to right with the long side at the bottom, creating two angled overhangs that prevent the sight from moving up and down or fore and aft. Let’s discuss how to remove your old sight and install or “drift” in new ones.

how to replace your pistol sights

Most sights are considered “drop-in” parts, which can be installed without any customization. However, slight fitting is sometimes required. When removing material to install sights, fit the sight to the gun, not the gun to the sight. Also, never touch the bottom of the sight dovetail. There should always be a slight gap between the underside of the sight post and the top of the slide; removing material from the bottom of the dovetail will pull the post downward, interfering with the top of the slide.

TOOL SELECTION

There are many gadgets available to install sights. “Universal” sight pushers can be handy but also rather expensive (upward of $100), and often not quite universal. Dedicated sight pushers aside, you can remove and install sights with some basic tools:

Sturdy vise: If you intend to work on firearms, a good vise is a must, preferably with at least 4-inch jaws. It should be hefty, so that when you clamp it down on something and hit it with a hammer, the vise won’t flex. This ensures all the force is transmitted to the workpiece; otherwise, it’s like trying to crack walnuts with a hammer on a mattress. When mounting a vise to a bench, try to locate it on a corner, directly above the leg, for maximum rigidity. Most vises come with scored jaws that bite into wood and rough material but will damage your slide’s finish, and a couple layers of tape won’t protect your bluing or Cerakote. You can take the jaws to a machinist to smooth off the texture or use soft jaws.

pistol slide in a vice

A layer of masking tape gives a little protection to your slide’s finish, or in the case of a HiPoint, prevents it from getting crap on your vice.

4-ounce ball-peen hammer: This hammer might seem dainty, but it’s the preferred striking weapon of gunsmiths for a reason. It allows much more control and finesse while keeping you out of trouble. Keep the flat face dressed with a stone to ensure good perpendicular contact and to avoid glancing hits, which can lead to shattered punches or uneven contact on the punch face.

Drift punch set: There are many different types of drift punches for drifting sights, but it’s hard to beat a simple set of steel Starrett punches. Nylon-tipped, brass, and most aluminum punches are too soft and require extra force to finely control small movements of the sight, often causing them to flex or compress. 

tool selection

If you’re going to start messing with sights (and on stock Glocks, we should really put that in quotes), then you’re going to need a few basic tools.

Fine triangle file: Hopefully, your slide cuts and the sight’s dovetail will be the perfect size for a slight interference fit, allowing for hassle-free installation and solid retention. When fitting is needed, use a fine, single-cut triangle file that cuts smoothly while taking a minimum of material. Grind one side of the file smooth to use as your “safe” side. If the sight is a 60-degree dovetail, use the bottom of the sight post as a guide for a consistent, clean cut. If you have one, a triangle India stone is also handy for dressing the dovetail.  

6-inch calipers: Dial or electronic calipers allow you to precisely position the pistol sights on the slide. While not as accurate as a depth micrometer, the depth rod on the tail of the caliper will get you within a couple thousandths. 

REMOVAL

Before you start, put on eye protection, then unload your pistol, making sure to remove the magazine and clear the chamber. Then, remove the slide, recoil spring, and barrel. Attach a strip of painter’s tape on the slide flats on each side just below the sight dovetails, to provide some protection.

how to replace your pistol sights

If you care about your handgun, grind a safe edge on your triangle file so that it only cuts on one surface at a time.

Carefully inspect both the top and the bottom of the slide around the sights. Some factory sights are further retained in the dovetail with a set screw or vertical roll pin. If so, carefully remove them. If you have an elevation-adjustable rear sight, remove the adjustment screw and spring, tilt it up to check for additional set screws underneath, and remove those as well. Make sure to use the proper hex wrench to avoid stripping them. If you suspect there’s any threadlocker, apply heat to break it up. 

Mount the slide in the vise with the right side toward the base of the vise and the bottom of the sights as close to the top of the jaws as possible. The closer they are to the jaws, the less flex you’ll get in the workpiece. The rear sights are a good place to start. They usually have a much larger flat area on the sides, so you can use a larger diameter punch to transfer more energy.

handgun slide in vice

You might find that the dovetail cut on some slides is tapered; it’s easier to detect this and determine which direction it tapers on the rear sights. Pins are often installed from right to left, so it’s a good idea to first attempt to drift the sight out to the right. With the largest punch that fits inside the dovetail, place the face squarely against the sight. Full contact between the punch face and the workpiece spreads the load out and ensures maximum energy transfer.

While many people place the punch once and start wailing, try removing the punch between each strike to check for any damage (in the case of soft or cast sights), and then adjust your position or reset and hit it again. You don’t need to swing for the fences either; if you have a rigid setup, the sight should start to move quite easily. A firm 6- to 8-inch swing is typically all you need to break the static friction. If it doesn’t budge, increase your striking force gradually in small increments. If it doesn’t seem to get easier, or it doesn’t move at all, reverse the slide in the vise (so that you’re always hammering toward the base of the vise) and try from the other side.

aluminum punches

This is what specialist aluminum punches look like after they’ve been used on handgun sights a few times. Save your money.

Once you get it moving, pay attention to the area that’s revealed as the sight moves to the side. On some pistols, there are small springs under tension beneath the rear sight. If you see the edge of a spring, move your pinky or ring finger over the hole while you push the sight to capture it.

The front sight will drift out in the same direction, but you’ll have less to work with, so you might need a smaller punch. The dovetail portion is typically quite shallow, so if you don’t feel comfortable striking it there, go as low as possible on the vertical portion of the sight. Avoid the inclination to place the edge of the punch on the dovetail, as it’ll usually swage the thinner material before it moves the sight. In this case, a flathead screwdriver might be better to increase the contact area on the dovetail or the bottom of the sight. The higher you strike the front sight, the more likely the sight post will bend or snap at the junction. Once the sights are removed, clean the dovetail slot with acetone and Q-tips. 

INSTALLATION

Make sure you read the sight manufacturer’s documentation before you install them, in case there are any special instructions. Check the edges of the dovetails on the sights. If they seem sharp or don’t have a slight radius, you can hit them with a stone or some 320-grit sandpaper to achieve about a 0.005-inch radius. This will give the corners some clearance, so they don’t catch and gall in the dovetail cut.

how to replace your pistol sights

Don’t try to remove your front sight until you’re certain any set screw has been backed out.

Test-fit the sights by hand to see if they start in the dovetail without issue. A rule of thumb is that the pistol sights should slide in under finger pressure between one-third to just about halfway. If they do, remove the sights and apply a small amount of lube on the dovetail surfaces to prevent galling, then install them as far as they’ll go under finger pressure. Using the same technique as removal, drift the sights in until they align with any secondary retention devices or until it looks reasonably centered.

how to replace your pistol sights rear set screw

That goes for your rear sight, too.

If you find that the sight slips all the way through with little resistance, but doesn’t seem to be loose, don’t worry! You have two options. You can liberally apply some blue threadlocker to the dovetail cut, install the sight, and take the edge of a punch or a small screwdriver with a broad edge and swage the slide material to crimp the slide material down on the sight. Select a spot that’ll be hard to notice, preferably on either side of the vertical post of the sight. Then, wipe away excess threadlocker. However, if intentionally denting your slide is a little too extreme, you can try the threadlocker by itself, though this can have mixed results. When the threadlocker hardens, the crystalline structure is susceptible to cracking from the shock of the slide going into and out of battery.

how to replace your pistol sights

If your sight goes in less than one-fourth of the way or doesn’t go in at all, first double check you have the correct replacement sight. If so, it’s time to bust out your file. Using the safe side up against the bottom of the sight post, gradually begin to remove material on only one side of the dovetail. Remember that your file only cuts one way, so don’t saw back and forth — this will kick up burrs that’ll mislead you during fitting, and you’ll end up removing too much material. Focus on smooth, linear strokes and follow the line of the material. Take three to five good swipes, wipe it clean, and check fitment. Continue this process until you can push the sight in far enough using finger pressure.

ALIGNMENT

Once you have both pistol sights installed and close to center, you can perform an initial alignment, assuming they aren’t constrained by some sort of secondary retention. Using the depth rod on your calipers, measure from the flat of the slide to the flat of the side of the sight. Then, take the same measurement on the other side of the slide. Calculate the difference between those two measurements and divide it by two. The result is how much farther you need to push the sight in from the side with the lesser measurement. 

centering handgun rear sight

Use the tail of your caliper to ensure the sight is centered in its dovetail to get a working mechanical zero.

Small taps and a lot of patience are key. If your pistol sights seem like they stutter or jump when attempting small adjustments, apply localized heat with a propane torch. Concentrate the heat in front and behind the dovetail cut. Mechanical center is just an initial alignment because slides and barrels don’t always line up exactly when in full battery. Take a trip to the range to see where your rounds impact in order to make your final adjustments. 

If rounds are landing left or right of where you’re aiming, you need to adjust windage, by drifting either the front or rear sight. Alternately, adjustable rear pistol sights may have a screw to adjust windage. If rounds hit high or low, adjust your elevation. With an adjustable rear sight, you can dial in the needed change. If it’s fixed, you’ll have to swap in a shorter or taller front sight to adjust your elevation. 

If you’re good at math, you can calculate the necessary sight adjustments given your sight radius, distance to target, and deviation from point of aim to point of impact. Or just use the handy online sight calculators on Dawson Precision’s and Dillon Precision’s websites. During and after your first couple range trips, admire your handiwork and periodically check your pistol sights for any looseness or movement. Once you’re confident in your sights, grab some ammo and go get some! 

 


More How-To’s and DIY Upgrades

Recoil

Tryton News: Tryton Release 6.0

https://discuss-cdn.tryton.org/uploads/default/optimized/2X/7/767d3c8cb2da36cbfd3eae39bc14aadc6bde349b_2_690x459.jpeg

We are proud to announce the 6.0 Long Term Support release of Tryton .
This release provides many bug fixes and some significant improvements. Among other changes you will find the display of attached documents, reinforced security and many accounting improvements. There are also no more than 11 new modules that include support for things such as Incoterms, Avatars and Product kits. Tryton has now also been translated into Romanian which brings the number of languages to 24.
You can give it a try on the demo server, use the docker image or download it here.
As usual migration from previous series is fully supported. Some manual operations may be required, see Migration from 5.8 to 6.0.

Here is a list of the most noticeable changes:

Changes for the User

The clients can now display documents inside a form. The supported document formats are dependent on the client. For the web client it is the one supported by the browser (usually images and pdfs). And for the desktop client it is also images and the formats supported by Evince.

Thanks to the document widget, it is possible to display, next to any form, a preview of the attachments. This can be used, for example, when entering a supplier invoice from the attached PDF.

When sending an email from the client, in addition to being able to attach any report, it is now possible to also attach any of the record’s attachments.

More

The dialog opened under a revision show in their title the revision.

When exporting into CSV file a tree, the first column is indented according to its level in the tree.

When opening many dialog, the title is now composed of a breadcrumb trail of all the dialog opened before. This avoid to loose the user in his navigation.

The name of the tabs opened from the menu is now the name of the menu entry.

Web Client

The CSV export and import dialog can now be reordered using drag and drop.

The web client can now also propose completion for the search input of the xxx2Many and Dict widgets.

The email and URL widgets now use the appropriate input type. So that mobile devices can display the best virtual keyboard.

More

Each selection entry can display its own help text.

Desktop Client

When printing reports that are single (like the invoice), the server sends a zip file containing one document for each record. The client now recognizes these files and can send each file from the zip to the printer.

When running the client on UNIX platforms, it is now possible to use the direct print feature. The client will uses the lp or lpr commands and for OpenDocuments it uses soffice. (It continues to use the print command on Windows).

Some reports can take a long time to generate so the client runs them with an asynchronous request. This allows the user to still perform other operations while the report is being generated.

An interactive search has been added to the list and tree views. It pops up when you start to type on the list and puts the focus on the first line which matches the results. You can jump to the next matching entry with <CTRL>+↓ and previous with <CTRL>+↑.

Accounting

The Income Statement and Balance Sheet can now be printed. Only the records that are open in the client are printed.

The general journal is now printed from a list of moves. This adds, as a nice side effect, the ability to print a single move if needed.

The General Ledger (accounts and lines) can now be filtered by journal. And from the lines it is also possible to perform a reconciliation.

The terms on the Aged Balance can now be expressed in weeks and years in addition to the existing days and months.

The Spanish accounting module now provides a report for the VAT book.

Companies can not always deduct the full amount of the taxes on supplier invoices. We now allow the accountant to set the deductible rate of each invoice line. You can set a default value for the rate on the product category.
Some companies can never deduct taxes, thus they can be configured to always use a 0% deductible rate.

It is now possible to make the link between invoice lines and stock moves after they have been posted and done. In these cases the unit price is also updated on the stock move, and if needed the cost price will be recalculated.

More

Account type from balance statement can be marked as debt. So they can be used directly to book invoices.

It is now possible to open directly from a party his general ledger accounts.

The balance of the general ledger lines start with the start value of the account.

The reconciliation sequence can now be set in the accounting configuration.

Once a move has been numbered, it is no more allowed to change its journal. This is because the numbering is based on the journal.

It is now possible to define an other date than the invoice date to use to compute the payment term for an invoice.

If you try to post a customer invoice with a maturity date in the past, Tryton will raise a warning.

We added a summary field on the invoice line list that display the first line of the description.

It is now possible to define a default customer payment term for all parties that have no term defined.

When the supplier sent an invoice to correct a price, it is now possible to mark it as correction. In this case the quantity will not be counted to compute the cost price on the related stock moves.

The payments record now the employees who approved, noted as succeeded or failure them.

The customer record of Braintree and Stripe are now kept up to date.

We warn the user when he posts a statement linked to a cancelled or already paid invoice.

The origin of the move line are now filled with the statement line.

The analytic lines are now filled for the closing move of an asset.

Commission

The date of the commission now uses the invoice date if the method is “on posting” and the payment date if the method is “on payment”. This is more coherent than using the date when the commission was generated.

Company

The users can now choose if they want to see only records for their current company or for all their companies.

It is now optional to define a number of hours in a working day, week, month and year.

Currency

You can configure a scheduled task to fetch currency rates at a specific frequency. By default it gets the rates from the European Central Bank.

Marketing

The marketing emails can now use the same formatting methods as the report.

Party

An specific contact mechanism can be used as email recipient. This is useful for example to send the sale order notifications to the email of the contact who placed the order instead to the generic one of the customer.
For that we added also an optional language to the contact mechanism to be used instead of the language of the linked party.

More

We added the new identifiers available from python-stdnum.

Product

When you deactivate a product, its variants are also automatically deactivated.

From the category view, it is now possible to add or remove products. This is useful when you have a lot of products that needs to be categorized.

It is now possible to use the list price of the product form in the formula of the price list. This is useful for businesses that have regulated prices (e.g. books in France).

Production

You can define a scheduled task that will try to automatically assign any productions that are planned for today. The productions that can not be fully assigned are listed in a new “Partially Assigned” tab.

More

The productions are now ordered by date.

Project

When invoicing a project based on the time-sheets, it is now possible to define for each work a date that limits the time-sheets invoiced. This date can be set, for example, once the customer has accepted the work done up to that date.

Purchase

When creating a return of a purchase, the original purchase is linked to the return.

You can now define a default lead time for each supplier. This is used when the product does not have a specific lead time set for that supplier.

The payment term and invoice method are now set by default based on the last purchases made from the supplier.

The amendment mechanism now supports changing lines without a product.

It is now easier to manually change the shipment cost of a purchase. A check box has been added to allow the price to be manually altered and to prevent any automatic re-calculation.

More

We added a summary field on the purchase and requisition line lists that display the first line of the description.

We added a relate to open purchase from a request and vice-versa.

The product supplier can now be deactivated.

Sale

You can now configure a global lead time. This is used for products that have no specific lead time.

The amendment mechanism now supports changing lines without a product.

The complaint action to credit the customer now make an invoice correction. This improves the product margin statistics.
The amount of the complaint action is now calculated automatically. This makes it easier to decide whether to validate the complaint, or not.

It is now possible to create promotions that are based on the total amount of the sale. The shipment cost can be excluded from these promotions.

We now only add the unsold shipment cost to the outgoing moves following the shipment cost method. The cost of the shipment for the company is calculated using the purchase price of the carrier. And the shipment cost for the sale can be free (price of zero).
It is now easier to manually change the shipment cost of a sale. A check box has been added to allow the cost to be altered and to prevent any automatic recalculation.

More

We added a summary field on the sale line lists that display the first line of the description.

The complaint type and product customer can now be deactivated.

It is now possible to set the sale line of a shipment cost to 0.

The carrier is now displayed on the shipment list. This is useful when you must prepare the shipment of a specific carrier in priority.

By default the shipment cost is now excluded from the promotion amount.

The effective date of drop shipment can now be defined.

It is now possible to open the drop shipments of a party from its form.

Stock

You can now define a scheduled task that tries to automatically assign all the shipments that are planned for today. The shipments that could not be fully assigned are listed in a “Partially Assigned” tab.

The graph that shows a product’s quantities over time of for each warehouse, can now display this for multiple products on the same graph. This is useful when comparing different products or if you want to analyze the scheduling of a shipment composed of multiple products.

We added a report that calculates the margin of goods by product or category.

As a counterpart to manually assigning a shipment, it is now possible to also manually unassign a shipment. The wizard asks, for each assigned move, the quantity to unassign and then restores an original move for this quantity.

When you use stock lots as a serial number, it can be time consuming to split the moves and add a lot for each unit. So we added a wizard to make this task easier. The wizard can also automatically generate the lot number using a sequence defined on the product.

You can now define the package used for a supplier shipment returns.

More

We added a relate from an assigned shipment that opens the quantities by warehouse for the products on the shipment.

The shipments are now ordered by default by date.

The contact mechanism can be defined for delivery usage.

When the storage and output zone are the same, the outgoing moves of customer shipments are now still editable in waiting and packed state.

The move list of the product quantities by warehouse display now the document from where they originate.

A sequence to automatically number lot can be configured on each product.

We now include the additional weight of the package to the total weight of a parcel.

The packages have now a field that contains the tracking URL.

The dimension of a package can be modified from the default value set for its type. This is useful to store for example the height of a pallet.

It is now possible to configure the product and format to use for a DPD carrier.

Timesheet

We added a tab on the time-sheet works to list the “Open” and “Closed” work.

More

The active field has been removed from the time-sheet work as it was redundant with the start and end dates.

New Modules

Account Invoice Defer

The Account Invoice Defer Module allows an invoice line’s expenses or revenues to be deferred over many periods.

Carrier Subdivision

The Carrier Subdivision Module extends the carrier selection pattern with the subdivision and the postal code.
These can be used to restrict the usage of a carrier to a specific subdivision or specific postal code.

Incoterm

This Incoterm Model is used to manage the Incoterms on sales, purchases and shipments. The module contains the Incoterms versions 2010 and 2020.

Party Avatar

The Party Avatar Module adds an avatar to each party.

Product Cost Warehouse

The Product Cost Warehouse Module allows the cost price of products to be calculated separately for each warehouse.

Product Kit

The Product Kit Module adds kits and components to products. This enables a defined set of products to be sold or purchased using a single line.

Purchase Price List

The Purchase Price List Module allows price lists to be defined for suppliers.

Sale Gift Card

The Sale Gift Card Module manages the selling and redeeming of gift cards.

Stock Quantity Early Planning

The Stock Quantity Early Planning Module helps reduce stock levels by suggesting where stock can be consumed earlier.

Stock Quantity Issue

The Stock Quantity Issue Module helps to solve stock quantity issues.

Stock Shipment Cost

The Stock Shipment Cost Module adds a shipment cost on the outgoing moves. This cost is added to the product margin reports.

Changes for the System Administrator

The Tryton server now includes protection of trusted devices against brute force attack mitigation. This means that these devices (which have been authenticated once) are not delayed by anonymous brute force attack.

A new curses command trytond-stat has been added which displays some statistics about the running trytond. For now it displays the running requests. This is useful to detect those that are taking too much time. It also displays how performant the caches are by showing the number of hits, misses and the ratio.

The user groups can now inherit access permissions from another group. This is used by the “Administrator” version of a group to extend the rights of the normal group.

More

It is now possible to define the email’s FROM per language.

The trytond-admin command has a new option --validate that can be used to validate all the records or a random percentage. This is useful to verify that a migration was correct.

Currency

We added a new parameter rate_decimal which defines the number of decimal places that are used to store currency exchange rates. This is useful when using currencies that needs more than 6 decimals places for conversion.

Party

We received some feedback about users getting lost when selecting from the large list of identifiers available in Tryton when they were only interested in local identifiers. So we added a configuration option to define which types of identifiers are available for use.

Stock

The shipping labels can now be stored in the filestore instead of the database thanks to a configuration parameter. This helps reduce the size of the database.

Changes for the Developer

Tryton supports now Python 3.9.

We unified the string format of PYSON between all the implementations.

It is now possible to use a URL as source for icon. The target image is then cached by the client. This is used to implement the avatar feature.

The data passed to ir.action now also contains the context model used and the paths (as a tree) of the selected records.
The actions can now define that they run on the selected records (default and historical behavior) or the listed records. The last one is used, for example, to print a tree structure as the user has it open.

We use now immutable data-structures for Dict and MultiSelection fields. This enforces good practice because the framework cannot detect modifications on those mutable values.

Thanks to the new context item _skip_warnings, non-interactive operations (like scheduled tasks, queue jobs etc.) are no longer blocked by warnings which have no user to ignore them.

The record rules are now only applied if _check_access is set in the context. This improves the multi-company support.

We added a new Mixin to add support for avatars on any ModelStorage. This exposes the avatar on a public but anonymized URL. This URL accepts a parameter to resize the image on request and automatically store the result in a cache. It can also generate a pseudo-random avatar using, by default, the record name.

The ORM now supports full text and similarity searches if the database back-end support it. This is used automatically for searches using ilike and a clause %…%. The similarity threshold is set by default to 0.3.
A new type of field has also been added – FullText. This stores, in the database, a list of strings representing the document as a vector so that indexes can be defined to improve searching and ordering on it.

We added the __access__ attribute to Model which contains a set of relation fields to which the access rights are delegated. This is used, for example, when a document is designed with multiple models like sale orders which are made up from Sale and SaleLine. Here the SaleLine delegates its access rights to the Sale.

More

The method to get the next sequence value is now an instance method.

The sequence type is now stored as a Many2One on the sequence.

A new route wrapper has been added to accept null as origin of a request. This is needed for add-ons application like Chronos.

The method ModelView.parse_view is now officially public.

Each value of a selection of multiselection can now have its own help text.

The trigonometric functions have been added to the SQLite back-end.

When a process change the list of activated modules, the others must refresh their pool.

A new method on Cache allows to clear all the cache instances.

The HTML editor supports now the Genshi element directives.

A new tool has been added firstline which return the first non empty line of a text.

When browsing ModelStorage instances, no access rights are enforced.

When multiple Function fields have the same getter we eagerly compute them.

The decorator button_change accepts now to depends on other methods like the other decorators.

It is now supported to use the standard Python copy method to copy Model instances.

When the server generates a default form view for a ModelView, it includes now automatically all the buttons.

All white spaces except space are forbidden on Char fields.

The Report can now group the rendering of a list of records by header keys. This is useful when OpenDocument templates the header and footer which are global for the whole document.

The URI to configure the database connection supports now parameters.

The table handler can not test the SQL type of a column. This is useful to decide to make a migration or not.

The timedelta converter supports now to have empty value for some keys.

Web Client

We removed the dependency to tempusdominus. Instead we use the HTML standard date and date-time inputs.

Accounting

The Move.query_get filter is now also based on the journal key in the context.

The method call_deposit now accepts an optional maximum amount to recall.

A new method has been added to Invoice to post invoices by batch. On large installations posting invoices can become a bottleneck due to the strict sequence constraint. With this batch method it is possible to speed up the process by reducing the time spent locking the invoice sequence.

More

We removed the foreign key constraint for the sequence link on Invoice. It creates new lock contention for no benefit.

The zip code in Stripe checkout has been removed because it was not used.

It is now possible to define the preferred locales to the Stripe Customer.

We do not create anymore account moves for the stock with a single empty line.

Company

We removed the tree structure from Company and replaced it with a flat list of companies that user has access to.

We added a generic test which ensures the definition of record rules for company related models.
We also added another generic test that checks if fields targeting company multivalue models have a company context defined.
It is highly advised to use this test mixin if your custom module depends on company.

We now use the report header feature on the CompanyReport instead of relying on the contextual company value. This now means that records on which these reports are based, must have a company field.

Country

We renamed the “Zip” model into “Postal Code” which is more generic.

Party

We renamed the “Zip” field into “Postal Code” which is more generic.

We implemented a simple distance field on the party module which is fully extended in the party_relationship module. This allows for other modules to implement distance behavior without having to depend on party_relationship.

Sale

We added the TaxableMixin to the sale line. This is used to base promotions on an amount without or without taxes.

Stock

We added a dedicated model for the “Products by Locations” and “Lots by Location” reports which makes it easier to customize compared to using the product or lot model.

More

We renamed the quantity_added to quantity in the inventory counting wizard.

1 post – 1 participant

Read full topic

Planet Python

Hot Wheels Roller Coaster

https://theawesomer.com/photos/2021/05/hot_wheels_roller_coaster_t.jpg

Hot Wheels Roller Coaster

Link

Readers have commented that we called things roller coasters that are actually trains since they’re self-powered. Well, here’s a case where we’re using the term properly. This impressive Hot Wheels track by 5MadMovieMakers keeps cars moving with gravity, a handful of motorized booster stations, and… a leaf blower.

The Awesomer