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

Does not download all volunteer positions #55

Closed
fkrauthan opened this issue Oct 28, 2021 · 6 comments · Fixed by #57
Closed

Does not download all volunteer positions #55

fkrauthan opened this issue Oct 28, 2021 · 6 comments · Fixed by #57
Assignees
Labels
bug Something isn't working

Comments

@fkrauthan
Copy link

It seems like for some reason it does not download all volunteer positions (only top 3 are included in the json).

joshuatz added a commit that referenced this issue Nov 1, 2021
 - Fix incomplete volunteer experiences - LI is paginating the entries,
 so fix is to check for truncated results and if so, use pagination
 DASH endpoint. Fixes #55
 - Chore: Add ignore-rev entry for previous large linting commit
@joshuatz
Copy link
Owner

joshuatz commented Nov 1, 2021

@fkrauthan Thanks for reporting. I can confirm this issue exists - for certain items within a profile, LinkedIn will only load the first three entries, and require that subsequent entries be loaded lazily, with pagination (e.g., if you have 5 volunteer entries, you get the first 3 on the initial page load, and the final 2 have to be separately loaded).

I've added code to check if volunteer experiences are truncated, and if so, perform the necessary action to load and parse the remaining entries. This fix has been rolled into the new v3.0.0 release.

Thanks for reporting, and also kudos on having that many volunteer experiences! 😄

@fkrauthan
Copy link
Author

haha thanks. Yeah I am currently redoing my website and plan to regenerate most of my about me page based on linkedin data so I've noticed that some stuff was missing :D I did actually build a quick local fix for that as well. But I was not able to figure out how to retrieve them in the proper order (the only endpoint I could find returns them in a random order).

@joshuatz
Copy link
Owner

joshuatz commented Nov 1, 2021

returns them in a random order

😬 Whoops, I'm like 99% certain I need to reopen this issue now lol. I totally forgot about ordering and although v3.0.0 now brings in all volunteer entries, it does a direct lookup by type, which does not preserve order.

@joshuatz joshuatz reopened this Nov 1, 2021
@joshuatz joshuatz added the bug Something isn't working label Nov 1, 2021
@joshuatz joshuatz self-assigned this Nov 1, 2021
@fkrauthan
Copy link
Author

I also tried to check what LinkedIn itself is issuing to load the rest of volunteer entries but couldn't see any API call. But to be honest a lot of the way linkedin does looks rather strange.

joshuatz added a commit that referenced this issue Nov 8, 2021
 - Refactor DB builder, try to do a better job of preserving original
 order of LI entities, if response includes a direct `*elements* urn
 array. Should fix ordering issue in #55
 - Cleanup typo
@joshuatz
Copy link
Owner

joshuatz commented Nov 8, 2021

@fkrauthan OK, ordering should fixed now too (in latest v3.1.0 release). The fix for this should actually fix ordering in a few other places, so thanks for reminding me about it!

And about the way LinkedIn internal APIs / loaders work... yeah, they are indeed strange.

@joshuatz joshuatz closed this as completed Nov 8, 2021
@fkrauthan
Copy link
Author

Perfect I will give this and the other ticket a try probably tomorrow :)

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
2 participants