Comments (8)
Hello, thank you for adding this information. I think I have found the cause of this error. I am working towards a fix, in the interim if you set your environmental variables to use the active profile and dont use the --profile
flag, that should work until I can get this fix pushed.
from ec2-classic-resource-finder.
Turns out a few extra tabs in the wrong places make a whole world of difference. I have pushed a fix which should resolve this issue. (NOTE: this bug also affected organizational runs as well, although they saw a much less verbose error)
from ec2-classic-resource-finder.
Is this only happening when you're using a profile or does it occur with other authentication methods? also, do you only and always get this error under Data Pipelines, or does it happen under other services at all?
from ec2-classic-resource-finder.
Profile is the only method I've tried so far, I haven't tried with role assumption. It always happens right at the end under data pipelines, so each time I run the script the output is just like that.
from ec2-classic-resource-finder.
Ok, thank you. Let me do some testing in my environment and see if I can replicate this.
from ec2-classic-resource-finder.
fwiw, I'm experiencing essentially the same reported behavior (with python 3.3.8 on Ubuntu 20.04.3 on WSL2 on Windows 10 21H1 build 19043.1348) when I use --profile
...
$ python3 py-Classic-Resource-Finder.py --profile myprofile
Checking the Classic platform status in us-east-1
Checking for EIPs in us-east-1
Checking for Classic EC2 Instances in us-east-1
-- snip --
Checking for Classic Data Pipelines in us-east-1
Traceback (most recent call last):
File "../py-Classic-Resource-Finder.py", line 847, in <module>
main(argparser(sys.argv[1:]))
File "../py-Classic-Resource-Finder.py", line 841, in main
loopregions(classicregions, datapipelineregions, creddict)
File "../py-Classic-Resource-Finder.py", line 668, in loopregions
process.start()
File "/usr/lib/python3.8/multiprocessing/process.py", line 115, in start
assert self._popen is None, 'cannot start a process twice'
AssertionError: cannot start a process twice
...however, the code seems to work correctly when the same profile is active via environment variable.
$ env AWS_PROFILE=myprofile python3 py-Classic-Resource-Finder.py
-- snip --
Checking for Classic OpsWorks stacks in ap-southeast-2
Checking for Classic OpsWorks stacks in ap-southeast-1
Checking for Classic Data Pipelines in ap-southeast-2
finished
Out of curiosity, I tried specifying the same profile in both places.
$ env AWS_PROFILE=myprofile python3 py-Classic-Resource-Finder.py --profile myprofile
...but this also fails, with the same error that occurs when using --profile
alone.
In my environment, I don't use a [default]
section in ~/.aws/config
(to avoid inadvertently/implicitly using a set of credentials or region) but adding that section with a valid key and secret also did not seem to make any difference -- the code still fails with the same error when using --profile
.
from ec2-classic-resource-finder.
Can confirm using the environment variable to set profile works. Thanks!
from ec2-classic-resource-finder.
Can confirm using the environment variable to set profile works. Thanks!
I was having the same issue.
But setting the environment variable to the right profile did the trick.
Of course without using the -p option.
Thanks Scott
from ec2-classic-resource-finder.
Related Issues (19)
- Fails on Beanstalk applications with a space in the name HOT 1
- Script is failing today when attempting to connect to certain regions HOT 1
- Please add CLI profile support HOT 1
- ElasticBeanstalk Environments with Classic LBs are not detected HOT 2
- More details for Unknown status HOT 1
- More information about default security groups HOT 1
- Space in EB App Name cause incorrect data HOT 1
- a continue statement will make this run faster for regions without classic HOT 1
- Why does it flag default security groups as EC2 Classic resources? HOT 1
- Empty CSV files? HOT 2
- Use #!/usr/bin/env python3 instead of #!/usr/bin/python3
- China region is not supported
- Why do ElasticBeanstalk environments that are Terminated show up in `Classic_ElasticBeanstalk_Applications_Environments.csv`? HOT 3
- Missing permissions for elasticloadbalancing and elasticmapreduce HOT 2
- Prompts for MFA on every region in every account
- Allow regions to be specified HOT 1
- False positives on RDS instances HOT 2
- Clarification on output of CSVs needed HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ec2-classic-resource-finder.