unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Amin Bandali <bandali@gnu.org>
To: 40642@debbugs.gnu.org
Subject: bug#40642: 27.0.90; htmlfontify's hfy-force-fontification misusing jit-lock-fontify-now
Date: Wed, 15 Apr 2020 10:07:11 -0400	[thread overview]
Message-ID: <878siwj10w.fsf@gnu.org> (raw)


It seems that htmlfontify's `hfy-force-fontification' uses
`jit-lock-fontify-now' without first checking if `jit-lock' is activated
in the buffer.

Symptoms of this bug include errors like this:

jit-lock-fontify-now: Wrong type argument: number-or-marker-p, nil

The above is triggered when calling the scpaste-index command from a
recent version of scpaste [0] that uses the `htmlfontify-buffer'
function from htmlfontify when htmlize is not available [1].

[0]: https://github.com/technomancy/scpaste
[1]: https://github.com/technomancy/scpaste/commit/ca95a8d

Excerpt from *Backtrace*:

Debugger entered--Lisp error: (wrong-type-argument number-or-marker-p nil)
  jit-lock--run-functions(1 10813)
  jit-lock-fontify-now()
  hfy-force-fontification()
  htmlfontify-buffer()
  scpaste("index")
  scpaste-index()
  funcall-interactively(scpaste-index)
  call-interactively(scpaste-index record nil)
  command-execute(scpaste-index record)
  counsel-M-x-action("scpaste-index")

In GNU Emacs 27.0.90 (build 3, x86_64-pc-linux-gnu, X toolkit, Xaw3d scroll bars)
 of 2020-04-15 built on darrud
Repository revision: 485f24223fdca91d439b7beaaac33f66cb3bc2af
Repository branch: emacs-27
Windowing system distributor 'The X.Org Foundation', version 11.0.12004000
System Description: Debian GNU/Linux 10 (buster)





             reply	other threads:[~2020-04-15 14:07 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-15 14:07 Amin Bandali [this message]
2020-04-15 15:01 ` bug#40642: 27.0.90; htmlfontify's hfy-force-fontification misusing jit-lock-fontify-now Stefan Monnier
2020-04-15 15:10   ` Amin Bandali
2020-04-15 16:18     ` Stefan Monnier

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to=878siwj10w.fsf@gnu.org \
    --to=bandali@gnu.org \
    --cc=40642@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 public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).