Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.buildout
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
isaak yansane-sisk
slapos.buildout
Commits
126938e4
Commit
126938e4
authored
Aug 18, 2012
by
Domen Kožar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix python2.4 support
parent
792046c7
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
34 additions
and
23 deletions
+34
-23
CHANGES.txt
CHANGES.txt
+2
-0
buildout.cfg
buildout.cfg
+10
-1
src/zc/buildout/buildout.py
src/zc/buildout/buildout.py
+1
-1
src/zc/buildout/download.py
src/zc/buildout/download.py
+13
-11
src/zc/buildout/easy_install.py
src/zc/buildout/easy_install.py
+6
-6
src/zc/buildout/update.txt
src/zc/buildout/update.txt
+2
-4
No files found.
CHANGES.txt
View file @
126938e4
...
@@ -4,6 +4,8 @@ Change History
...
@@ -4,6 +4,8 @@ Change History
1.6.1 (xxx)
1.6.1 (xxx)
===========
===========
- fix Python 2.4 support (Domen Kožar)
- added travis-ci testing (Domen Kožar)
- added travis-ci testing (Domen Kožar)
1.6.0 (2012-08-15)
1.6.0 (2012-08-15)
...
...
buildout.cfg
View file @
126938e4
[buildout]
[buildout]
develop = zc.recipe.egg_ z3c.recipe.scripts_ .
develop =
zc.recipe.egg_
z3c.recipe.scripts_
.
parts = test oltest py
parts = test oltest py
versions = versions
[py]
[py]
recipe = z3c.recipe.scripts
recipe = z3c.recipe.scripts
...
@@ -28,3 +32,8 @@ defaults =
...
@@ -28,3 +32,8 @@ defaults =
'!(bootstrap|selectingpython|selecting-python)',
'!(bootstrap|selectingpython|selecting-python)',
]
]
# python2.4 compatibility
[versions]
zope.interface = 3.7.0
zope.exceptions = 3.7.1
src/zc/buildout/buildout.py
View file @
126938e4
...
@@ -917,7 +917,7 @@ class Buildout(UserDict.DictMixin):
...
@@ -917,7 +917,7 @@ class Buildout(UserDict.DictMixin):
if
sys
.
platform
==
'win32'
:
if
sys
.
platform
==
'win32'
:
should_run
+=
'-script.py'
should_run
+=
'-script.py'
if
(
realpath
(
os
.
path
.
abspath
(
sys
.
argv
[
0
]))
!=
should_run
)
:
if
realpath
(
os
.
path
.
abspath
(
sys
.
argv
[
0
]))
!=
should_run
:
self
.
_logger
.
debug
(
"Running %r."
,
realpath
(
sys
.
argv
[
0
]))
self
.
_logger
.
debug
(
"Running %r."
,
realpath
(
sys
.
argv
[
0
]))
self
.
_logger
.
debug
(
"Local buildout is %r."
,
should_run
)
self
.
_logger
.
debug
(
"Local buildout is %r."
,
should_run
)
self
.
_logger
.
warn
(
"Not upgrading because not running a local "
self
.
_logger
.
warn
(
"Not upgrading because not running a local "
...
...
src/zc/buildout/download.py
View file @
126938e4
...
@@ -174,18 +174,20 @@ class Download(object):
...
@@ -174,18 +174,20 @@ class Download(object):
self
.
logger
.
info
(
'Downloading %s'
%
url
)
self
.
logger
.
info
(
'Downloading %s'
%
url
)
urllib
.
_urlopener
=
url_opener
urllib
.
_urlopener
=
url_opener
handle
,
tmp_path
=
tempfile
.
mkstemp
(
prefix
=
'buildout-'
)
handle
,
tmp_path
=
tempfile
.
mkstemp
(
prefix
=
'buildout-'
)
try
:
try
:
tmp_path
,
headers
=
urllib
.
urlretrieve
(
url
,
tmp_path
)
try
:
if
not
check_md5sum
(
tmp_path
,
md5sum
):
tmp_path
,
headers
=
urllib
.
urlretrieve
(
url
,
tmp_path
)
raise
ChecksumError
(
if
not
check_md5sum
(
tmp_path
,
md5sum
):
'MD5 checksum mismatch downloading %r'
%
url
)
raise
ChecksumError
(
except
IOError
,
e
:
'MD5 checksum mismatch downloading %r'
%
url
)
os
.
remove
(
tmp_path
)
except
IOError
,
e
:
raise
zc
.
buildout
.
UserError
(
"Error downloading extends for URL "
os
.
remove
(
tmp_path
)
"%s: %r"
%
(
url
,
e
[
1
:
3
]))
raise
zc
.
buildout
.
UserError
(
"Error downloading extends for URL"
except
Exception
,
e
:
" %s: %r"
%
(
url
,
e
[
1
:
3
]))
os
.
remove
(
tmp_path
)
except
Exception
,
e
:
raise
os
.
remove
(
tmp_path
)
raise
finally
:
finally
:
os
.
close
(
handle
)
os
.
close
(
handle
)
...
...
src/zc/buildout/easy_install.py
View file @
126938e4
...
@@ -1181,12 +1181,12 @@ def develop(setup, dest,
...
@@ -1181,12 +1181,12 @@ def develop(setup, dest,
args
[
1
]
==
'-v'
args
[
1
]
==
'-v'
if
log_level
<
logging
.
DEBUG
:
if
log_level
<
logging
.
DEBUG
:
logger
.
debug
(
"in: %r
\
n
%s"
,
directory
,
' '
.
join
(
args
))
logger
.
debug
(
"in: %r
\
n
%s"
,
directory
,
' '
.
join
(
args
))
try
:
p
=
subprocess
.
Popen
(
subprocess
.
check_call
([
_safe_arg
(
executable
)]
+
args
)
[
_safe_arg
(
executable
)]
+
args
,
stdout
=
subprocess
.
PIPE
,
stderr
=
subprocess
.
PIPE
)
except
subprocess
.
CalledProcessError
:
if
p
.
wait
()
>
0
:
raise
zc
.
buildout
.
UserError
(
"Installing develop egg failed
"
)
raise
zc
.
buildout
.
UserError
(
"Installing develop egg failed
: %s"
%
p
.
stderr
.
read
()
)
return
_copyeggs
(
tmp3
,
dest
,
'.egg-link'
,
undo
)
return
_copyeggs
(
tmp3
,
dest
,
'.egg-link'
,
undo
)
finally
:
finally
:
...
...
src/zc/buildout/update.txt
View file @
126938e4
...
@@ -290,7 +290,5 @@ Create a broken egg
...
@@ -290,7 +290,5 @@ Create a broken egg
... eggs = broken
... eggs = broken
... """ % dict(new_releases=new_releases))
... """ % dict(new_releases=new_releases))
>>> import subprocess
>>> import subprocess
>>> subprocess.check_call([buildout])
>>> subprocess.call([buildout])
Traceback (most recent call last):
1
...
CalledProcessError: Command '['/sample-buildout/bin/buildout']' returned non-zero exit status 1
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