# \[ANN\] PrettyTables v3.0.0

**URL:** <https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821>\
**Category:** Package Announcements\
**Tags:** prettytables\
**Created:** [August 25, 2025, 1:53am UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821 "2025-08-25T01:53:49Z")\
**Posts on this page:** 20\
**Page:** 4

<div class="post-metadata">

**Author:** ![devel-chm](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/devel-chm/32/3572_2.png) [@devel-chm](https://discourse.julialang.org/u/devel-chm)\
**Post date:** [September 19, 2025, 12:52pm UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/61 "2025-09-19T12:52:07Z")

</div>

You might also try using [JULIA\_CUDA\_SOFT\_MEMORY\_LIMIT](https://cuda.juliagpu.org/stable/usage/memory/#Memory-limits)  
and similar options.

---

<div class="post-metadata">

**Author:** ![juliohm](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/juliohm/32/215266_2.png) [@juliohm](https://discourse.julialang.org/u/juliohm)\
**Post date:** [September 19, 2025, 12:53pm UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/62 "2025-09-19T12:53:12Z")

</div>

Unfortunately the tests crash with `--jobs=2` too.

---

<div class="post-metadata">

**Author:** ![juliohm](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/juliohm/32/215266_2.png) [@juliohm](https://discourse.julialang.org/u/juliohm)\
**Post date:** [September 19, 2025, 12:54pm UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/63 "2025-09-19T12:54:05Z")

</div>

> [@devel-chm](#):
>
> You might also try using [JULIA\_CUDA\_SOFT\_MEMORY\_LIMIT](https://cuda.juliagpu.org/stable/usage/memory/#Memory-limits)  
> and similar options.

Yes, this is quickly becoming off-topic. All I want is to update PrettyTables.jl in CUDA.jl. It is so annoying that CUDA.jl is blocking updates downstream…

---

<div class="post-metadata">

**Author:** ![juliohm](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/juliohm/32/215266_2.png) [@juliohm](https://discourse.julialang.org/u/juliohm)\
**Post date:** [September 22, 2025, 5:50pm UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/64 "2025-09-22T17:50:27Z")

</div>

CUDA.jl released a patch that bumped the version of PrettyTables.jl to v3, but apparently there is another issue with GPUCompiler.jl in the way:

```julia
] activate --temp
] add CUDA@v5.8.4
] add PrettyTables@v3.0

```

```julia
Resolving package versions...
ERROR: Unsatisfiable requirements detected for package GPUCompiler [61eb1bfa]:
 GPUCompiler [61eb1bfa] log:
 ├─possible versions are: 0.1.0 - 1.6.1 or uninstalled
 ├─restricted by compatibility requirements with CUDA [052768ef] to versions: [0.3.0 - 0.7.3, 0.8.1 - 0.10.0, 0.11.1 - 0.12.9, 0.13.3 - 0.21.4, 0.24.0 - 1.6.1]
 │ └─CUDA [052768ef] log:
 │ ├─possible versions are: 0.1.0 - 5.8.4 or uninstalled
 │ ├─restricted to versions * by project [8f28697a], leaving only versions: 0.1.0 - 5.8.4
 │ │ └─project [8f28697a] log:
 │ │ ├─possible versions are: 0.0.0 or uninstalled
 │ │ └─project [8f28697a] is fixed to version 0.0.0
 │ ├─restricted by julia compatibility requirements to versions: [2.3.0, 2.5.0 - 5.8.4] or uninstalled, leaving only versions: [2.3.0, 2.5.0 - 5.8.4]
 │ └─restricted by compatibility requirements with PrettyTables [08abe8d2] to versions: 0.1.0 - 4.4.2 or uninstalled, leaving only versions: [2.3.0, 2.5.0 - 4.4.2]
 │ └─PrettyTables [08abe8d2] log:
 │ ├─possible versions are: 0.1.0 - 3.0.10 or uninstalled
 │ └─restricted to versions 3.0 by an explicit requirement, leaving only versions: 3.0.0 - 3.0.10
 ├─restricted by julia compatibility requirements to versions: 0.23.0 - 1.6.1 or uninstalled, leaving only versions: 0.24.0 - 1.6.1
 └─restricted by compatibility requirements with CUDA [052768ef] to versions: [0.8.1 - 0.10.0, 0.11.1 - 0.12.9, 0.13.3 - 0.21.4] — no versions left
   └─CUDA [052768ef] log: see above

```

---

<div class="post-metadata">

**Author:** ![giordano](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/giordano/32/2166_2.png) [@giordano](https://discourse.julialang.org/u/giordano)\
**Post date:** [September 22, 2025, 8:12pm UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/65 "2025-09-22T20:12:10Z")

</div>

> [@juliohm](#):
>
> [CUDA.jl](https://juliaregistries.github.io/General/packages/redirect_to_repo/CUDA) released a patch that bumped the version of [PrettyTables.jl](https://juliaregistries.github.io/General/packages/redirect_to_repo/PrettyTables) to v3

It did not: [Switch to texthighlighter to unbreak profile (#2891) · JuliaGPU/CUDA.jl@29fa0ba · GitHub](https://github.com/JuliaGPU/CUDA.jl/commit/29fa0ba46dc4aa873d917be13cb9a89be26ecf50) isn’t in CUDA.jl v5.8.4

> <https://github.com/JuliaGPU/CUDA.jl/blob/v5.8.4/Project.toml#L79>

---

<div class="post-metadata">

**Author:** ![juliohm](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/juliohm/32/215266_2.png) [@juliohm](https://discourse.julialang.org/u/juliohm)\
**Post date:** [September 22, 2025, 8:20pm UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/66 "2025-09-22T20:20:07Z")

</div>

Misread the commits, sorry.

---

<div class="post-metadata">

**Author:** ![juliohm](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/juliohm/32/215266_2.png) [@juliohm](https://discourse.julialang.org/u/juliohm)\
**Post date:** [September 24, 2025, 7:38pm UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/67 "2025-09-24T19:38:09Z")

</div>

Updated all GeoStats.jl modules successfully to PrettyTables.jl v3 ✅

@Ronis_BR the title of the table in HTML output is disproportionally large:

 ![image](https://global.discourse-cdn.com/julialang/original/3X/f/4/f4fa4c4ab3cd01747daf0cb4b97038f76270a22f.png)

This is what happens when the geospatial domain is more complicated:

 ![image](https://global.discourse-cdn.com/julialang/original/3X/4/6/465661342b0d12ee085d4e51523811d463789863.png)

Any way to reduce the size of the font for the title?

---

<div class="post-metadata">

**Author:** ![juliohm](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/juliohm/32/215266_2.png) [@juliohm](https://discourse.julialang.org/u/juliohm)\
**Post date:** [September 25, 2025, 12:49pm UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/68 "2025-09-25T12:49:39Z")

</div>

@Ronis_BR another issue after the update. PrettyTables.jl is throwing an error explicitly in Quarto builds as you can see here:

```julia
ERROR: EvaluationError: Encountered 3 errors during evaluation

Error 1 of 3
@ /home/juliohm/Desktop/geospatial-data-science-with-julia/01-geodata.qmd:205
MethodError: no method matching _html__print(::PrettyTables.PrintingSpec; is_stdout::Bool, column_label_titles::Vector{Union{Nothing, Vector{String}}}, highlighters::Vector{PrettyTables.HtmlHighlighter}, maximum_column_width::String, minify::Bool, stand_alone::Bool, style::PrettyTables.HtmlTableStyle{Vector{Pair{String, String}}, Vector{Pair{String, String}}}, table_class::String, table_div_class::String, top_left_string::String, wrap_table_in_div::Bool, header_alignment::Symbol)
This error has been manually thrown, explicitly, so the method may exist but be intentionally marked as unimplemented.

```

You can reproduce by updating the env in [GitHub - JuliaEarth/geospatial-data-science-with-julia: Geospatial Data Science with Julia](https://github.com/JuliaEarth/geospatial-data-science-with-julia) and typing `quarto render`.

---

<div class="post-metadata">

**Author:** ![Ronis\_BR](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ronis_br/32/50999_2.png) [@Ronis\_BR](https://discourse.julialang.org/u/Ronis_BR)\
**Post date:** [September 25, 2025, 6:28pm UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/69 "2025-09-25T18:28:48Z")

</div>

> [@juliohm](#):
>
> @Ronis_BR the title of the table in HTML output is disproportionally large:

You can change the default style of the title using `HtmlTableStyle` in the `style` keyword.

---

<div class="post-metadata">

**Author:** ![Ronis\_BR](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ronis_br/32/50999_2.png) [@Ronis\_BR](https://discourse.julialang.org/u/Ronis_BR)\
**Post date:** [September 25, 2025, 6:29pm UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/70 "2025-09-25T18:29:26Z")

</div>

> [@juliohm](#):
>
> @Ronis_BR another issue after the update. [PrettyTables.jl](https://juliaregistries.github.io/General/packages/redirect_to_repo/PrettyTables) is throwing an error explicitly in Quarto builds as you can see here:

For some reason (maybe macOS Tahoe), I am not able to install quarto. Can you provide a MWE to reproduce this bug?

---

<div class="post-metadata">

**Author:** ![juliohm](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/juliohm/32/215266_2.png) [@juliohm](https://discourse.julialang.org/u/juliohm)\
**Post date:** [September 25, 2025, 7:54pm UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/71 "2025-09-25T19:54:09Z")

</div>

Will try to produce a MWE tomorrow. It could be related to the previous workaround we had to do for printing DataFrames.jl:

> <https://github.com/JuliaEarth/geospatial-data-science-with-julia/blob/c3994c70b79d4ecde9c10aea4e69d72b12257c40/01-geodata.qmd#L207>

---

<div class="post-metadata">

**Author:** ![Ronis\_BR](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ronis_br/32/50999_2.png) [@Ronis\_BR](https://discourse.julialang.org/u/Ronis_BR)\
**Post date:** [September 25, 2025, 9:07pm UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/72 "2025-09-25T21:07:20Z")

</div>

> [@juliohm](#):
>
> ```julia-auto
> show(stdout, MIME("text/html"), df; header_alignment = :s)
>           
> 
> ```

There is no `header_alignment` keyword in PrettyTables.jl v3. It should be `column_label_alignment`.

---

<div class="post-metadata">

**Author:** ![giordano](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/giordano/32/2166_2.png) [@giordano](https://discourse.julialang.org/u/giordano)\
**Post date:** [September 25, 2025, 9:19pm UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/73 "2025-09-25T21:19:32Z")

</div>

When releasing a breaking version of a package, it’d be really helpful to the users to know what broke and how to adapt the code, a sort of upgrade guide. This is even more so important for somewhat popular packages. [Release v3.0.0 · ronisbr/PrettyTables.jl · GitHub](https://github.com/ronisbr/PrettyTables.jl/releases/tag/v3.0.0) merely says

> This new version contains many breaking changes. The API was almost entirely redesigned to improve the package maintainability and to add new features. Please, check the documentation for more details.

but as far as I could see the documentation doesn’t have anything about “if you used X in v2, you probably want to use Y in v3”. It’s really hard to get this sort of differential information just by reading the docs.

---

<div class="post-metadata">

**Author:** ![Ronis\_BR](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ronis_br/32/50999_2.png) [@Ronis\_BR](https://discourse.julialang.org/u/Ronis_BR)\
**Post date:** [September 25, 2025, 9:31pm UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/74 "2025-09-25T21:31:29Z")

</div>

Yeah, I completely agree. The issue is that PrettyTables.jl has always been a one-man show, so I didn’t have the time to write a migration guide for v2 to v3 because about 90% of the keywords and options changed at some point. Instead, I focused on creating comprehensive documentation so users can search and adapt their existing code.

For this particular release, a migration guide would probably be bigger than the documentation itself.

---

<div class="post-metadata">

**Author:** ![Ronis\_BR](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ronis_br/32/50999_2.png) [@Ronis\_BR](https://discourse.julialang.org/u/Ronis_BR)\
**Post date:** [September 25, 2025, 9:41pm UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/75 "2025-09-25T21:41:20Z")

</div>

Ah, by the way! For anyone migrating from PrettyTables.jl v2 to v3, feel free to post any errors on this thread. I really do not mind answering them, and it would probably be much faster 🙂

When I get some time in the future, I can use this feedback to make a simple migration guide as @giordano proposed with the most common errors.

---

<div class="post-metadata">

**Author:** ![LaurentPlagne](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/laurentplagne/32/10103_2.png) [@LaurentPlagne](https://discourse.julialang.org/u/LaurentPlagne)\
**Post date:** [September 25, 2025, 10:29pm UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/76 "2025-09-25T22:29:10Z")

</div>

The following has been generated by a free LLM agent. I have no idea if it has any value.

# Migration Guide: PrettyTables.jl v2 to v3

This guide is intended to help users migrate their code from PrettyTables.jl v2 to the new v3 release. Version 3 introduces several significant improvements and API changes that, while breaking, provide a more flexible and powerful way to create and customize tables.

The key areas of change are:

1. The `PrettyTable` object is now mutable.
2. The behavior of the `pretty_table` function has changed.
3. Several keyword arguments have been renamed.
4. The APIs for highlighters and table formats have been redesigned.

* * *

## 1. `PrettyTable` Object Mutability

In v2, the `PrettyTable` object was immutable, meaning all configuration had to be provided at the time of its creation. In v3, the `PrettyTable` object is now **mutable** , allowing you to modify its properties after creation.

**v2 Example:**

```julia-auto
# In v2, all options were passed in the constructor.
pt = PrettyTable(data, title = "My Table", border_crayon = crayon"blue")

```

**v3 Example:**

In v3, you can create a table and modify it step-by-step.

```julia-auto
# Create a table with the default configuration.
pt = pretty_table(data)

# Now, modify its properties as needed.
pt.title = "My Table"
pt.table_format = TextTableFormat(border_crayon = crayon"blue")

```

* * *

## 2. `pretty_table` Function Behavior

The `pretty_table` function no longer prints the table to the console by default. Instead, it returns a `PrettyTable` object.

**v2 Example:**

```julia-auto
# This would print the table directly to STDOUT.
pretty_table(data)

```

**v3 Example:**

To display the table in v3, you can either use the `show()` function or, if in a REPL, simply have the object as the last statement.

```julia-auto
# Create the table object.
pt = pretty_table(data)

# To print the table, you can do:
show(pt)

# Or in a REPL, just this will suffice:
pt

```

* * *

## 3. Keyword Argument Renames

Several keyword arguments have been renamed for better clarity and consistency. Here is a summary of the changes:

| v2 Keyword | v3 Keyword |
| --- | --- |
| `formatter` | `formatters` |
| `tf` | `table_format` |
| `header` | `column_labels` |
| `border_crayon` | (Part of `TextTableFormat`) |

**v2 Example:**

```julia-auto
pretty_table(data,
    header = ["Col A", "Col B"],
    tf = :simple,
    formatter = my_formatter
)

```

**v3 Example:**

```julia-auto
pretty_table(data,
    column_labels = ["Col A", "Col B"],
    table_format = tf_simple,
    formatters = my_formatter
)

```

* * *

## 4. API Redesigns

The APIs for highlighters and table formats have been significantly redesigned for greater flexibility.

### 4.1. Highlighters

The highlighter API has been completely revamped. Instead of using tuples to define highlighters, v3 introduces dedicated highlighter objects for each backend (`TextHighlighter`, `HtmlHighlighter`, etc.).

**v2 Example:**

```julia-auto
# v2 used a tuple-based system.
highlighters = (
    (data, i, j) -> data[i, j] > 10,
    crayon"bold red"
)

```

**v3 Example:**

In v3, you create a highlighter object and pass it to the `highlighters` keyword. This approach is more explicit and powerful.

```julia-auto
# Define a highlighter object.
hl_gt10 = TextHighlighter(
    (data, i, j) -> data[i, j] > 10,
    crayon"bold red"
)

# Pass it in a vector to the `highlighters` keyword.
pretty_table(data, highlighters = [hl_gt10])

```

### 4.2. Table Formats

Table formats are now defined by immutable structs (`TextTableFormat`, `HtmlTableFormat`, etc.). This means that to modify a format, you must create a new format object instead of modifying an existing one.

**v2 Example:**

```julia-auto
# v2 might have allowed direct modification or used symbols.
pretty_table(data, tf = :simple, border_crayon = crayon"green")

```

**v3 Example:**

In v3, you instantiate a format object with your desired settings. You can create a new format based on an existing one.

```julia-auto
# Create a new table format.
my_format = TextTableFormat(
    border_crayon = crayon"green",
    horizontal_char = '─'
)

# You can also use predefined formats and modify them.
# For example, to get a simple table with no vertical lines:
no_vertical_lines_format = TextTableFormat(; @text__no_vertical_lines)

pretty_table(data, table_format = no_vertical_lines_format)

```

* * *

## Conclusion

The changes in PrettyTables.jl v3 are substantial but are designed to provide a more intuitive and powerful API. By following this guide, you should be able to update your code with relative ease.

For a complete overview of all the new features and options, please refer to the official v3 documentation.

---

<div class="post-metadata">

**Author:** ![jules](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@jules](https://discourse.julialang.org/u/jules)\
**Post date:** [September 26, 2025, 5:46am UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/77 "2025-09-26T05:46:44Z")

</div>

You could try installing `quarto_jll` if the normal installer causes problems for you

---

<div class="post-metadata">

**Author:** ![juliohm](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/juliohm/32/215266_2.png) [@juliohm](https://discourse.julialang.org/u/juliohm)\
**Post date:** [September 26, 2025, 11:09am UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/78 "2025-09-26T11:09:50Z")

</div>

The new `column_label_alignment` option fixed the Quarto build ✅

---

<div class="post-metadata">

**Author:** ![juliohm](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/juliohm/32/215266_2.png) [@juliohm](https://discourse.julialang.org/u/juliohm)\
**Post date:** [September 26, 2025, 11:23am UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/79 "2025-09-26T11:23:43Z")

</div>

@Ronis_BR although the build is successful, the output with the workaround is raw HTML:

 ![image](https://global.discourse-cdn.com/julialang/original/3X/4/f/4fbfc0808c8288db7719aec625ab07ee646f52b6.png)

I removed the workaround and the output is rendered properly:

 ![image](https://global.discourse-cdn.com/julialang/original/3X/3/1/31b603ea0d7104834fdecbe46289996d44cdb680.png)

Now we are back to [show in html is a bit hard to read · Issue #3378 · JuliaData/DataFrames.jl · GitHub](https://github.com/JuliaData/DataFrames.jl/issues/3378).

Do you have a new workaround to better align the DataFrame columns?

---

<div class="post-metadata">

**Author:** ![Ronis\_BR](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ronis_br/32/50999_2.png) [@Ronis\_BR](https://discourse.julialang.org/u/Ronis_BR)\
**Post date:** [September 26, 2025, 5:51pm UTC](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821/80 "2025-09-26T17:51:51Z")

</div>

Hum, the old workaround should still work. We need to verify why the system is not rendering the HTML output and showing plain text instead.

[Previous page](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821.md?page=3)

[Next page](https://discourse.julialang.org/t/ann-prettytables-v3-0-0/131821.md?page=5)
