Monday, 2023-09-25

opendevreviewHervĂ© Beraud proposed openstack/oslo.rootwrap master: DNM test  https://review.opendev.org/c/openstack/oslo.rootwrap/+/89635408:37
JayFWorking on heat test failures for the oslo.messaging bump.16:48
JayFreverting my security fix does cause them to pass, so that's the root cause, going to see if I can shake out why16:48
JayFif not, how would you all feel about a rewrite of that fix in the way I originally did: explicitly blank sensitive values  -- in an attempt to get us something backportable16:49
stephenfinJayF: If it's not gross looking and won't cause us hassle down the line, I have no objections to anything that makes your life easier16:58
JayFHonestly, the thing that may make my life easier would be someone being willing to rubber duck this with me if I get stuck16:58
JayFI've confirmed already it's my sanitization change that breaks it16:58
JayFI am not sure but I think it's got to do with osprofiler; osprofiler hooks in via notifications16:59
JayFand given the way the tests are hanging, I suspect something around osprofiler freaking out when it gets a serialized copy of a different context16:59
JayFbut I am not sure and am mainly troubleshooting thru changing oslo messaging code and seeing how the unit tests change (if they do)16:59
JayFif I replace _sanitize_context with > return ctxt.__class__.from_dict(ctxt.__class__.to_dict(ctxt)) 17:09
JayFit passes17:09
JayFso it's not even angry about it being a different context object; it's doing something with the context being passed from the notification and hanging afterwards17:09
JayFoh wow I got it, this is crazy17:20
JayFhttps://github.com/openstack/heat/blob/master/heat/common/context.py#L12017:20
JayFwe filter is_admin17:20
JayFand as a result it does a roundtrip to policy, using a context that's already been stripped of anything that makes sense of policy17:21
JayFthat's how we end up doing work with a notification-cleaned context17:21
JayFI believe I shuold be able to work around this by adding is_admin to the safe list17:21
* JayF crosses fingers17:22
JayFbingo17:24
opendevreviewJay Faulkner proposed openstack/oslo.messaging master: Add is_admin to safe fields list for notifications  https://review.opendev.org/c/openstack/oslo.messaging/+/89645117:30
JayFstephenfin: ^17:30
JayFstephenfin: we need to land that, release it as 14.4.1, then bump https://review.opendev.org/c/openstack/requirements/+/89291917:30
JayFhttps://bugs.launchpad.net/oslo.messaging/+bug/203731217:32
JayFhberaud: frickler: Please take notice of the oslo.messaging fix above ^ I believe that should be the last step in getting an oslo.messaging that's happy with all 2023.2 projects and able to be released for a security fix17:33
JayFhberaud: frickler: https://review.opendev.org/c/openstack/oslo.messaging/+/896451 all details, including a link to the bug and the cause, are indicated in there17:33
opendevreviewJay Faulkner proposed openstack/oslo.context master: Add is_admin to default version of redacted_context  https://review.opendev.org/c/openstack/oslo.context/+/89645317:37
JayF(that will prevent a similar bug when transitioning to the better way to do this in caracal)17:38
opendevreviewJay Faulkner proposed openstack/oslo.messaging stable/2023.2: Add is_admin to safe fields list for notifications  https://review.opendev.org/c/openstack/oslo.messaging/+/89642217:39
opendevreviewJay Faulkner proposed openstack/oslo.messaging stable/2023.1: Add is_admin to safe fields list for notifications  https://review.opendev.org/c/openstack/oslo.messaging/+/89642317:40
opendevreviewJay Faulkner proposed openstack/oslo.messaging stable/zed: Add is_admin to safe fields list for notifications  https://review.opendev.org/c/openstack/oslo.messaging/+/89642417:40
opendevreviewJay Faulkner proposed openstack/oslo.messaging stable/yoga: Add is_admin to safe fields list for notifications  https://review.opendev.org/c/openstack/oslo.messaging/+/89642517:40
opendevreviewJay Faulkner proposed openstack/oslo.messaging stable/xena: Add is_admin to safe fields list for notifications  https://review.opendev.org/c/openstack/oslo.messaging/+/89642617:40
opendevreviewJay Faulkner proposed openstack/oslo.messaging master: Add is_admin to safe fields list for notifications  https://review.opendev.org/c/openstack/oslo.messaging/+/89645117:50
opendevreviewJay Faulkner proposed openstack/oslo.messaging master: Add is_admin to safe fields list for notifications  https://review.opendev.org/c/openstack/oslo.messaging/+/89645117:51
opendevreviewJay Faulkner proposed openstack/oslo.messaging stable/2023.2: Add is_admin to safe fields list for notifications  https://review.opendev.org/c/openstack/oslo.messaging/+/89642217:51
opendevreviewJay Faulkner proposed openstack/oslo.messaging stable/2023.1: Add is_admin to safe fields list for notifications  https://review.opendev.org/c/openstack/oslo.messaging/+/89642317:52
opendevreviewJay Faulkner proposed openstack/oslo.messaging stable/zed: Add is_admin to safe fields list for notifications  https://review.opendev.org/c/openstack/oslo.messaging/+/89642417:52
opendevreviewJay Faulkner proposed openstack/oslo.messaging stable/yoga: Add is_admin to safe fields list for notifications  https://review.opendev.org/c/openstack/oslo.messaging/+/89642517:52
opendevreviewJay Faulkner proposed openstack/oslo.messaging stable/xena: Add is_admin to safe fields list for notifications  https://review.opendev.org/c/openstack/oslo.messaging/+/89642617:53
JayFfrickler: hberaud: Updated as per code review feedback and re-backported thru. (I'm early-cherry-picking just to try and reduce latency/back and forth since this fix has taken a while)17:53
fricklerJayF: thx, I'm really glad that the fix is so simple, looking at the test failures I had feared something much worse happening18:01
JayFI was mostly terrified the entire time18:01
JayFLOL18:01
JayFMy biggest fear was that it was just straight-up broken with osprofiler, but nope, just some cleverness in __init__18:02
frickleralso, if you have the fix in oslo.context in master, would it be enough to do the messaging fix as stable-only?18:03
JayFHere's sorta how I am thinking about it, logically?18:03
JayFthe state of messaging master is "messaging redacts the context"18:03
JayFthat is broken; so fixing it is a unit of work18:04
JayFa separate parallel unit of work is taking out that piece and replacing it with calls to oslo.context (which, at this point, needs a merge and re-release to prevent this bug too when we switch to it, see https://review.opendev.org/c/openstack/oslo.context/+/896453 )18:04
JayFSo I would rather treat it as two separate efforts because there is less between us and "fixed" if we just fix master+backport, then replace the implementation in master18:05
JayFI can do it the other way (just pull master forward to using cxt.redacted_copy()) but that's going to take a bit longer to land, and I don't like messaging master being broken that long18:05
JayFjust my $.0218:05
JayFTBH I'm not super familiar with like ... how you all approach this kind of stuff in oslo; I will likely be working more in these common areas as time moves on so if that approach is like ... incompatible with how you usually handle that stuff, I'd love to learn18:06
opendevreviewJay Faulkner proposed openstack/oslo.context master: Add is_admin to default version of redacted_context  https://review.opendev.org/c/openstack/oslo.context/+/89645318:09
fricklernote that I'm only an outsider myself, I just mention this because this seems to be similar to what happened for oslo.db. the fixes were merged into stable/2023.2 and a new release was cut there to fix bobcat, while master stayed untouched, ready to make further progress towards sqla218:09
JayFfrickler: yeah, in that case oslo.db master was significantly different than 2023.2; in this case they are literally identical except for the perfunctory patches landed when a branch is cut18:09
JayF(and it's not a "move backwards" in the same way a revert is; it's just a straight moving-forward fix)18:10
fricklerI think the fwd vs. reverse thing is a good point, ack, so I rest my case on that ;)18:12

Generated by irclog2html.py 2.17.3 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!