DJF3 / Webex-Message-space-archiver

Archive Cisco Webex Teams Space messages to a single HTML file. Highly configurable (download files/images, sort order, max messages or age, avatars, etc)
Other
55 stars 19 forks source link

Issue - subfolder creation fails when team name ends in trailing space #2

Closed chriskoch99 closed 3 years ago

chriskoch99 commented 3 years ago

Didn't realize one of our Teams spaces was named with a trailing space. The archiver trips on this, per below:

Traceback (most recent call last):
  File "E:\temp\teams\webex-teams-space-archive.py", line 1030, in <module>
    os.makedirs(myAttachmentFolder + "/files/")
225, in makedirs
    mkdir(name, mode)
FileNotFoundError: [WinError 3] The system cannot find the path specified: 'Sample Space /files/'

Obviously the space name shouldn't have the trailing space, and I've renamed it, but FYI.

DJF3 commented 3 years ago

This should now be fixed. I added ".strip()" to the line below in function get_roomname return str(returndata.strip()) It removes leading/trailing spaces from the space name

chriskoch99 commented 3 years ago

Awesome, thanks!

DJF3 commented 3 years ago

closed