1503 Commits

Author SHA1 Message Date
Jacob Eiting
f12ef22281 Handle UnicodeDecodeError in _get_user() (#1684)
Fixes #1683
2018-01-18 04:29:25 +03:00
Berker Peksag
76eaa0805b Fix various warnings and errors reported by pylint 2018-01-11 09:59:31 +03:00
Randall Leeds
b07532be75 Forbid contradictory secure scheme headers
When a request specifies contradictory secure scheme headers, raise a
parse error.
2018-01-10 12:10:35 -08:00
Andy Wilcox
32992a88f9 Avoid needlessly triggering non-false return from issetugid on MacOSX 2018-01-03 08:15:17 -08:00
Martin Broadhurst
6171ac4885 Add --reuse-port to make use of SO_REUSEPORT optional (#1669)
Fixes #1603
2018-01-02 20:25:26 +03:00
YuppY
5953148573 Do not strip leading slash from path (#1511)
Fixes #1512
2017-12-28 11:32:47 +03:00
Randall Leeds
cb2f471831 Remove superfluous BytesIO allocation 2017-12-10 11:57:32 -08:00
Nicolas Le Manchet
ad44552a03 Fix access logs not emitted when using logconfig_dict
Fixes #1652
2017-12-01 22:42:23 +03:00
Juan Julián Merelo Guervós
6ba2ebe545 Make "failed to find application" more informative (#1648)
Co-Authored-By: Luis Liñán Villafranca <luislivilla@gmail.com>

Fixes #1647
2017-11-24 10:42:03 +03:00
Benoit Chesneau
120f503f68 fix eventlet worker boot
new version of eventlet uses an external process to check a feature at
runtime (monotonic). ut since gunicorn already installed a signal handler,
eventlet never get the return and then was raising a runtime error making the worker crash.

This patch fix it by patching the worker after it has been initialized
and the signals resetted.

fix #1584
2017-11-12 11:19:30 +01:00
Benoit Chesneau
61431d47f3
Merge pull request #1616 from closeio/fix-non-blocking-connected-socket
Force gevent connected socket to blocking mode
2017-11-12 10:49:35 +01:00
Berker Peksag
2dd7321c90
Deprecate gaiohttp worker and document alternatives (#1569)
Fixes #1338
2017-10-31 07:30:41 +03:00
Randall Leeds
783c9bee3e Warn on Python < 2.7 for dictConfig 2017-10-29 21:44:10 -07:00
Randall Leeds
a7d4491a71 Fix up documentation for dictConfig 2017-10-29 21:43:41 -07:00
Randall Leeds
c5ae962dfa Add CLI option for dictionary log config 2017-10-29 21:43:26 -07:00
Mat Moore
9d7c857521 The logconfig_dict setting is not available on 2.6 2017-10-29 21:28:53 -07:00
Mat Moore
e6de1a07b4 Issue 1087: support dictConfig logging configuration 2017-10-29 21:28:53 -07:00
Randall Leeds
ccad26dd91
Merge pull request #1481 from benoitc/fix/1349-config-module-path
Set CWD and Python path before and after config
2017-10-28 11:02:14 -07:00
Hasan Ramezani
90b7daebb6 Fix invalid auto_int value error when --umask=0 passed (#1632)
Fixes #1622
2017-10-28 10:48:23 +03:00
Randall Leeds
89e364977a Set CWD and Python path before and after config
The config may be specified as a Python module, in which case we want
to ensure that the Python path is fixed up properly before we try to
load it. That means we should follow symlinks and add the current working
directory before and after the configuration is loaded.

Fix #1349
2017-10-26 19:50:06 -07:00
Randall Leeds
a3e258f24a Merge pull request #1428 from bsergean/master
Update arbiter.py to not leave tmp files around (fix #1327)
2017-10-26 19:46:36 -07:00
Matt Billenstein
5d4f885103 [gevent worker] Fix broken header parsing in logging (#1607)
We have a http.client.HTTPMessage in Python 3
(mimetools.Message in Python 2), just take .items()
from that.
2017-10-23 18:12:23 +03:00
Hasan Ramezani
81efa40da7 Improve parsing of 'unix://' addresses in parse_address (#1623) 2017-10-16 09:44:00 +03:00
Joe Kemp
61da054e27 Force connected socket to blocking mode 2017-10-06 05:41:30 -04:00
Berker Peksag
1edf8fcff5 Revert "Simplify hook handler config code"
This reverts commit cbbafdb9b1f8b0f04c7a0d174b5d56962e6bdbfe.
2017-09-19 02:28:00 +03:00
Randall Leeds
4c3ee6f4ec Merge pull request #1589 from Code0x58/tweaks
Tweaks
2017-09-16 13:52:49 -07:00
Oliver Bristow
6a2a8b3298 Fix #1576 - config file/module in GUNICORN_CMD_ARGS 2017-09-16 11:41:57 +01:00
Oliver Bristow
cbbafdb9b1 Simplify hook handler config code 2017-09-15 17:56:54 +01:00
Oliver Bristow
f14d4428bd Remove redundant properties 2017-09-14 22:12:06 +01:00
Oliver Bristow
bff593d9e4 replace shim wrap_method with staticmethod 2017-09-14 21:19:36 +01:00
Raphaël Slinckx
15e901a5e5 http/message: Split request line as bytes to avoid splitting on 0x0A. Fixes #1577 2017-08-25 10:50:34 +02:00
Benoit Chesneau
60efb1041e Merge pull request #1528 from hramezani/redirect_accesslog_issue_1403
Redirect accesslog issue 1403
2017-08-22 21:17:59 +02:00
Hasan Ramezani
7dc9003dff Add disable-redirect-access-to-syslog config 2017-08-22 22:43:30 +04:30
Tuukka Mustonen
0e4e0779e6 doc: Notes about worker keepalive support 2017-08-09 18:05:08 +03:00
Randall Leeds
fc0d973416 Merge pull request #1547 from guj-zz/syslog_socktype
parse_syslog_addr sock_type default
2017-08-06 23:37:55 -07:00
tomjaguarpaw
fc1e7a8262 Remove redundant "is not None" in gunicorn/app/wsgiapp.py (#1558) 2017-08-01 13:56:49 +03:00
tomjaguarpaw
c77df25a84 Remove redundant "is not None" in gunicorn/app/base.py (#1557) 2017-08-01 13:54:35 +03:00
tomjaguarpaw
cf401982fd Remove redundant "is not None" in gunicorn/http/wsgi.py (#1556) 2017-08-01 13:51:19 +03:00
tomjaguarpaw
4f11708542 Remove redundant 'is not None' 2017-07-22 20:05:55 +01:00
zz
5b0ae52c8a Merge remote-tracking branch 'origin/master' into syslog_socktype 2017-07-17 07:48:44 +02:00
Berker Peksag
56ef7710dd Fix a silly error introduced by 2407dd29a6b44e96150d48ac12d0d16be2506725 2017-07-14 02:42:28 +03:00
Berker Peksag
2407dd29a6 select.error is a subclass of OSError since Python 3.3 2017-07-12 18:07:16 +03:00
Berker Peksag
610596c9d9 Pass log.info() formatted values correctly
It should be

    log.info("%s", "spam")

not

    log.info("%s" % "spam")
2017-07-12 18:07:16 +03:00
Berker Peksag
f00fb441ca Remove unused variables 2017-07-12 18:07:16 +03:00
Berker Peksag
dd7c8f330b list.pop() doesn't accept a second argument
This was introduced by 032271a030a6bbe39d22e9ebadf2a86ddf3b6705.
2017-07-12 17:48:23 +03:00
Benno Rice
0d11691718 Ensure that overriding methods match the signature they've overriden. 2017-07-12 16:34:28 +03:00
Benno Rice
20616d50fc Move a default class definition into an else block so we're not redefining. 2017-07-12 16:26:04 +03:00
Benno Rice
e81c654c2d __str__ doesn't take any extra parameters. 2017-07-12 16:17:26 +03:00
Benno Rice
1f42421762 Fix a broken format string. 2017-07-12 16:16:40 +03:00
Benno Rice
e6edcb454a Remove some errant trailing commas. 2017-07-12 16:16:10 +03:00