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

TypeError: argument of type 'WindowsPath' is not iterable #33

Open
dip16gphy opened this issue Apr 2, 2022 · 7 comments
Open

TypeError: argument of type 'WindowsPath' is not iterable #33

dip16gphy opened this issue Apr 2, 2022 · 7 comments

Comments

@dip16gphy
Copy link

dip16gphy commented Apr 2, 2022

While using rfpy_ccp PBA.pkl --start=92.74,11.66 --end=92.75,11.65 --snr=10 --snrh=5 --no-outlier --load --prep --prestack --ccp --gccp --linear --figure , I am getting this error.

Traceback (most recent call last):
File "c:\users\uplc\anaconda3\envs\rfpy\lib\runpy.py", line 194, in _run_module_as_main
return _run_code(code, main_globals, None,
File "c:\users\uplc\anaconda3\envs\rfpy\lib\runpy.py", line 87, in run_code
exec(code, run_globals)
File "C:\Users\UPLC\anaconda3\envs\rfpy\Scripts\rfpy_ccp.exe_main
.py", line 7, in
File "c:\users\uplc\anaconda3\envs\rfpy\lib\site-packages\rfpy\scripts\rfpy_ccp.py", line 623, in main
ccpimage.save(prep_file)
File "c:\users\uplc\anaconda3\envs\rfpy\lib\site-packages\rfpy\ccp.py", line 637, in save
if not ".pkl" in title:
TypeError: argument of type 'WindowsPath' is not iterable

However, the message also shows this before throwing error:
image

@wasjabloch
Copy link
Collaborator

This should be fixed in the current master branch. Can you please test it and see if it resolved your issue?

@dip16gphy
Copy link
Author

rfpy_ccp PBA.pkl --start=92.74,11.66 --end=92.75,11.65 --snr=10 --snrh=5 --no-outlier --load --prep --prestack --ccp --gccp --linear --figure

Again it throws the same error as above.

@wasjabloch
Copy link
Collaborator

Please have a look at the updated version and let me know if the issue persists.

@dip16gphy
Copy link
Author

Please have a look at the updated version and let me know if the issue persists.

nothing changes!! Again same error

@wasjabloch
Copy link
Collaborator

The problem is not obvious to me. Can you please copy+paste the entire Traceback here?

@wasjabloch wasjabloch reopened this Apr 28, 2022
@dip16gphy
Copy link
Author

Traceback (most recent call last):
File "c:\users\uplc\anaconda3\envs\rfpy\lib\runpy.py", line 194, in _run_module_as_main
return run_code(code, main_globals, None,
File "c:\users\uplc\anaconda3\envs\rfpy\lib\runpy.py", line 87, in run_code exec(code, run_globals) File "C:\Users\UPLC\anaconda3\envs\rfpy\Scripts\rfpy_ccp.exe__main
.py", line 7, in
File "c:\users\uplc\anaconda3\envs\rfpy\lib\site-packages\rfpy\scripts\rfpy_ccp.py", line 623, in main
ccpimage.save(prep_file)
File "c:\users\uplc\anaconda3\envs\rfpy\lib\site-packages\rfpy\ccp.py", line 637, in save
if not ".pkl" in title:
TypeError: argument of type 'WindowsPath' is not iterable

Traceback (most recent call last):
File "c:\users\uplc\anaconda3\envs\rfpy\lib\runpy.py", line 194, in _run_module_as_main
return _run_code(code, main_globals, None,
File "c:\users\uplc\anaconda3\envs\rfpy\lib\runpy.py", line 87, in run_code
exec(code, run_globals)
File "C:\Users\UPLC\anaconda3\envs\rfpy\Scripts\rfpy_ccp.exe_main.py", line 7, in
File "c:\users\uplc\anaconda3\envs\rfpy\lib\site-packages\rfpy\scripts\rfpy_ccp.py", line 623, in main
ccpimage.save(prep_file)
File "c:\users\uplc\anaconda3\envs\rfpy\lib\site-packages\rfpy\ccp.py", line 637, in save
if not ".pkl" in title:
TypeError: argument of type 'WindowsPath' is not iterable

@wasjabloch
Copy link
Collaborator

wasjabloch commented Apr 29, 2022

It looks like you are still using the former version of RfPy. The line in question has now moved to 638, instead of 637, where your error is occurring. This suggests that in the code you are using line 633 does not contain the most recent fix

title = str(title)

Please try downloading the most recent RfPy version and re-installing it.

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