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

How to exclude field from export #31

Open
dgassman3 opened this issue Aug 11, 2017 · 2 comments
Open

How to exclude field from export #31

dgassman3 opened this issue Aug 11, 2017 · 2 comments

Comments

@dgassman3
Copy link

This is a great script btw, was hard to find something that did the trick. That said, due to odd characters used, the message portion of the export doesn't always format correctly. I cannot quite identify where to modify the code to exclude that field. I would be fine with just the group, date, user and like count.

Any suggestions? I had played with a few different delimiters but the format was still a bit messy. Thanks!

@youyanggu
Copy link
Owner

Line 197: https://github.com/youyanggu/groupme_stats/blob/master/retrieve_msgs.py#L197

Just remove "text.encode('utf-8')," and it should skip the message field. Let me know if you run into any issues.

@dgassman3
Copy link
Author

Thanks for the reply. I was able to overcome this by using this line of code to set the text variable:

text = "".join(filter(unicode.isalpha, text))

It removes spaces and numbers, but for what I needed, largely got the job done.

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