unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Strange warnings from htmlize.el
@ 2024-07-31 21:55 Angelo Graziosi
  2024-08-01 11:26 ` Bruno Barbier
  0 siblings, 1 reply; 5+ messages in thread
From: Angelo Graziosi @ 2024-07-31 21:55 UTC (permalink / raw)
  To: emacs-orgmode; +Cc: emacs-devel

With the last Emacs master build (20240731_183641) I get a lot of 
warnings like this:


Warning (emacs): Cannot fontify source block (htmlize.el >= 1.34 required)


when I export an old ORG document in HTML (C-c C-e h h).

Until some time ago, I had  exported the same document and many more in 
the same manner and never seen those warnings (just Emacs master and ORG 
versions changed).

What happened?

Ciao,
   Angelo.



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Strange warnings from htmlize.el
  2024-07-31 21:55 Strange warnings from htmlize.el Angelo Graziosi
@ 2024-08-01 11:26 ` Bruno Barbier
  2024-08-01 15:04   ` Angelo Graziosi
  0 siblings, 1 reply; 5+ messages in thread
From: Bruno Barbier @ 2024-08-01 11:26 UTC (permalink / raw)
  To: Angelo Graziosi, emacs-orgmode; +Cc: emacs-devel


Hi Angelo,

Angelo Graziosi <angelo.g0@libero.it> writes:

> With the last Emacs master build (20240731_183641) I get a lot of 
> warnings like this:
>
>
> Warning (emacs): Cannot fontify source block (htmlize.el >= 1.34 required)
>
>
> when I export an old ORG document in HTML (C-c C-e h h).
>
> Until some time ago, I had  exported the same document and many more in 
> the same manner and never seen those warnings (just Emacs master and ORG 
> versions changed).
>
> What happened?

This warning is from Org. It's telling you that you need to install the
htmlize package in your new Emacs.

Bruno



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Strange warnings from htmlize.el
  2024-08-01 11:26 ` Bruno Barbier
@ 2024-08-01 15:04   ` Angelo Graziosi
  2024-08-01 15:16     ` Ihor Radchenko
  0 siblings, 1 reply; 5+ messages in thread
From: Angelo Graziosi @ 2024-08-01 15:04 UTC (permalink / raw)
  To: Bruno Barbier, emacs-orgmode; +Cc: emacs-devel

Il 01/08/2024 13:26, Bruno Barbier ha scritto:
> 
> Hi Angelo,
> 
> Angelo Graziosi <angelo.g0@libero.it> writes:
> 
>> With the last Emacs master build (20240731_183641) I get a lot of
>> warnings like this:
>>
>>
>> Warning (emacs): Cannot fontify source block (htmlize.el >= 1.34 required)
>>
>>
>> when I export an old ORG document in HTML (C-c C-e h h).
>>
>> Until some time ago, I had  exported the same document and many more in
>> the same manner and never seen those warnings (just Emacs master and ORG
>> versions changed).
>>
>> What happened?
> 
> This warning is from Org. It's telling you that you need to install the
> htmlize package in your new Emacs.

If ORG is in Emacs core and it needs this package, shouldn't the package 
be in core too?

In any case I have "fixed" this removing the language from #+BEGIN_SRC. 
For example:

-#+BEGIN_SRC sh
+#+BEGIN_SRC

which for me is enough.

Thanks,
   Angelo.



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Strange warnings from htmlize.el
  2024-08-01 15:04   ` Angelo Graziosi
@ 2024-08-01 15:16     ` Ihor Radchenko
  2024-08-04 18:44       ` Ihor Radchenko
  0 siblings, 1 reply; 5+ messages in thread
From: Ihor Radchenko @ 2024-08-01 15:16 UTC (permalink / raw)
  To: Angelo Graziosi; +Cc: Bruno Barbier, emacs-orgmode, emacs-devel

Angelo Graziosi <angelo.g0@libero.it> writes:

>> This warning is from Org. It's telling you that you need to install the
>> htmlize package in your new Emacs.
>
> If ORG is in Emacs core and it needs this package, shouldn't the package 
> be in core too?

That's out of our control.
htmlize is not strictly required.  But without htmlize, code in the code
blocks is not colored.

Note that what is now a warning used to be a message.  Now, it is more
visible, which was the reason why this was promoted to warning.

> In any case I have "fixed" this removing the language from #+BEGIN_SRC. 
> For example:
>
> -#+BEGIN_SRC sh
> +#+BEGIN_SRC
>
> which for me is enough.

You can also:
1. Suppress the warning
2. Set `org-html-htmlize-output-type' to nil to tell Org not to try coloring

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Strange warnings from htmlize.el
  2024-08-01 15:16     ` Ihor Radchenko
@ 2024-08-04 18:44       ` Ihor Radchenko
  0 siblings, 0 replies; 5+ messages in thread
From: Ihor Radchenko @ 2024-08-04 18:44 UTC (permalink / raw)
  To: Angelo Graziosi; +Cc: Bruno Barbier, emacs-orgmode, emacs-devel

Ihor Radchenko <yantar92@posteo.net> writes:

> Angelo Graziosi <angelo.g0@libero.it> writes:
>
>>> This warning is from Org. It's telling you that you need to install the
>>> htmlize package in your new Emacs.
>>
>> If ORG is in Emacs core and it needs this package, shouldn't the package 
>> be in core too?
>
> That's out of our control.
> htmlize is not strictly required.  But without htmlize, code in the code
> blocks is not colored.
>
> Note that what is now a warning used to be a message.  Now, it is more
> visible, which was the reason why this was promoted to warning.

I now tried to improve the warning text to clarify things.
https://git.savannah.gnu.org/cgit/emacs/org-mode.git/commit/?h=bugfix&id=b7026cf3e8cda347c377db498cf7dab70c7a67a4

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2024-08-04 18:44 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-07-31 21:55 Strange warnings from htmlize.el Angelo Graziosi
2024-08-01 11:26 ` Bruno Barbier
2024-08-01 15:04   ` Angelo Graziosi
2024-08-01 15:16     ` Ihor Radchenko
2024-08-04 18:44       ` Ihor Radchenko

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).