Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
ZEO
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
ZEO
Commits
85a156c2
Commit
85a156c2
authored
Jun 16, 2003
by
Jeremy Hylton
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use cStringIO instead of StringIO.
(All the other non-test ZODB code uses cStringIO.)
parent
2a8691c1
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
src/ZODB/config.py
src/ZODB/config.py
+4
-4
No files found.
src/ZODB/config.py
View file @
85a156c2
...
@@ -13,10 +13,10 @@
...
@@ -13,10 +13,10 @@
##############################################################################
##############################################################################
"""Open database and storage from a configuration.
"""Open database and storage from a configuration.
$Id: config.py,v 1.1
2 2003/05/30 19:20:55
jeremy Exp $"""
$Id: config.py,v 1.1
3 2003/06/16 14:51:49
jeremy Exp $"""
import
os
import
os
import
StringIO
from
cStringIO
import
StringIO
import
ZConfig
import
ZConfig
...
@@ -41,7 +41,7 @@ def getStorageSchema():
...
@@ -41,7 +41,7 @@ def getStorageSchema():
return
_s_schema
return
_s_schema
def
databaseFromString
(
s
):
def
databaseFromString
(
s
):
return
databaseFromFile
(
StringIO
.
StringIO
(
s
))
return
databaseFromFile
(
StringIO
(
s
))
def
databaseFromFile
(
f
):
def
databaseFromFile
(
f
):
config
,
handle
=
ZConfig
.
loadConfigFile
(
getDbSchema
(),
f
)
config
,
handle
=
ZConfig
.
loadConfigFile
(
getDbSchema
(),
f
)
...
@@ -55,7 +55,7 @@ def databaseFromConfig(section):
...
@@ -55,7 +55,7 @@ def databaseFromConfig(section):
return
section
.
open
()
return
section
.
open
()
def
storageFromString
(
s
):
def
storageFromString
(
s
):
return
storageFromFile
(
StringIO
.
StringIO
(
s
))
return
storageFromFile
(
StringIO
(
s
))
def
storageFromFile
(
f
):
def
storageFromFile
(
f
):
config
,
handle
=
ZConfig
.
loadConfigFile
(
getStorageSchema
(),
f
)
config
,
handle
=
ZConfig
.
loadConfigFile
(
getStorageSchema
(),
f
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment