Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cherry-pick #16388 to 7.x: Fix generation of notice file in CSV format #16399

Merged
merged 1 commit into from
Feb 19, 2020

Conversation

jsoriano
Copy link
Member

Cherry-pick of PR #16388 to 7.x branch. Original message:

Fix generation of notice file in CSV format, and make ./dev-tools/generate_notice.py executable, so it can be directly executed and correct python interpreter will be taken from the shebang.

This script was failing with this error when used to generate the output in CSV format.

Get the licenses available from ['./vendor']
WARNING: No version information found for: github.com/prometheus/client_model
WARNING: No version information found for: github.com/Azure/azure-storage-blob-go
WARNING: No version information found for: github.com/Azure/azure-pipeline-go
WARNING: No version information found for: github.com/godror/godror/odpi
WARNING: No version information found for: github.com/go-ini/ini
Traceback (most recent call last):
  File "dev-tools/generate_notice.py", line 417, in <module>
    dependencies = create_notice(notice, args.beat, args.copyright, vendor_dirs, args.csvfile, overrides=overrides)
  File "dev-tools/generate_notice.py", line 227, in create_notice
    write_csv_file(csvwriter, dependencies)
  File "dev-tools/generate_notice.py", line 204, in write_csv_file
    csvwriter.writerow(["name", "url", "version", "revision", "license"])
TypeError: a bytes-like object is required, not 'str'

It could be reproduced with python3 ./dev-tools/generate_notice.py . --csv foo.csv.

@jsoriano jsoriano merged commit e8d1561 into elastic:7.x Feb 19, 2020
@jsoriano jsoriano deleted the backport_16388_7.x branch February 19, 2020 09:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants