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

1. Initialize Address Parser Object AttributeError #13

Open
Mulliganisoup opened this issue Oct 17, 2023 · 3 comments
Open

1. Initialize Address Parser Object AttributeError #13

Mulliganisoup opened this issue Oct 17, 2023 · 3 comments

Comments

@Mulliganisoup
Copy link

If anyone else is getting the error:

" Exception has occurred: AttributeError
'AddressParser' object has no attribute 'parse_address'
File "C:\Users\libparse.py", line 11, in
parsed_address = parser.parse_address("The White House 1600 Pennsylvania Avenue NW, Washington, DC 20500, USA")
^^^^^^^^^^^^^^^^^^^^
AttributeError: 'AddressParser' object has no attribute 'parse_address'"

Change the line:
parsed_address = parser.parse_address("The White House 1600 Pennsylvania Avenue NW, Washington, DC 20500, USA")

To:
parsed_address = parser.runParser("The White House 1600 Pennsylvania Avenue NW, Washington, DC 20500, USA")

Documentation: https://pypi.org/project/pypostalwin/

@DSBay
Copy link

DSBay commented Nov 19, 2023

otherwise, replace '../site-packages/pypostalwin.py' code with the new one in GitHub. There is, however, an issue with the json.loads() output, since it only works on single json objects and libpostal's address_parser.exe outputs multiple json objects.

@selva221724
Copy link
Owner

thanks a lot @DSBay , i saw your suggestion on these, let me fix these soon !! if you like to be a part of the group, i can add you as a contributor too!!

@BayProjects
Copy link

I would love that! Could you please add my personal account? BayProjects

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

4 participants