]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commitdiff
add missing slash for sqlite URL with explicit :memory:
authorMike Bayer <mike_mp@zzzcomputing.com>
Wed, 21 Aug 2024 14:49:27 +0000 (10:49 -0400)
committerMike Bayer <mike_mp@zzzcomputing.com>
Wed, 21 Aug 2024 14:49:53 +0000 (10:49 -0400)
Fixes: #11772
Change-Id: I3bdb1c81c5a503cb16143c9d1c130ec79769fbca
(cherry picked from commit 663e6f1d60c99fa93da479b4f6f3b3c5e49cc2a8)

lib/sqlalchemy/dialects/sqlite/pysqlite.py

index f39baf32171f6351a6bdc3c88a2c45aea1ef85b4..69a902c32ab6684828d5edd299402a18814b06e8 100644 (file)
@@ -52,11 +52,11 @@ used. Double backslashes are probably needed::
     e = create_engine('sqlite:///C:\\path\\to\\database.db')
 
 To use sqlite ``:memory:`` database specify it as the filename using
-``sqlite://:memory:``. It's also the default if no filepath is
+``sqlite:///:memory:``. It's also the default if no filepath is
 present, specifying only ``sqlite://`` and nothing else::
 
-    # in-memory database
-    e = create_engine('sqlite://:memory:')
+    # in-memory database (note three slashes)
+    e = create_engine('sqlite:///:memory:')
     # also in-memory database
     e2 = create_engine('sqlite://')