Skip to content

Commit

Permalink
handle explict pardir relative paths in packages
Browse files Browse the repository at this point in the history
  • Loading branch information
sfoster1 committed Jan 12, 2024
1 parent 4a5d8cf commit 19776cf
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions layers/meta-opentrons/classes/pipenv_app_bundle.bbclass
Original file line number Diff line number Diff line change
Expand Up @@ -97,19 +97,19 @@ python do_rewrite_requirements() {
bb.debug(1, 'Checking ' + plainname)

if line.startswith('--index-url'): pypi.append(line)
elif line.startswith('--editable') or line.startswith('./'):
elif line.startswith('--editable') or (line.startswith('./') or line.startswith('../')):
# an editable probably-local package
if line.startswith('--editable'):
working = line.split('--editable')[-1].strip()
else:
working = line.strip()
if not working.startswith('./'):
if not (working.startswith('./') or working.startswith('../')):
bb.debug(1, 'Skipping {}'.format(line))
continue
working = d.getVar('PIPENV_APP_BUNDLE_PROJECT_ROOT') + '/' + working
local.append(working)
bb.debug(1, 'Rewrote local path to ' + working)
elif not line.startswith('.') and not '://' in line:
elif not (line.startswith('.') or line.startswith('../')) and not '://' in line:
# This is a package from pypi; check if it's global
first_nonalpha = [c for c in line if c in '=~^<>']
pkgname = line.split(first_nonalpha[0])[0] if first_nonalpha else line
Expand Down

0 comments on commit 19776cf

Please sign in to comment.