20:00:01 <nitzmahone> #startmeeting Ansible Windows Working Group
20:00:01 <zodbot_> Meeting started Tue Nov  9 20:00:01 2021 UTC.
20:00:01 <zodbot_> This meeting is logged and archived in a public location.
20:00:01 <zodbot_> The chair is nitzmahone. Information about MeetBot at https://fedoraproject.org/wiki/Zodbot#Meeting_Functions.
20:00:01 <zodbot_> Useful Commands: #action #agreed #halp #info #idea #link #topic.
20:00:01 <zodbot_> The meeting name has been set to 'ansible_windows_working_group'
20:00:04 <nitzmahone> bah
20:00:08 <nitzmahone> #chair jborean93
20:00:08 <zodbot_> Current chairs: jborean93 nitzmahone
20:00:15 <jborean93> gotta pick up your game
20:00:25 <nitzmahone> #info agenda https://github.com/ansible/community/issues/581
20:00:49 <nitzmahone> Actually a couple things today
20:00:56 <nitzmahone> uh oh, looks like we lost the bot
20:01:02 <nitzmahone> oh well
20:01:16 <jborean93> zodbot_ is here though :)
20:01:17 <briantist> hey
20:01:20 <nitzmahone> #topic community wiki updates
20:01:46 <jborean93> yea it's probably time we update the wiki page
20:02:38 <briantist> it still goes to 2020
20:02:49 <nitzmahone> I'll take a stab at it afterwards and try to fix up the egregious stuff
20:02:57 <jborean93> thanks
20:03:00 <nitzmahone> #action nitzmahone to update wiki
20:03:08 <nitzmahone> #halp
20:03:20 <bcoca> i am not a bot!  .. also not lost, just silent
20:04:03 <nitzmahone> Most of the folks listed on there haven't been around for awhile- do we want to drop the ones that we haven't seen?
20:04:19 <jborean93> yea, we can always add them back in if they rejoin
20:04:34 <nitzmahone> ๐Ÿ‘
20:04:44 <briantist> sgtm
20:04:55 <nitzmahone> OK, next up then
20:05:06 <nitzmahone> #topic https://github.com/ansible/community/issues/581#issuecomment-963785156 (Script Analyzer update)
20:05:37 <nitzmahone> I'm ok with both of jborean93's suggestions there
20:06:26 <nitzmahone> If we're going to enable line length limit, I'd probably set to at least 120, and probably 160
20:06:28 <jborean93> we could also add rules to check the brace position if we wish but I thought that might be a step too far
20:06:38 <jborean93> yea we use 160 in Python so that would be it
20:07:16 <nitzmahone> I still leave my IDEs set for 120, but it's occasionally nice to be able to go longer without doing line continuation craziness
20:07:58 <jborean93> luckily PSSA can do auto correction so it shouldn't be too hard to just fix these in 1 go
20:08:16 <nitzmahone> Yeah, that's always nice
20:08:37 <jborean93> do we want to look at brace styles or even whitespace rules in statements, i.e. `if ()` vs `if()`
20:09:16 <nitzmahone> I could go either way- I know the last time we did a big pass on rules it seemed like a number of them were still kinda unsettled in the PS community as a whole
20:10:06 <jborean93> My biggest problems is really the indentation stuff and while I have a preferences for braces I don't really care too much about them
20:10:26 <jborean93> But I know we passed on this because the rules weren't really there to check this stuff but now they are
20:10:51 <briantist> sorry, had to step away for a few, but back  now
20:11:13 <nitzmahone> I don't have strong feelings either- if we're willing to put a stake in the ground and update the existing stuff to pass, I'm cool with whatever
20:11:32 <briantist> I definitely think 4 space indentation is easier to read for code, powershell too in this case
20:11:36 <briantist> (for yaml I like 2 spaces)
20:11:39 <nitzmahone> ditto
20:11:55 <nitzmahone> 4 space yaml grinds my gears
20:12:28 <briantist> we could take a layered approach.. don't have to change new rules all at once
20:13:12 <nitzmahone> Seems like if the tool's going to fix them for us and we're in the neighborhood, any reason *not* to do it all at once?
20:13:50 <jborean93> the only thing holding me back from enforcing brace style is people can be quite picky about it
20:13:54 <briantist> hm.. auto-remediation sounds dangerous (or at least.. iffy?)
20:14:22 <jborean93> but honestly I think I'm on the side of doing it to enforce consistency rather than the slapstick method we have today
20:14:51 <jborean93> briantist: so far I haven't been bitten by it, it's seems to be quite solid
20:14:59 <nitzmahone> I don't like auto-remediation in the commit pipeline (eg post-commit hooks or whatever), but I'm generally comfortable using it for a block change pass like this
20:15:25 <briantist> I definitely would like to see consistency that isn't enforced by humans in code review, so it sounds good to me
20:15:42 <jborean93> cool, I'll add those rules to the PR as well
20:15:52 <nitzmahone> ๐Ÿ‘ thanks!
20:15:58 <briantist> should we add an ignore refs file for the large changes?
20:16:00 <jborean93> by that it will do `if (condition) {\n`
20:16:19 <briantist> I know it doesn't get used automatically, but it'd be nice to be able to opt-in for git blame purposes
20:16:38 <jborean93> I'm not sure I've seen that before, is it a git thing?
20:16:49 <briantist> yeah, let me find an example
20:16:51 <nitzmahone> I'm inconsistent about that one myself, so having the tool make the choice solves that :D
20:17:49 <briantist> didn't read this but looks solid: https://akrabat.com/ignoring-revisions-with-git-blame/
20:18:21 <briantist> basically, you can tell git blame to ignore certain revs, very useful for bulk formatting changes. You can store a list of such commits in a file, and commit that
20:18:22 <nitzmahone> Ah that's clever
20:18:43 <briantist> people can set it in their local git config to use it automatically, or can specify it manually, etc.
20:18:51 <briantist> so it's no harm to add such a thing
20:18:59 <jborean93> ah ok so it's a way to tell `git blame` to ignore these revisions, do you know if GitHub uses the file?
20:19:03 <nitzmahone> TIL- I wasn't aware of `--ignore-rev`
20:19:34 <briantist> I'm not sure if GitHub uses it actually. Pretty sure vscode extensions like gitlens will respect your git config and use it though
20:19:59 <jborean93> ok, it sounds like a decent thing to do, it's going to be a large change for this stuff so I'll look at adding this
20:20:09 <briantist> https://github.com/github/feedback/discussions/5033
20:20:36 <jborean93> TIL about all this, thanks for sharing it
20:20:50 <briantist> looks like one of things a million people want but isn't implemented in GitHub yet ๐Ÿ˜…
20:21:00 <jborean93> lol, it might get there one day
20:21:04 <nitzmahone> Sounds like GH will eventually support it in some form, so worst case maybe we have to rename/move the file someday
20:21:52 <nitzmahone> Cool, anything else to talk about on that one?
20:22:07 <jborean93> I don't think so, we seem to have a consensus and I'll push those changes to the PR
20:22:20 <briantist> it sounds good to me
20:22:31 <nitzmahone> #action jborean93 to add ignore-rev-file support and enable new PSSA rules
20:22:34 <briantist> other than the bulk change itself, the enforcement/checking is going into ansible-test right?
20:23:22 <jborean93> yep
20:23:29 <jborean93> will be part of `ansible-test sanity --test pslint`
20:23:40 <briantist> sweet
20:23:52 <nitzmahone> and looks like it's already requiring the new version as well, so that should cover it
20:23:56 <nitzmahone> (in the PR)
20:24:13 <jborean93> the rules are defined at https://github.com/ansible/ansible/blob/devel/test/lib/ansible_test/_util/controller/sanity/pslint/settings.psd1
20:24:28 <nitzmahone> #topic open floor
20:24:58 <nitzmahone> We'll wait for any topics until :30 past the hour
20:25:18 <briantist> jborean93: wanted to ask how the work was coming along (I think in pypsrp?) that would enable ansible in WSL to connect to its Windows host without going through WinRM
20:25:50 <briantist> I'm a little vague on the details, but the stuff I was trying with GitHub Actions made it come up in my mind again
20:26:24 <jborean93> I've been putting off revisting my PR but it's still ongoing
20:27:10 <jborean93> Currently trying to simplify the existing implementation as currently it's a bit too complex with a lot of moving parts. Once that's done it will need more tests which is always fun
20:27:26 <briantist> got it
20:27:45 <briantist> could you remind me what part of that work would enable the scenario I mentioned?
20:27:56 <jborean93> like the PR or just how it works in general?
20:28:27 <jborean93> https://github.com/jborean93/pypsrp/pull/99 is the PR
20:29:27 <jborean93> and it's essentially https://github.com/jborean93/pypsrp/blob/f7b24dac86e0c42763cd954eca2de79909f0fa94/psrp/_process.py that does the communication, data is sent in using the stdin and read from stdout
20:29:57 <briantist> ahh I see
20:30:25 <briantist> so we could provide the executable with the native Windows name/path, like `pwsh.exe` instead of `pwsh`, which in WSL will execute with the native version
20:31:28 <jborean93> yep, it should even work with `powershell.exe`
20:32:07 <jborean93> I'm still not sure how to expose this stuff in Ansible but that's a problem for the future :)
20:32:23 <briantist> I was originally thinking of cloning a "local" connection plugin to implement this kind of thing, but I held off when you mentioned this work.
20:32:31 <nitzmahone> Heh, that's the part I was just ๐Ÿค” on
20:32:57 <briantist> That's what I did with the custom connection/shell plugin I created that lets us execute "windows" (powershell) ansible modules natively in Linux with `pwsh`
20:33:14 <jborean93> nitzmahone: yea I'm not sure whether it would be a `psrp_local`, `psrp_ssh`, separate connections or expose it all in the config somewhat, many ways to go about that
20:33:29 <nitzmahone> It's too bad those abstractions just aren't quite right for the Windows way
20:33:34 <briantist> right ^ was going to say, we'll have options, with it being available in pypsrp
20:33:36 <jborean93> if you need something sooner rather than later you might have more luck just doing that for now, this probably won't be done until next year
20:34:13 <briantist> yeah, I might consider an intermediate thing, depends on how critical the need becomes.. right now it's really important
20:34:13 <nitzmahone> `psrp_inception`
20:34:17 <briantist> haha
20:34:35 <briantist> `psrp` = `psrp remoting protocol`
20:34:40 <nitzmahone> `i_put_some_powershell_in_your_powershell`
20:34:47 <jborean93> lol
20:35:10 <briantist> `ansible_connection: 'powershell_๐Ÿ•ถ'`
20:35:18 <nitzmahone> lol
20:35:31 <briantist> `p๐Ÿ•ถwershell`
20:36:19 <briantist> anyway, nothing else from me for open floor
20:36:38 <nitzmahone> OK cool, we'll wrap it up then- til next week!
20:36:42 <nitzmahone> Thanks all!
20:36:43 <jborean93> thanks everyone
20:36:46 <briantist> thanks
20:36:48 <nitzmahone> #endmeeting