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
Nicolas Wavrant
slapos.buildout
Commits
539e2232
Commit
539e2232
authored
Dec 14, 2012
by
Patrick Strawderman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix macro "inheritance" bug.
parent
219b3b3e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
36 additions
and
1 deletion
+36
-1
src/zc/buildout/buildout.py
src/zc/buildout/buildout.py
+2
-1
src/zc/buildout/tests.py
src/zc/buildout/tests.py
+34
-0
No files found.
src/zc/buildout/buildout.py
View file @
539e2232
...
@@ -1117,7 +1117,7 @@ class Options(DictMixin):
...
@@ -1117,7 +1117,7 @@ class Options(DictMixin):
raise
zc
.
buildout
.
UserError
(
"Infinite extending loop %r"
%
name
)
raise
zc
.
buildout
.
UserError
(
"Infinite extending loop %r"
%
name
)
doing
.
append
(
name
)
doing
.
append
(
name
)
try
:
try
:
to_do
=
data
.
pop
(
'<'
,
None
)
to_do
=
data
.
get
(
'<'
,
None
)
if
to_do
is
None
:
if
to_do
is
None
:
return
data
return
data
__doing__
=
'Loading input sections for %r'
,
name
__doing__
=
'Loading input sections for %r'
,
name
...
@@ -1133,6 +1133,7 @@ class Options(DictMixin):
...
@@ -1133,6 +1133,7 @@ class Options(DictMixin):
result
.
update
(
self
.
_do_extend_raw
(
iname
,
raw
,
doing
))
result
.
update
(
self
.
_do_extend_raw
(
iname
,
raw
,
doing
))
result
.
update
(
data
)
result
.
update
(
data
)
result
.
pop
(
'<'
)
return
result
return
result
finally
:
finally
:
assert
doing
.
pop
()
==
name
assert
doing
.
pop
()
==
name
...
...
src/zc/buildout/tests.py
View file @
539e2232
...
@@ -2715,6 +2715,40 @@ def want_new_zcrecipeegg():
...
@@ -2715,6 +2715,40 @@ def want_new_zcrecipeegg():
Error: Bad constraint >=2.0.0a3 zc.recipe.egg<2dev
Error: Bad constraint >=2.0.0a3 zc.recipe.egg<2dev
"""
"""
def
macro_inheritance_bug
():
"""
There was a bug preventing a section from using another section as a macro
if that section was extended with macros, and both sections were listed as
parts (phew!). The following contrived example demonstrates that this
now works.
>>> write('buildout.cfg',
... '''
... [buildout]
... parts = foo bar
... [base]
... recipe = zc.recipe.egg
... [foo]
... <=base
... eggs = zc.buildout
... interpreter = python
... [bar]
... <=foo
... interpreter = py
... ''')
>>> print_(system(join('bin', 'buildout')), end='') # doctest: +ELLIPSIS
Installing foo.
...
Installing bar.
...
>>> ls("./bin")
- buildout
- py
- python
"""
######################################################################
######################################################################
...
...
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