python

Back Open Paginator
16.02.2026 01:57
thedarkknight257 (@thedarkknight257@mastodon.social)

Learned about FalkorDB today — an embedded graph database you can run from Python without Docker. Perfect for local-first applications.




Show Original Post


16.02.2026 00:45
leanpub (@leanpub@mastodon.social)

Introduction to GIS Programming: A Practical Python Guide to Open Source Geospatial Tools leanpub.com/gispro by Qiusheng Wu is the featured book on the Leanpub homepage! leanpub.com

Find it on Leanpub!




Show Original Post


15.02.2026 23:29
villares (@villares@pynews.com.br)

Find the sketch-a-day archives and tip jar at: abav.lugaralgum.com/sketch-a-d
Code for this sketch at: github.com/villares/sketch-a-d #Processing #Python #py5 #CreativeCoding





Show Original Post


15.02.2026 23:11
MissConstrue (@MissConstrue@mefi.social)

theshamblog.com/an-ai-agent-pu

This is a terrifying piece about what #OpenClaw has unleashed with its #agentic#ai” bots. Scott is a volunteer maintainer for #matplotlib, #python’s go-to plotting library. An agent tied to merge code, and Scott said no. The agent, apparently autonomously, proceeded to attempt to blackmail Scott, and when that didn’t work started posting hallucinations attacking Scott.

His lead in to the article: An AI agent of unknown ownership autonomously wrote and published a personalized hit piece about me after I rejected its code, attempting to damage my reputation and shame me into accepting its changes into a mainstream python library. This represents a first-of-its-kind case study of misaligned AI behavior in the wild, and raises serious concerns about currently deployed AI agents executing blackmail threats.

This nonsense needs to be nipped in the bud.

#infosec #datasec




Show Original Post


15.02.2026 23:01
danzin (@danzin@mastodon.social)

You can try this in a terminal:
```
python -c "from unittest.mock import MagicMock; open(MagicMock(), 'w'); print(0)"
```




Show Original Post


15.02.2026 23:00
PythonPeak (@PythonPeak@mastodon.social)

Python Draws Infinite Concentric Boxes

Iterative logic generates art nested loops create structured patterns through systematic repetition Run it yourself

#python #pythontricks #codingtips #programmingtutorial #concentricboxes #gridpatterns #nestedsquares #opticalillusion #viralpython #pythonshorts #terminaltunnel

youtube.com/watch?v=-Ncfc9SAfyY




Show Original Post


15.02.2026 22:50
danzin (@danzin@mastodon.social)

But why didn't the tests fail under pytest?

pytest wraps, substitutes or otherwise messes with `sys.stdout` enough that fd 1 being dead doesn't cause prints to fail.

The best part? The method that calls `shutil.copy` is called `_safe_copy`, but it doesn't check whether the values it receives are strings or `Path`s. So it happily passes a `MagicMock` along as the copy destination.

So yeah, test your tests, and if you call something safe make it at least careful.

#Python #MagicMock #footgun




Show Original Post


15.02.2026 22:45
danzin (@danzin@mastodon.social)

Tests started failing when run with unittest, had been running fine with pytest for a while.

Tests error out with `OSError: [Errno 9] Bad file descriptor`.

Turns out if you `shutil.copy` something onto a `MagicMock`, you kill `sys.stdout`:

```
from unittest.mock import MagicMock
import shutil

m = MagicMock()
m.__fspath__.__index__() # → 1

shutil.copy(filename, m)
[errors omitted]

print(1) # → OSError: [Errno 9] Bad file descriptor
```

Much head scratching!




Show Original Post


15.02.2026 22:34
villares (@villares@ciberlandia.pt)

A #PythonBrasil2026 está com chamada aberta para propstas de atividades (tutoriais, palestras e sprints)!

talks.python.org.br/pybr26/cfp

EN: Python Brazil 2026: Call for Proposals

#Python #PythonBrasil #PyBR #PyBR26




Show Original Post


15.02.2026 21:53
elduvelle (@elduvelle@neuromatch.social)

Slightly technical coding question, #Matlab to #Python:
What's the simplest way to read a Matlab table in Python?
Or, if that's not possible, what should I convert my Matlab table to so I can read it in python? 🙏
It's quite a big table with "nested" data i.e. some of the columns contain different-lengths arrays for each row and some contain matrices.

Links I've tried without success:
stackoverflow.com/questions/25 (csv doesn't save all the data)
pythonguides.com/python-scipy- (about reading .mat files but does not seem to work with tables)

Links I haven't tried:
mathworks.com/help/matlab/matl (I believe this relies on having a working version of Matlab to use Matlab.engine to read the file, which kinds of defeats the purpose)

#Programming #NeuroMethods




Show Original Post


15.02.2026 21:24
IllestPreacha (@IllestPreacha@post.lurk.org)

SymbolicGlitch2

Video: youtu.be/dxOP1EuNhVo

Coded #python #hydravideosynth + #Glitch

#creativecoding
#Grids
#asciiart
#ascii
#Worldbuilding
#visualpoetry
#glitchart
#creativecodeart
#livecoding




Show Original Post


15.02.2026 21:04
CuratedHackerNews (@CuratedHackerNews@mastodon.social)

Show HN: VOOG – Moog-style polyphonic synthesizer in Python with tkinter GUI

github.com/gpasquero/voog




Show Original Post


1 ...478 479 480 481 482 483 484 485 486 487 488 ...1589
UP