just another web log

15 May 2024:
geolocation with just docker redis and a json file
docker exec my-redis 'redis-cli' 'GEOADD' 'location' '51.51452633138356' '-0.09850080369320617' 'st-pauls' docker exec my-redis 'redis-cli' 'GEOADD' 'location' '53.3869683450906' '-1.4896723908551361' 'oxford-house' docker exec my-redis 'redis-cli' 'GEOADD' 'location' '56.34028949355843' '-2.7883787054016342' 'st-andrews' Not we have three, slightly random locations loaded into *redis*, let's get the rider's positions. curl -s "https://example.com/latest.json?i=$(date +%N)" -o /tmp/rider.json Note: I have removed the actual domain name. Now we can extract the juicy location data and store it in *redis* docker exec my-redis 'redis-cli' 'GEOADD' 'location' $(jq '.latitude' /tmp/rider.json) $(jq '.longitude' /tmp/rider.json) 'riders' I will go into a bit more detail about how this works at the end. But in the meantime we want those measurements... docker exec my-redis 'redis-cli' 'GEODIST' 'location' 'riders' 'st-pauls' 'mi' docker exec my-redis 'redis-cli' 'GEODIST' 'location' 'riders' 'oxford-house' 'mi' docker exec my-redis 'redis-cli' 'GEODIST' 'location' 'riders' 'st-andrews' 'mi' The results are printed in Miles due to the specifier **'mi'** Time to stop the docker container and delete it. docker stop my-redis docker rm my-redis If you made it this far you may want a little more detail. *redis* has a command line interface that can be accessed by running redis-cli Running this normally drops you into an interactive shell where only *redis* commands work, but what we want is to execute specific commands from outside the container. docker exec CONTAINER Runs a command within the selected container and to accept parameters to be used by the command we simply provide a space separated list. docker exec my-redis 'redis-cli' 'GEOADD' 'location' $(jq '.latitude' /tmp/rider.json) $(jq '.longitude' /tmp/rider.json) 'riders' runs the **redis-cli** command in the **my-redis** container and passes the **GEOADD** redis action, setting a **location** to have the space separated *lat*/*long* that was pulled from the file we downloaded and sets it all to the key **riders** jq accepts a query path and in our example that is simply **latitude** for the first value and **longitude** for the second.
12 May 2024:
Vinted addiction affects my life


I have been cursed with knowledge. The mobile app known as Vinted now resides on my phone. It sits there innocently, teasing my eyeballs for a small dopamine hit...

But what is Vinted or more to point, where did it come from?

In 2008, Milda was moving house, but had too many clothes to take with her. Justas offered help and built a website to give away her clothes to friends. Soon enough, the media wanted in, too. The duo knew they were on to something Vinted was born.

(quote from the company website)

From Lithuania to other Nordic countries and from there to the whole of Europe, the UK and USA.

I saw small amounts of advertising where it was always on the subject of second hand clothes. Not really my thing, due to size constraints and a lack of interest in fashion brands. But a certain someone suggested it for cheap t-shirts after they had had good success with purchasing jeans and other items from Vinted.

OK, time for a quick look... Ooo, they do have a lot of choice and in my size and many styles I would wear. From Marvel/DC/Starwars to Aliens/Back to the Future/2000AD and much much more.

And the amount of new items being uploaded is huge. You can spend 5 minutes scrolling through the latest items and then refresh and see 10s if not hundreds more. But not necessarily clothes ...

After watching the Live-Action and then the complete series of Avatar the Last Airbender recently, I was interested in what Avatar items Vinted had. Perhaps unsurprisingly it was mostly items from a James Cameron's Avatar universe, but there were Aang related items... So I sorted by latest and then Price High to Low .

Vinted Avatar baby with dress

Vinted Avatar baby with loin cloth

Vinted Avatar baby nude - censored

Vinted Avatar baby twins

Who is the market for those? I am not sure I want to know. These were all from different sellers and marked as hand-made .

There is other weird stuff, but I could start a YouTube channel and never run out of items to cover. And, this is just Vinted in the UK!

Vinted pig clock

Vinted shoes with eyes

Vinted burger shoes with eyes

Vinted tiny newborn

Vinted coca cola phone

Some sellers go to great lengths to take clear and useful photos, others ... I am not sure they understand what is going on.

Vinted bad contrast

It's like a car-boot sale, only there is much much more out there, in fact it seems to never end. Americans may relate to this as multiple yard sales . As with all market places there are some people who charge a fortune and hardly sell anything and there are those who are more than willing drop the price to just get rid of old collectables to free up space.

And the moment a market place gets big enough the parasites move in to prey on the unwary.

There are various scams, not mention the basic Caveat emptor . It is very easy to see a bargain and try and snap it it up before anyone else, only to find that you did not read the description and you got exactly what you agreed to, but not what you wanted.

The most well know scam on Vinted is the "paper plate scam". Where your order is delivered, but when you open the package there is only a paper plate. Vinted tries to combat this by requesting the buyer select an "Everything is OK" button in the app before any money is transferred to the seller. This is no good for outright fakes, as the buyer may not realise before clicking the button.

It is also risky for the seller. A buyer swears blindly that the parcel was not delivered or was damaged in transit. That last one swings both ways. I have had items delivered damaged and when I have followed the straight forward reporting process and provided photos of the damaged items, I have received a full refund. No idea if the seller got any money.

The message from Vinted implied that is was the sellers responsibility to recover the money from the courier company.

I did see a large number of what appeared to be bot behaviour. I would click on a really good bargain (yes, Funko Pops) the sale would be approved and strangely the status would immediately be set to Sent . Looking at the other items the seller had and there would ALWAYS be a least one Xbox/Playstation a selection of watches and ... a creepy Reborn doll. The scam is wait and see if the buyer notices or if the scammer can just claim to Vinted that the buyer is forgetting to click the "Everything is OK" button and to just release the money.

Oddly all the prices on these items was never .00, which most second hand items are. You could see the patterns only if you were watching closely. For instance when viewing a non-scammers items, nearly all the backgrounds to the photos would be the same. The scammers having stolen the photos from different sellers would have wildly different backgrounds, quality etc.

Vinted tries to match photos to ones it has seen before. This explains why all the bot photos have a 50px border of smudged pixels.

I currently have the Vinted app limited to 30 minutes a day. That means after 29 minutes of use the phone screen turns monochrome and a message alerts that the app will shut. This is necessary to stop me scrolling for Funko Pops and then refreshing and refreshing and buying and buying.

Finally the couriers. When you sign up for Vinted you get a discount on P&P, but after that the price goes up and then it seems to go up again. There are various options a seller can use for their courier including ones that will deliver to postage lockers rather than your house. I currently opt heavily for the lockers to save a quid here and there.

Is it safe? Well I have had 8 refunds, two from damaged items and 6 from sellers who did not send me anything. I have got a lot of great bargains and I am very happy with the value the app provides. I am slightly concerned about the fact that I have ordered over 30 times in the last 3 months...

loading results, please wait loading animateloading animateloading animate
[More tags]
rss feed



flog archives

Disclaimer: This page is by me for me, if you are not me then please be aware of the following
I am not responsible for anything that works or does not work including files and pages made available at www.jumpstation.co.uk I am also not responsible for any information(or what you or others do with it) available at www.jumpstation.co.uk In fact I'm not responsible for anything ever, so there!