How To Install python3-lark-parser on AlmaLinux 8

In this tutorial we learn how to install python3-lark-parser in AlmaLinux 8. python3-lark-parser is Lark is a modern general-purpose parsing library for Python

Introduction

In this tutorial we learn how to install python3-lark-parser on AlmaLinux 8.

What is python3-lark-parser

Lark is a modern general-purpose parsing library for Python. Lark focuses on simplicity and power. It lets you choose between two parsing algorithms Earley It is the default. LALR(1) other pure-python parsing libraries. Both algorithms are written in Python and can be used interchangeably with the same grammar (aside for algorithmic restrictions). See “Comparison to other parsers” for more details. Lark can auto magically build an AST from your grammar, without any more code on your part. Features - EBNF grammar with a little extra - Earley & LALR(1) - Builds an AST auto magically based on the grammar - Automatic line & column tracking - Automatic token collision resolution (unless both tokens are regexps) - Python 2 & 3 compatible - Unicode fully supported

We can use yum or dnf to install python3-lark-parser on AlmaLinux 8. In this tutorial we discuss both methods but you only need to choose one of method to install python3-lark-parser.

Install python3-lark-parser on AlmaLinux 8 Using dnf

Update yum database with dnf using the following command.

sudo dnf makecache --refresh

After updating yum database, We can install python3-lark-parser using dnf by running the following command:

sudo dnf -y install python3-lark-parser

Install python3-lark-parser on AlmaLinux 8 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

After updating yum database, We can install python3-lark-parser using yum by running the following command:

sudo yum -y install python3-lark-parser

How To Uninstall python3-lark-parser on AlmaLinux 8

To uninstall only the python3-lark-parser package we can use the following command:

sudo dnf remove python3-lark-parser

References

Summary

In this tutorial we learn how to install python3-lark-parser on AlmaLinux 8 using yum and dnf.