Skip to content

Make Python3.6+ compliant #26

@deadbits

Description

@deadbits

To get a wider user base and ensure we can support both Python2.7 and Python3.6+, we'll need to make some changes:

  • Ensure all dependencies from requirements.txt are Py3.6+ compatible
  • Ensure all exceptions are handled correctly
  • Handle print as print(foo) versus print foo
  • Use fstrings and new format method in places where it makes sense:
  • ...
  • ... ongoing as I find more requirements
new: info(f'{artifact} tags: {result}')

original: info('%s tags: %s' % (artifact, result))
new: 
build_version = 'v{}.{}-{}_{}'.format(__app_major, rev_count.strip(), rev_hash.strip(), __app_stage)
app_version = 'v{}.{}_{}'.format(__app_major, rev_count.strip(), __app_stage)

old:
build_version = 'v%s.%s-%s_%s' % (__app_major, rev_count.strip(), rev_hash.strip(), __app_stage)
app_version = 'v%s.%s_%s' % (__app_major, rev_count.strip(), __app_stage)

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions