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

Add function to clean WIDEn-N and * from path, leaving just digi callsigns #46

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

wsmitchell3
Copy link
Contributor

Added a function to turn a digi path list into a list of digis through which the packet passed.
Path: ['K0ABC-1','WIDE1*','W0DEF-2','N0GHI-1*']
becomes digi path: ['K0ABC-1','W0DEF-2','N0GHI-1']
This is useful for anyone interested in getting just the digipeaters in the path without the extraneous routing info.

@rossengeorgiev
Copy link
Owner

Hi @wsmitchell3, thanks for the contribution, but I feel this doesn't need to part of the package. It can be reduced to single line path = list(filter(lambda x: not re.match(r'WIDE[0-9\-\*]+$', x), path)). I'm not sure how useful this could be in general, but it could be put under like aprslib.util module as helper function.

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

Successfully merging this pull request may close these issues.

2 participants