Skip to content

Replace print() in documentation #1257

@niccokunzmann

Description

@niccokunzmann

The print statement in the documentation has been modified. However, this causes confusion.

Current solution

  • to convert bytes to string - Python 2 compatible
  • provide an easy way to display the resulting component as ics

Current Problems

  • when you copy & paste the code, you get a different output
  • that can be confusing

Future ideas

I would like people to be able to view and see, grasp and have documented well the resulting ICS output and calendar.

  • it would be nice to use ics syntax highlighting on the <output>
  • it would be nice to do something like this in the docs:
>>> from icalendar import Calendar
>>> calendar = Calendar.new()
>>> calendar.view()
<output>
  • When using the above statement, what I would like to be able to switch between ics and jcal output in the documentation, like sphinx-icalendar.

Implementation

  • test/conftest.py needs changing
  • if we go with view(), then, this goes into Component
  • A new solution should solve the problems and discuss the best way forward for the ideas

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions