all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Augusto Stoffel <arstoffel@gmail.com>
To: 61648@debbugs.gnu.org
Subject: bug#61648: [PATCH] * lisp/progmodes/python.el (python--import-sources): Fix regexp
Date: Mon, 20 Feb 2023 10:54:07 +0100	[thread overview]
Message-ID: <875ybwhdc0.fsf@gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 286 bytes --]

Tags: patch

Please include this small bug fix concerning the Python import commands
in Emacs 29.

.pyc files are binary bytecode and not relevant for the purposes of the
import management.  I originally confused them with .pyx files, which
are Cython source files (a Python dialect).


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-lisp-progmodes-python.el-python-import-sources-Fix-r.patch --]
[-- Type: text/patch, Size: 952 bytes --]

From 5332794f25d5d7272271981d8c463d112a1d8b1e Mon Sep 17 00:00:00 2001
From: Augusto Stoffel <arstoffel@gmail.com>
Date: Mon, 20 Feb 2023 10:49:22 +0100
Subject: [PATCH] * lisp/progmodes/python.el (python--import-sources): Fix
 regexp

---
 lisp/progmodes/python.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el
index 0d714c31e9e..eab5e70af33 100644
--- a/lisp/progmodes/python.el
+++ b/lisp/progmodes/python.el
@@ -6376,7 +6376,7 @@ python--import-sources
   "List files containing Python imports that may be useful in the current buffer."
   (if-let (((featurep 'project))        ;For compatibility with Emacs < 26
            (proj (project-current)))
-      (seq-filter (lambda (s) (string-match-p "\\.py[ciw]?\\'" s))
+      (seq-filter (lambda (s) (string-match-p "\\.py[iwx]?\\'" s))
                   (project-files proj))
     (list default-directory)))
 
-- 
2.39.2


             reply	other threads:[~2023-02-20  9:54 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-20  9:54 Augusto Stoffel [this message]
2023-02-22 13:32 ` bug#61648: [PATCH] * lisp/progmodes/python.el (python--import-sources): Fix regexp Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=875ybwhdc0.fsf@gmail.com \
    --to=arstoffel@gmail.com \
    --cc=61648@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.