Services Blog Français

djcall 0.0.5 release

| by jpic | python django uwsgi spooler cron

django-call is a model wrapper around uWSGI native cron and spooler features, including the signal framework allowing to program callbacks on cron or run them in a given spooler with a given priority for example.

For example right now on a betagouv project it logs the following when uWSGI starts:

[uwsgi-signal] signum 1 registered (wid: 0 modifier1: 0 target: worker)
[djcall] uwsgi.register_signal(1, mrsstat.models.Stat.objects.create_missing)
[uwsgi-signal] signum 2 registered (wid: 0 modifier1: 0 target: worker)
[djcall] uwsgi.register_signal(2, caisse.models.daily_mail)
[uwsgi-signal] signum 3 registered (wid: 0 modifier1: 0 target: worker)
[djcall] uwsgi.register_signal(3, djcall.models.prune)
[djcall] mrsstat.models.Stat.objects.create_missing() add cron : (0, 2, -1, -1, -1) signal 1
[djcall] caisse.models.daily_mail() add cron : (0, 8, -1, -1, 1) signal 2
[djcall] caisse.models.daily_mail() add cron : (0, 8, -1, -1, 2) signal 2
[djcall] caisse.models.daily_mail() add cron : (0, 8, -1, -1, 3) signal 2
[djcall] caisse.models.daily_mail() add cron : (0, 8, -1, -1, 4) signal 2
[djcall] caisse.models.daily_mail() add cron : (0, 8, -1, -1, 5) signal 2
[djcall] djcall.models.prune(keep=10000) add cron : (0, 4, -1, -1, -1) signal 3

Read More

Building better containers: A Survey of Container Build Tools

| by jpic | linux docker containers

Building Better Containers: A Survey of Container Build Tools [I] - Michael Ducy, Chef CNCF [Cloud Native Computing Foundation] Published on Dec 15, 2017 If you stick to the “industry standard” method of building containers (Dockerfiles), it’s easy to build containers that contain libraries, tools, binaries, and more that you don’t need. One survey showed that over 75% of containers contain a full Operating Systems. So how can you build containers that only contain the bits you require to run a particular application, and nothing more. This talk will cover various tools in the open source community that provide better methods for building containers, no matter the underlying container runtime. We will explore Bazel (along with Distroless), Smith (from Oracle), and Habitat (from Chef), and we will cover the benefits and drawbacks of each method. A short demo of each tool will be included. About Michael Ducy Born on the rolling plains of central Illinois corn fields, Michael Ducy started his technology journey at a young age. Always curious, he was once threatened that he’d never have toys bought for him again if he didn’t stop taking them apart to see how they worked. Raised in a blue collar family, his first workbench was given to him at the age of 5. His first programming language was BASIC, at the ripe young age of 6. Michael quickly saw the parallels between building physical objects on his workbench, and building virtual objects with his computer. Still an avid woodworker, Michael finds joy in helping people understand technology and the impact it has on the work that we do, and the lives that we lead.

Django-autocomplete-light 3.3.0 release

| by jpic | python django-autocomplete-light django

Changes since 3.3.0-rc6:

- use admin statics
- #981: create option behaviour
- #995: automatically generated views for generic foreign key fields
- Getting placeholder and minimumInputLength from dal select
- #1017: Initial migrations and database
- Turkish translation
- Added support for forwarded fields to Select2GenericForeignKeyModelField

Since 3.2.10:

3.3.0-rc6

#959: Django 2.0 widgets may load jQuery after dal #959 

3.3.0-rc5

#895: Self() and JavaScript() forward features

3.3.0-rc4

Read More

yourlabs django uwsgi spooler

| by jpic | python django uwsgi django-uwsgi-spooler

https://github.com/yourlabs/django-uwsgi-spooler

Finnaly a Django app to wrap around uWSGI’s builtin spooler ! I should have done this years ago, but I was expecting to make a boring module, it turned out a lot more exciting than expected ! First things first, django-uwsgi-spooler has only one expectation from your callbacks: be an importable function and take a task argument. The only other expectation is that you can use the Task model it provides, for example: Task(callback_name=‘yourmodule.yourcallback’, env=myvars).spool() Find more up to date information in the README. What’s the catch ? SECURITY Task model has a PickleField for you to pass data Well, hitting the database to update the task information (progress and output) is highly sub-optimal. So, the product needs going through another iteration, to make it use cache as safely as possible and still persist the data (progress, output) from the cache into the database after the task is over. But still, if you have CRUDLFA+ then it will offer a CRUD interface out of the box. For the moment it’s basic Task model visualisation, but I’m excited because of the possibilities it opens, such as: creating tasks in the admin, using other tasks as template, cancelling tasks… Have fun !

CHIP: a python's functional implementation of ReactJS

| by jpic | python best-practice

https://github.com/tbinetruy/CHIP

Python’s functional implementation of ReactJS, fast moving and very promising, by YourLabs Dev Team ! Thomas Binetruy has taken over jpic’s PoC of React in Python, which I’ve also seen an implementation attempt in the v2 branch of django-material. This is part of the milestone of migrating from MaterializeCSS to Material Design Components Web in CRUDLFA+. But know that YourLabs has never released any Django form rendering plugin so far. It never appealed to me, but with this thingie we’re entering that game. Right now it seems like “at last” there is a great tool to metaprogram JS, and this could even completely replace the need for ReactJS, and have components communicate between each other both on the server and client. We’ll push tests with the python-webpack-loader and things like that until we reach the point where we want to feature freeze. Will let you know when we release 1.0, but we are not sure were to stop as we move forward in the implementation. With LOVE

Previous Page 11 of 33 Next Page

They trust us

Contact

logo