-----BEGIN PGP SIGNED MESSAGE-----
Today a security release of Bash was issued, fixing a critical vulnerability.
This vulnerability allows an attacker to inject and execute arbitrary code on
many web servers and other applications.
This issue does not affect Twisted directly, but will affect many users of
Any web server which is serving traffic over a CGI or CGI-like interface
(including WSGI) should upgrade its version of Bash immediately.
This issue has been assigned CVE-2014-6271.
A complete description of the bug is also available: http://seclists.org/oss-
New packages have been issued for the following operating systems:
* Debian: http://www.debian.org/security/2014/dsa-3032
* Ubuntu: http://www.ubuntu.com/usn/usn-2362-1/
* Red Hat Enterprise Linux: https://rhn.redhat.com/errata/RHSA-2014-1293.html
Please be aware that there are reports that the current patches do not
completely solve the issue, it is likely that users will need to perform
updates a second time.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1
-----END PGP SIGNATURE-----
I've got some database transactional code running within a thread via RunInteraction (it needs to rollback on error).
One of the features on the logic is that it interacts with a 3rd party API, which may or may not have a ratelimit in effect. Most 3rd party APIs i consume have a minute/hourly based limit -- so I just do a graceful fail on the transaction to requeue it, and set a local timeout.
This particular API has a per-second meter in effect. It is considerably more efficient to just sleep for a second and "try again" a second later. I end up being able to process over twice as many API calls in a given period with that strategy.
The problem I ran into, is that I need a second database connection to note that a ratelimit has been created in the database -- and i'd like to pull that db connection out of the twisted connection pool to simplify my connection management.
- I can't do it within the existing connection, because I am in a transaction and the limit won't appear to other twisted jobs.
- I can't use runInteraction() off the pool, because that will defer to a thread and I am in a thread, and the last time I did something like that... everything broke.
- the stopgap I have right now is just creating/closing a raw pscycopg2 connection and using that. it works, but it requires a bit more management of postgres to ensure I can balance the right number of connections.
has anyone had a need like this before? if so, what did you do?
i basically just need to make two "INSERT" statements from a second connection.
I work for a company that develops telemetry boxes, and that uses the Twisted framework running on the main board.
It is planned to integrate a cellular module connected via USB or serial link to the main board.
Could you help me to know if GPRS/3G/Modem protocols through USB are supported with Twisted please? And how it is possible to use this interface?
Thanks for your help.
Recently I worked on refactoring a project so that it was, in my opinion, more testable. For reference, the diff is available at <https://github.com/Weasyl/txyam/compare/Weasyl:9230b7d09c1413a09d776700f26a…>, and the important parts in the changed version are at <https://github.com/Weasyl/txyam/blob/cdf7aef9e3425f27016f8e97c59bd2143fbf80…>.
My question: is this a good factoring for testing a wrapper? It seems to make sense to split apart crafting and issuing requests to clients, as it lets you test the contents of a request to see what will happen instead of having to issue the request and test that its effects happened.
On a previous iteration of this project, I wrote tests that did exactly that: issued requests and checked the bytes that were sent to a StringTransport. Those tests ended up being harder to read and write, and seemed to rely on the exact implementation of the thing I was wrapping.
Thanks in advance for any feedback on the matter,
I'm using a 3rd party API client, which uses httplib2 in the internals. ( the google-plus api )
I'm placing this blocking code within a DeferredList, that runs within a twisted.enterprise.adbapi.ConnectionPool.runInteraction
In my initial tests, everything worked fine -- but I was only making a single GET/POST, as I kept the size of the DeferredList to 1 while I worked on the code.
As soon as I increased the limit and had 2 GET/POST events firing off at the same time, I started getting a ssl/socket error ( httplib2 > httplib > socket > ssl ).
It works fine in twisted if I make simultaneous requests otherwise (using twisted or the `requests` package). this seems to be tied to how httplib2/httplib is running within twisted.
Has anyone experienced this before? if so, do you know if there is a workaround?
The easiest fix, is probably for me to write a new ApiClient tomorrow for the methods I need. I'd just like to avoid that if possible