Python Forum
[SOLVED] OSError: [Errno 22] Invalid argument
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[SOLVED] OSError: [Errno 22] Invalid argument
#10
the colon is not allowed in file name. Use something like
hdlr = logging.FileHandler('Path to the log file/Logs/log{}.log'.format(datetime.datetime.strftime(datetime.datetime.now(), '%Y%m%d%H%M%S_%f'))
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs

Reply


Messages In This Thread
RE: OSError: [Errno 22] Invalid argument - by wavic - Jun-03-2018, 02:09 PM
RE: OSError: [Errno 22] Invalid argument - by Panda - Jun-03-2018, 02:10 PM
RE: OSError: [Errno 22] Invalid argument - by wavic - Jun-03-2018, 02:12 PM
RE: OSError: [Errno 22] Invalid argument - by Panda - Jun-03-2018, 02:15 PM
RE: OSError: [Errno 22] Invalid argument - by wavic - Jun-03-2018, 02:21 PM
RE: OSError: [Errno 22] Invalid argument - by Panda - Jun-03-2018, 02:24 PM
RE: OSError: [Errno 22] Invalid argument - by wavic - Jun-03-2018, 02:30 PM
RE: OSError: [Errno 22] Invalid argument - by Panda - Jun-03-2018, 02:31 PM
RE: OSError: [Errno 22] Invalid argument - by buran - Jun-03-2018, 02:39 PM
RE: OSError: [Errno 22] Invalid argument - by Panda - Jun-03-2018, 02:51 PM
RE: OSError: [Errno 22] Invalid argument - by wavic - Jun-03-2018, 02:41 PM
RE: OSError: [Errno 22] Invalid argument - by buran - Jun-03-2018, 02:55 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  OSError occurs in Linux. anna17 2 385 Mar-23-2024, 10:00 PM
Last Post: snippsat
  Invalid argument: 'images\x08ackground.jpg' CatBall 4 1,031 Jun-19-2023, 09:28 AM
Last Post: CatBall
  OSError with SMPT script Milan 0 835 Apr-28-2023, 01:34 PM
Last Post: Milan
  OSERROR When mkdir Oshadha 4 1,845 Jun-29-2022, 08:50 AM
Last Post: DeaD_EyE
  [split] [Errno 22] Invalid argument Junaid 0 2,318 Jun-12-2021, 06:02 PM
Last Post: Junaid
  [solved] Variable number of dictionnaries as argument in def() paul18fr 11 6,264 Apr-20-2021, 11:15 AM
Last Post: paul18fr
  OSError: Unable to load libjvm when connecting to hdfs with pyarrow 3.0.0 aupres 0 3,214 Mar-22-2021, 10:25 AM
Last Post: aupres
  pyarrow throws oserror winerror 193 1 is not a valid win32 application aupres 2 3,850 Oct-21-2020, 01:04 AM
Last Post: aupres
  [Errno 22] Invalid argument satyaneel 11 106,690 Jul-14-2020, 08:47 AM
Last Post: lichunming
  zlib decompress error: invalid code lengths set / invalid block type DreamingInsanity 0 6,945 Mar-29-2020, 12:44 PM
Last Post: DreamingInsanity

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020