Ticket #147 (closed enhancement: invalid)

Opened 5 years ago

Last modified 4 years ago

passing "workdir='' " to build steps doesn't work.

Reported by: stefan Owned by:
Priority: major Milestone: undecided
Version: 0.7.6 Keywords:
Cc:

Description

All build-steps allow a 'workdir' to be explicitely specified, overriding the default value from the builder. However, the logic that decides whether to use the default or not simply checks "if workdir:...". This means that a value of won't work; the user needs to explicitely specify './' to get that effect. The obvious fix is to replace the logic "if workdir" by "if workdir is None".

Change History

comment:1 Changed 4 years ago by dustin

  • Milestone changed from undecided to 0.7.10

sounds good and easy

comment:2 Changed 4 years ago by bhearsum

I'm not sure I quite understand the bug report. Are you saying that if workdir isn't passed we should default to '.' instead of 'build'? I also can't find the 'if workdir' code you're referencing. Can you clarify?

comment:3 Changed 4 years ago by dustin

  • Type changed from defect to enhancement

No, I think that the implication is that setting workdir="" should have the same effect as workdir=".", which seems reasonable. I haven't looked at the code, but this should be relatively easy to find and change.

comment:4 Changed 4 years ago by bhearsum

Oh, I see. That makes sense, yeah.

comment:5 Changed 4 years ago by dustin

  • Status changed from new to closed
  • Resolution set to invalid

This looks like it's already done:

dustin@euclid ~/devel/projects/buildbot/t/buildbot [fixtests*] $ rgrep 'if .*workdir'
./buildbot/slave/commands.py:        if not os.path.isdir(self.workdir):
./buildbot/slave/commands.py:##         if os.path.isdir(workdir):
./buildbot/steps/source.py:        if not kwargs.has_key('workdir') and directory is not None:
./buildbot/steps/transfer.py:        if self.workdir is None:
./buildbot/steps/transfer.py:        if self.workdir is None:

I can't find anywhere that 'workdir' is used in a boolean context. Please re-open if you can point me to the code in question.

comment:6 Changed 4 years ago by dustin

  • Milestone changed from 0.7.10 to undecided
Note: See TracTickets for help on using tickets.