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

Attempt to use a CSV file failed #3

Open
valencetech opened this issue Feb 14, 2018 · 2 comments
Open

Attempt to use a CSV file failed #3

valencetech opened this issue Feb 14, 2018 · 2 comments

Comments

@valencetech
Copy link

»cat resources.csv
Id,Region,Business Unit,Project,Owner,ApplicationService,environment
i-11111111111111111,eu-west-1,Commercial-and-Marketing,Loyalty,,Container,
i-22222222222222222,eu-west-2,Commercial-and-Marketing,Loyalty,,Container,
i-3333333333333333,eu-west-3,Commercial-and-Marketing,Loyalty,,Container,

» aws-tagger --csv resources.csv
Traceback (most recent call last):
File "/usr/local/bin/aws-tagger", line 11, in
load_entry_point('aws-tagger==0.6.1', 'console_scripts', 'aws-tagger')()
File "/Library/Python/2.7/site-packages/click/core.py", line 722, in call
return self.main(*args, **kwargs)
File "/Library/Python/2.7/site-packages/click/core.py", line 697, in main
rv = self.invoke(ctx)
File "/Library/Python/2.7/site-packages/click/core.py", line 895, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/Library/Python/2.7/site-packages/click/core.py", line 535, in invoke
return callback(*args, **kwargs)
File "/Library/Python/2.7/site-packages/tagger/cli.py", line 22, in cli
tagger.tag(csv)
File "/Library/Python/2.7/site-packages/tagger/tagger.py", line 151, in tag
self._tag_resource(tag_index, row)
File "/Library/Python/2.7/site-packages/tagger/tagger.py", line 161, in _tag_resource
resource_id = row[tag_index[self.resource_id_column]]
KeyError: 'Id'

@bruth
Copy link

bruth commented Jul 3, 2018

This is likely due to the BOM if you exported this from Excel.. https://stackoverflow.com/a/17912811/407954

@bruth
Copy link

bruth commented Jul 3, 2018

Created #6

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants