DESCRIPTION.rst 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162
  1. ======================================
  2. hyperframe: Pure-Python HTTP/2 framing
  3. ======================================
  4. .. image:: https://travis-ci.org/python-hyper/hyperframe.png?branch=master
  5. :target: https://travis-ci.org/python-hyper/hyperframe
  6. This library contains the HTTP/2 framing code used in the `hyper`_ project. It
  7. provides a pure-Python codebase that is capable of decoding a binary stream
  8. into HTTP/2 frames.
  9. This library is used directly by `hyper`_ and a number of other projects to
  10. provide HTTP/2 frame decoding logic.
  11. Contributing
  12. ============
  13. hyperframe welcomes contributions from anyone! Unlike many other projects we
  14. are happy to accept cosmetic contributions and small contributions, in addition
  15. to large feature requests and changes.
  16. Before you contribute (either by opening an issue or filing a pull request),
  17. please `read the contribution guidelines`_.
  18. .. _read the contribution guidelines: http://hyper.readthedocs.org/en/development/contributing.html
  19. License
  20. =======
  21. hyperframe is made available under the MIT License. For more details, see the
  22. ``LICENSE`` file in the repository.
  23. Authors
  24. =======
  25. hyperframe is maintained by Cory Benfield, with contributions from others. For
  26. more details about the contributors, please see ``CONTRIBUTORS.rst``.
  27. .. _hyper: http://python-hyper.org/
  28. Release History
  29. ===============
  30. dev
  31. ---
  32. **API Changes (Backward-compatible)**
  33. - Invalid PING frame bodies now raise ``InvalidFrameError``, not
  34. ``ValueError``. Note that ``InvalidFrameError`` is a ``ValueError`` subclass.
  35. - Invalid RST_STREAM frame bodies now raise ``InvalidFramError``, not
  36. ``ValueError``. Note that ``InvalidFrameError`` is a ``ValueError`` subclass.
  37. - Canonicalized the names of ``SettingsFrame.SETTINGS_MAX_FRAME_SIZE`` and
  38. ``SettingsFrame.SETTINGS_MAX_HEADER_LIST_SIZE`` to match their peers, by
  39. adding new properties ``SettingsFrame.MAX_FRAME_SIZE`` and
  40. ``SettingsFrame.SETTINGS_MAX_HEADER_LIST_SIZE``. The old names are still
  41. present, but will be deprecated in 4.0.0.
  42. **Bugfixes**
  43. - The change in ``3.1.0`` that ensured that ``InvalidFrameError`` would be
  44. thrown did not affect certain invalid values in ALT_SVC frames. This has been
  45. fixed: ``ValueError`` will no longer be thrown from invalid ALT_SVC bodies.
  46. 3.1.1 (2016-01-18)
  47. ------------------
  48. **Bugfixes**
  49. - Correctly error when receiving Ping frames that have insufficient data.
  50. 3.1.0 (2016-01-13)
  51. ------------------
  52. **API Changes**
  53. - Added new ``InvalidFrameError`` that is thrown instead of ``struct.error``
  54. when parsing a frame.
  55. **Bugfixes**
  56. - Fixed error when trying to serialize frames that use Priority information
  57. with the defaults for that information.
  58. - Fixed errors when displaying the repr of frames with non-printable bodies.
  59. 3.0.1 (2016-01-08)
  60. ------------------
  61. **Bugfixes**
  62. - Fix issue where unpadded DATA, PUSH_PROMISE and HEADERS frames that had empty
  63. bodies would raise ``InvalidPaddingError`` exceptions when parsed.
  64. 3.0.0 (2016-01-08)
  65. ------------------
  66. **Backwards Incompatible API Changes**
  67. - Parsing padded frames that have invalid padding sizes now throws an
  68. ``InvalidPaddingError``.
  69. 2.2.0 (2015-10-15)
  70. ------------------
  71. **API Changes**
  72. - When an unknown frame is encountered, ``parse_frame_header`` now throws a
  73. ``ValueError`` subclass: ``UnknownFrameError``. This subclass contains the
  74. frame type and the length of the frame body.
  75. 2.1.0 (2015-10-06)
  76. ------------------
  77. **API Changes**
  78. - Frames parsed from binary data now carry a ``body_len`` attribute that
  79. matches the frame length (minus the frame header).
  80. 2.0.0 (2015-09-21)
  81. ------------------
  82. **API Changes**
  83. - Attempting to parse unrecognised frames now throws ``ValueError`` instead of
  84. ``KeyError``. Thanks to @Kriechi!
  85. - Flags are now validated for correctness, preventing setting flags that
  86. ``hyperframe`` does not recognise and that would not serialize. Thanks to
  87. @mhils!
  88. - Frame properties can now be initialized in the constructors. Thanks to @mhils
  89. and @Kriechi!
  90. - Frames that cannot be sent on a stream now have their stream ID defaulted
  91. to ``0``. Thanks to @Kriechi!
  92. **Other Changes**
  93. - Frames have a more useful repr. Thanks to @mhils!
  94. 1.1.1 (2015-07-20)
  95. ------------------
  96. - Fix a bug where ``FRAME_MAX_LEN`` was one byte too small.
  97. 1.1.0 (2015-06-28)
  98. ------------------
  99. - Add ``body_len`` property to frames to enable introspection of the actual
  100. frame length. Thanks to @jdecuyper!
  101. 1.0.1 (2015-06-27)
  102. ------------------
  103. - Fix bug where the frame header would have an incorrect length added to it.
  104. 1.0.0 (2015-04-12)
  105. ------------------
  106. - Initial extraction from `hyper`_.
  107. .. _hyper: http://hyper.readthedocs.org/