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

No delimiter defiend when no mails #18

Open
Schluggi opened this issue Sep 30, 2020 · 3 comments
Open

No delimiter defiend when no mails #18

Schluggi opened this issue Sep 30, 2020 · 3 comments
Assignees
Labels
bug Something isn't working

Comments

@Schluggi
Copy link
Owner

If one of the mailboxes has no mails, pymap-copy can't determine the delimiter and the tool will crash.

This will be fixed with #17.

@Schluggi Schluggi added the bug Something isn't working label Sep 30, 2020
@Schluggi Schluggi self-assigned this Sep 30, 2020
@Schluggi Schluggi changed the title Do delimiter defiend when no mails No delimiter defiend when no mails Oct 1, 2020
@donvito-pl
Copy link

donvito-pl commented Dec 4, 2020

Hi. When trying to migrate mailbox (full of e-mails) I get this:
Python 3.7.3

Traceback (most recent call last):
File "pymap-copy.py", line 446, in
df_name = sf_name.replace(source_delimiter, destination_delimiter)
TypeError: replace() argument 2 must be str, not None

--destination-root into non-existing folder seems to cause the problem.

@Schluggi
Copy link
Owner Author

Schluggi commented Dec 4, 2020

You can try to predefine the destination delimiter in line 154. If the delimiter is None the script will look at the first folder and grap that delimiter. Without an existing destination root it will stay None and the error eccurs.

I'll fix it in the future but in your case line 154 will fix it for now.

@donvito-pl
Copy link

donvito-pl commented Dec 4, 2020

Changing line 154, as suggested, solved the problem

destination_delimiter, source_delimiter = ".", "."

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants