Hello,
I am reporting a bug in the core export engine of Org 10.0-pre where the
`#+TITLE` directive is parsed correctly but subsequently dropped by
`org-export-get-environment`. This causes export backends (such as HTML) to
generate an empty `<title>‎</title>` tag and completely omit the
document title from the output.
Steps to reproduce:
1. Start Emacs without configurations: `emacs -Q`
2. Create a file named `test.org` with the exact following content:
#+TITLE: TEST FILE
* header
lorem ipsum dolor sit amet
3. Parse the buffer using `M-: (org-element-parse-buffer)`. The AST
correctly identifies the title:
(keyword (:standard-properties [...] :key "TITLE" :value "TEST FILE"))
4. Evaluate the export environment: `M-: (plist-get
(org-export-get-environment) :title)`
Expected result:
The evaluation should return the parsed title list, e.g., `("TEST FILE")`.
Actual result:
The evaluation returns `nil`. The core framework fails to pass the title to
the export environment.
I would appreciate your feedback on this regression in the export framework.
Regards,
Kaan I. Yesilyurt
On Fri, Mar 6, 2026 at 1:22 PM İsmail YEŞİLYURT <[email protected]>
wrote:
> Hello,
>
> I am experiencing an issue where the Org-mode HTML exporter fails to
> recognize the `#+TITLE` directive.
> This results in an empty title tag (`<title>‎</title>`) in the HTML
> `<head>`.
>
> Steps to reproduce:
> 1. Start Emacs without configurations: `emacs -Q`
> 2. Create a new file named `test.org` with the exact following content:
>
> #+TITLE: test file
>
> * header
> lorem ipsum dolor sit amet
>
> 3. Export the file to HTML using `C-c C-e h h`.
>
> Expected result:
> The generated HTML should contain `<title>test file</title>` in the header.
>
> Actual result:
> The title tag evaluates to `<title>‎</title>` and the title header is
> entirely missing from the HTML body:
> <?xml version="1.0" encoding="utf-8"?>
> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
> <head>
> <!-- 2026-03-06 Fri 13:09 -->
> <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
> <meta name="viewport" content="width=device-width, initial-scale=1" />
> <title>‎</title>
> <meta name="author" content="freeman" />
> <meta name="generator" content="Org Mode" />
> <style type="text/css">.......
>
> System Information:
> - Emacs version: GNU Emacs 30.1 (built from source) [GNU Emacs 30.1
> (build 2, x86_64-pc-linux-gnu, GTK+ Version 3.24.41, cairo version 1.18.0)
> of 2026-03-05]
> - Org-mode version: 10.0-pre (cloned and built from savannah.nongnu.org)
> as well as the default built-in version.
> [Org mode version 10.0-pre (release_9.8-53-g1025e3 @
> /home/freeman/BACKUP/emacs/org-mode/lisp/)]
> - Operating System: Linux Mint [Linux blackmesa 6.17.0-14-generic
> #14~24.04.1-Ubuntu SMP PREEMPT_DYNAMIC Thu Jan 15 15:52:10 UTC 2 x86_64
> x86_64 x86_64 GNU/Linux]
>
> I have verified that the directive is on the first line and there are no
> leading spaces, tabs, or hidden BOM characters before the `#+TITLE`
> directive.
>
> I would appreciate any guidance on whether this is a known parsing issue
> or if further debugging steps are required.
>
> Regards,
> Kaan I. YESILYURT
>