Skip to content

bug: the romanize function removes spaces from results #1108

@free-bug

Description

@free-bug

Description

Version: "5.1.1"

from pythainlp.transliterate import romanize

print(romanize("สามารถ สามารถ", "thai2rom"))

Expected output: samat samat

Received output: samatsamat

Expected results

Function romanize shouldn't remove spaces if source string contains them.

Current results

Function romanize removes spaces from result string if source string contains them.

Steps to reproduce

Just run code from the description.

PyThaiNLP version

5.1.1

Python version

3.12.7

Operating system and version

Ubuntu 24.10

More info

Host system, docker wasn't used for this case.

Possible solution

No response

Files

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationimprove documentation and test cases

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions