Received: from mail.netlandish.com (mail.netlandish.com [174.136.98.166]) by code.netlandish.com (Postfix) with ESMTP id 8427F811A5 for <~petersanchez/public-inbox@lists.code.netlandish.com>; Fri, 20 Oct 2023 02:33:19 +0000 (UTC) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=209.85.222.179; helo=mail-qk1-f179.google.com; envelope-from=matt@jellyfish.co; receiver= Authentication-Results: mail.netlandish.com; dkim=pass (1024-bit key; unprotected) header.d=jellyfish.co header.i=@jellyfish.co header.b=ZHMTsyMn Received: from mail-qk1-f179.google.com (mail-qk1-f179.google.com [209.85.222.179]) by mail.netlandish.com (Postfix) with ESMTP id 5B0E2152E8A for <~petersanchez/public-inbox@lists.code.netlandish.com>; Fri, 20 Oct 2023 02:33:16 +0000 (UTC) Received: by mail-qk1-f179.google.com with SMTP id af79cd13be357-777745f1541so22331185a.0 for <~petersanchez/public-inbox@lists.code.netlandish.com>; Thu, 19 Oct 2023 19:33:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=jellyfish.co; s=google; t=1697769196; x=1698373996; darn=lists.code.netlandish.com; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=XpCDcRKPm28OaZXOvDbljmApZFftM7nbVGgojZi1m/I=; b=ZHMTsyMntCkhhvid/E2STnOtpo9KJuBReOkuf9fDWQj7xw6b7/m90mHYfOrplUBA9t KAaeE4nOc7a+jR9tPDoIrTk+pMxqykTlD9w6crHED4yshqdiPm6CXU11CEBB3pdHw1L1 k4emgNHGM8cUqQJzXBbUDJVoJv1Emy+XfTTDU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697769196; x=1698373996; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=XpCDcRKPm28OaZXOvDbljmApZFftM7nbVGgojZi1m/I=; b=LdMQ9c+ylvMmofKPJChWCdIrM/Gcsc8kejpAi9q+CdbNgQZWVNici2/IOcLiirLnFP GHeZfI7gENk0ovJBgKiYESC+PsKNyCdU/tqEvOVoOeDW913N1Ev3my3bNbJSw9irTYkL YOb6zr8CTbBsdB+z5Y9zuua/xJod5dL3ZiZ9eLSBX3VkwjxycsOsKDWwuNL6pQ0zZuv0 OHPueXFQymnETnGJnOY1zNvUxhbVvQyOw6d0TbGQxKgVkCDyY3M5JVwrp06Gqj8VIvgs 6R+kNTWX7yaBfPW/Y9fe2YFyA8IjNlk5i3NMRzJGiUyMNOxYbeoWvlvhLbzPM0HWaoN9 IZHg== X-Gm-Message-State: AOJu0YxNyD6MK1nrnxq8q67MHfpJO9NxUtjnJVrrEH0FkkbiQ1HLB/6/ UoX/EMKCIw/FwkdZi/LYdk97PFKfrtedXVaJftNXeg== X-Google-Smtp-Source: AGHT+IHC3x9xzt9+tBPEjgE4IjGiUuYNEjLBhZMpX/4MKgM83/JdkDOLiwEkxXKdZlLuz3q18q59wK0fQrg9HAY7dNE= X-Received: by 2002:a05:6214:2266:b0:63f:80a0:4eea with SMTP id gs6-20020a056214226600b0063f80a04eeamr944014qvb.24.1697769196273; Thu, 19 Oct 2023 19:33:16 -0700 (PDT) MIME-Version: 1.0 References: <20231018201246.oxarujz2tdu7kgfi@thinkpad.my.domain> In-Reply-To: <20231018201246.oxarujz2tdu7kgfi@thinkpad.my.domain> From: Matt Klein Date: Thu, 19 Oct 2023 22:33:05 -0400 Message-ID: Subject: Re: [PATCH django-impersonate] Ensure an impersonation session is marked as ended if it's timed out To: Peter Sanchez Cc: ~petersanchez/public-inbox@lists.code.netlandish.com Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Peter, thanks for your response. Does this one work? (I took out the comments too since they're not really necessary.) --- a/impersonate/views.py +++ b/impersonate/views.py @@ -85,7 +85,7 @@ def stop_impersonate(request): if impersonating is not None: session_end.send( sender=3DNone, - impersonator=3Drequest.impersonator, + impersonator=3Drequest.user, impersonating=3Dimpersonating, request=3Drequest, ) On Wed, Oct 18, 2023 at 4:12=E2=80=AFPM Peter Sanchez wrote: > > Matt, thanks for the second patch. Unfortunately it doesn't apply. It > looks like you may be trying to submit it directly from a parent repo > which you've included the impersonate code into. The error is: > > `unable to find 'vendor/django-impersonate-1.9.1/impersonate/views.py' fo= r patching` > > There is no `vendor` directory in the repo. If you can clone the main > repo, make your changes, and resubmit the patch it should apply cleanly. > > Thanks, > > Peter