Skip to content

Start Time & End Time: Allow empty cells #4

@styroll

Description

@styroll

Thank you for your great tool. It finally worked. I was looking for an alternative way creating an ICS-File without using MS Outlook (only Outlook Classic allows exporting ICS files) or online calendars (like Google Calendar) or online converters. The workflow to date was:

  1. Creating the database with events in MS Access and exporting to XLS for distribution of a printed version (all done by an external person). That's why start time and end time cells are often empty and start date and end date are identical, cf. the following screenshot below.
  2. Conversion form XLSX to CSV using Excel and importing the CSV file into MS, then export to ICS (all done by myself). MS Outlook is creating an all-day event if Start Time and End Time are missing and is creating an 1-hour event, when only Start Time is given.
Image

.
Unfortunately your CLI tool expects Start Time & End Time in each cell:

    raise ValueError("time data %r does not match format %r" %
                     (data_string, format))
ValueError: time data '2025-08-14 ' does not match format '%Y-%m-%d %H:%M'

I was indeed able to to add this data using some IF formulas in Excel. However, it would be great, if your tool would complete this time data by itself and correct the End Date in case of all-day events, e.g. in this way:

  1. If Start Date = End Date and Start Time is empty, then set Start Time to 00:00 and End Time to 00:00 and End Date to "End date + 1 day"
  2. If Start Time ist not empty and End Time is empty, set End Time to "Start Time + 1 hour"

The ReadMe may be optimized too:

  1. The order and the number (7) of columns is given (that's why you can rename the column header name, but cannot omit the name, e.g. for the last two columns, even if they are empty).
  2. The quotation marks are only needed in the case you use commas in text strings.
  3. The CSV file has to use UTF-8 as text encoding (there were some corresponding errors in my terminal output).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions