ingo / microsoft-teams-chat-extractor

A Chrome extension to extract chats from Microsoft Teams Web
Apache License 2.0
16 stars 5 forks source link

This extension no longer works. #1

Open mpalpha opened 3 years ago

mpalpha commented 3 years ago

Shows "Loading..." forever.

wojoNZ commented 3 years ago

Would be greatly appreciated to have this fixed.

ingo commented 3 years ago

Sorry, I missed the notifications. It's still working for me. Does anything appear in the error console? Can you show a screenshot of what it shows?

wojoNZ commented 3 years ago

Not sure how to show a proper error console. But hopefully this helps?

https://imgur.com/a/6UeCNnQ

ingo commented 3 years ago

Thanks. The screenshot shows two items, but only the info one is fully displayed. How about the full text of the one in red? Also, which browser are you using (and which OS version)?

charlesweir commented 2 years ago

Nothing in Chrome's Javascript error console. I'm using 96.0.4664.110 on MacOs Catalina 10.15.7, looking at a simple chat in a University Teams account Screenshot 2021-12-21 at 13 25 10 .

charlesweir commented 2 years ago

Ah - found out how to enable error logging. I get: Screenshot 2021-12-21 at 13 35 01

Guess maybe adding https://teams.microsoft.com/ to permissions in manifest might help?

Penagwin commented 2 years ago

It looks like teams has changed the classes they use.

.ts-msg-name    ->  .ui-chat__message__author
.message-datetime   ->  .ui-chat__message__timestamp
.message-body-content   ->  .chat__message__content

I haven't checked the others or if other things in the exporter needed modifications. This seems likely though.

EDIT: This method of scraping the DOM may no longer work on it's own, it looks like teams might be loading/unloading chats live as you scroll now

charlesweir commented 2 years ago

teams might be loading/unloading chats live as you scroll now

Indeed so. Loading as you scroll isn't a problem (there are several plugins to automate scrolling), but Teams now unloads all messages but those closest to the page you're viewing. So to do the job properly we'd need to force scroll AND cumulatively save messages as we do so.

charlesweir commented 2 years ago

Teams now unloads all messages but those closest to the page you're viewing

Wait a moment.... Just thought to check this by taking my machine offline and then scrolling back to the 'unloaded' messages. No. Teams doesn't unload the off-screen messages; instead it keeps them cached, but renders them as grey blocks until it has a chance to catch up. In fact, it loads a lot more messages initially than it shows. When I capture the grey blocks using a breakpoint, I find it's a virtual-repeat HTML element: I'm guessing that's a Chrome optimisation of the Angular-JS md-virtual-repeat element. It contains only the currently-rendered messages. To get the rest, maybe one could query its provider object?

StoreMax commented 2 years ago

Hi, has there been any progress on this?

pbulteel commented 1 year ago

Anything? It's been a year 😄

1JotaPe1 commented 10 months ago

yeah it's over! :) but it was a good project thou