Skip to content

Commit

Permalink
Remove unnecessary sqlite code
Browse files Browse the repository at this point in the history
`OptimizedUnicode` has been an alias for `str` since Python 3.2 and is scheduled for removal in Python 3.12. The default factory is already `str`, so the line wasn't doing anything.

See python/cpython#92547.
  • Loading branch information
JelleZijlstra committed May 10, 2022
1 parent de46911 commit a53a113
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion nltk/sem/relextract.py
Original file line number Diff line number Diff line change
Expand Up @@ -319,7 +319,6 @@ def in_demo(trace=0, sql=True):
import sqlite3

connection = sqlite3.connect(":memory:")
connection.text_factory = sqlite3.OptimizedUnicode
cur = connection.cursor()
cur.execute(
"""create table Locations
Expand Down

0 comments on commit a53a113

Please sign in to comment.