[01:22:27] Twitter SRE, a decade of cache related incidents in review ; https://danluu.com/cache-incidents/ [06:59:11] Hi folks, I just noticed that there is an error called ORES workers production in icinga, but it is the first time that I see it [06:59:25] and looking at what the nagios check does, everything seems working from the ORES side [07:02:12] but check_http leads to a socket timeout [07:02:38] I have to run some errands in a bit, so since nothing is on fire afaics I'll investigate later what's happening [12:56:07] dumb question - do we have a page with detail on Python style guide in WMF? [12:56:34] I'm hitting some minor errors with indenting and struggling to work out what it wants to see [13:05:46] mmhh perhaps https://www.mediawiki.org/wiki/Manual:Coding_conventions/Python topranks [13:06:10] can't speak to how official/followed it is though [13:06:44] I usually give the code to 'black' and that seems to work [13:10:13] godog: thanks! [13:10:48] I'll have a look, usually I just find another instance of the same thing in the code but this one is tricky ;) [13:12:10] hehe fair enough [13:14:33] ryankemper: fyi the syntax you had is correct (se: https://puppet-compiler.wmflabs.org/pcc-worker1001/1/) but there was an issue with the compiler hosts, which shuld be fixed now let m knof if you still see issues [13:15:23] godog: thanks, that led me to the pep8 spec, where I found what I needed. cheers. [13:21:45] topranks: sure! I highly recommend checking out 'black' for automatic formatting [13:51:17] I will check it out thanks! [14:53:18] topranks: i had to just make some decisions on this recently [14:53:26] here's the repo: https://gitlab.wikimedia.org/repos/data-engineering/workflow_utils [14:53:33] using setup.cfg and pyproject.toml [14:53:40] as well as mypy, pylint and flake8 [14:53:45] with some modification [14:53:45] s [14:56:51] ottomata: super thanks for the pointer, good to know where it is to work down through it if needed! [14:59:00] the pytest setup is...okay [14:59:20] but i don't love how it always runs all tests extensions like flake8 and pylint. the output is hard to read [14:59:29] but i like the linting it is suggesting...and also the overrides i chose too :) [15:00:13] e.g. i prefer 100 lines to 80 these day [15:00:14] s [15:00:23] 100 chars per line [15:00:41] ottomata: have you seen tox-wikimedia btw? [15:00:52] https://pypi.org/project/tox-wikimedia/ [15:01:01] basically what you set up for yourself :) legoktm taught me about it a while ago [15:01:21] i have not! [15:01:54] oh nice, but just in tox...hmmmmm i wouldn't mind using just tox i suppose, hmmm [15:02:11] might try that! [15:02:16] thanks cdanis ! [15:02:47] ottomata: very simple to use -- example https://gerrit.wikimedia.org/r/plugins/gitiles/operations/software/statograph/+/refs/heads/master/tox.ini [15:02:58] looking for link to source of tox-wikimedia [15:03:12] ah, gerrit [15:03:14] found it https://gerrit.wikimedia.org/r/plugins/gitiles/integration/tox-wikimedia/ [15:03:40] does look very nice [15:04:35] oh but hm [15:04:36] requirements: Install deps from requirements.txt and similarly named variants [15:04:39] i don't use requirements.txt [15:10:10] I don't either [15:32:27] quick question on deployment-prep puppetmaster TLS if anyone has time to help: https://phabricator.wikimedia.org/T299797#7702668 . TIA! [16:14:50] inflatador: trying to log in and have a look, but getting 'Connection closed by UNKNOWN port 65535'. has a first puppet run completed on the host yet? [16:22:29] herron nah, puppet is broken due to the cert/key mismatch mentioned in the ticket. Mainly I want to make sure it's safe to replace a private key on the puppetmaster's filesystem. Can I just stop puppetmaster service and replace the key? Is there another safer/better procedure? [16:23:27] happy to regen the cert if that works too, but puppet-ecdsa balks when the cert is in place [16:25:39] gotcha, in the case of a puppet cert mismatch I'll typically do something like... puppet-master: puppet cert --clean $fqdn and then puppet-agent: rm -rf /var/lib/puppet/ssl -- very important to not run that rm command only on the agent side and never on the master! [16:26:12] then after that puppet-agent: puppet agent -t and then puppet-master: puppet cert --sign [16:27:32] *only on the agent side and never on the master [16:27:49] herron thanks, I'll give it a shot. (and for anyone following along, this is in deployment-prep so don't freak out too much ;P ) [16:28:06] (unless a person want to spend the afternoon fixing puppet certs) [16:59:02] jbond: ah thanks, great to know the syntax was correct [17:28:04] ryankemper: if you learn cool tricks that are not on https://wikitech.wikimedia.org/wiki/Help:Standalone_puppetmaster edits are welcome. [17:29:16] bd808: why that page specifically? I'd think like https://wikitech.wikimedia.org/wiki/Help:Puppet-compiler would be a more logical place? [17:30:12] ryankemper: ah.. I think I meant to ping back to inflatador about his puppet cert questions and not you, sorry. [17:30:15] oh or were you saying that in reference to the `deployment-prep` stuff above [17:30:20] ack [17:31:02] but do edit any wikitech pages that are missing helpful info :) [17:48:41] thanks bd808 , taking a look now [18:48:04] requirements: Install deps from requirements.txt and similarly named variants <-- patches welcome to support other things, it's really very simple (hasn't required any maintenance for 2 years now) [18:55:57] topranks: in WMCS things we have settled on using `black` to format things and make most debates go away. https://wikitech.wikimedia.org/wiki/Wikimedia_Cloud_Services_team/Python_coding [18:57:15] legoktm: what about just pip install? [18:57:22] i'm using setuptools setup.cfg [18:57:27] no standalone requirements files [18:57:44] https://gitlab.wikimedia.org/repos/data-engineering/workflow_utils/-/blob/main/setup.cfg [18:58:22] tox already runs `pip install .` unless you explicitly skip it [18:58:54] oh i ugess the deps . bit will work for that [18:58:55] okay cool [18:59:16] oh right cool c danis isn't using requirements either [18:59:17] great [18:59:21] that'll work [18:59:22] thank you! [19:26:39] bd808: thanks, had a quick look at black it definitely looks like something to check out will dig in. [19:29:10] My main concern was simply pleasing the gods of CI, funny to see the debate I inadvertently sparked! [19:34:36] bd808: i will check that out too [23:26:07] Thanks mutante for the Friday afternoon code review! That's good SRE karma right there ;) [23:26:19] inflatador: :) [23:26:25] it was cool that you posted that question on wikitech-l too, have a good one [23:26:47] yeah, I need to reply to that nice volunteer who gave a detailed answer. Have a great weekend! [23:27:09] random share: offered my car to Carvana: $315 seemed low, tried Carmax, Carmax: $100 lol, and that in this market. I am driving a real "beater". [23:27:20] you too and sounds great :)