docs: drop flytekit references from public docstrings; fix a flytekit import - #1633
Merged
Merged
Conversation
… import Seven docstrings on public classes still described flytekit's type engine, and the API reference publishes them verbatim (flyte.io.extend and flyte.types pages, plus every plugin encoder/decoder that inherits them). They now say Flyte. The Encoder docstring pointed back at itself for "the other way"; it now points at DataFrameDecoder. Also fixes the "enginer" typo and completes the dangling sentence in DataFrameTransformerEngine.register. PythonDependencyRenderer.to_html imported flytekit.loggers, so it raised ModuleNotFoundError wherever flytekit is not installed. It now uses flyte._logging. Adds tests for it. The asyn.py module docstring's example now imports run_sync from flyte. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Signed-off-by: Peeter Piegaze <1153481+ppiegaze@users.noreply.github.com>
Users see these when a dataclass, enum or dict conversion fails. The enum message also used backslash continuations inside the string, which put runs of spaces into the message; it is now one line. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Signed-off-by: Peeter Piegaze <1153481+ppiegaze@users.noreply.github.com>
fiedlerNr9
approved these changes
Oct 1, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Seven docstrings on public classes still described flytekit. The API reference publishes them verbatim, so the wording shows up on about 20 pages:
flyte.io.extend.DataFrameEncoder/DataFrameDecoder/DataFrameTransformerEngine,flyte.types.TypeEngine/TypeTransformer/FlytePickle, and every plugin encoder/decoder that inherits the base docstring (BigQuery, Polars, Spark). TheTypeEngine,TypeTransformerandFlytePicklephrases are also those pages' one-line summaries, so they appear in index tables and search results.DataFrameEncodersaid "for the other way, see the DataFrameEncoder"; it now points atDataFrameDecoderDataFrameTransformerEngine.registerended mid-sentence ("…field, then"); it now says an unspecified protocol registers the handler for every protocol, which is what the code doesBug fix
PythonDependencyRenderer.to_html()importedflytekit.loggers, so it raisedModuleNotFoundError: No module named 'flytekit'wherever flytekit isn't installed (reproduced onmain). It now usesflyte._logging. New tests intests/flyte/types/test_renderer.pycover the success and pip-failure paths; both fail onmainand pass here.The private
flyte._utils.asynmodule docstring's example now importsrun_syncfrom flyte.Error messages
Four user-facing error messages in
_type_engine.pysaid "Flytekit" (dataclass encode/decode, enum annotations, dict implicit conversion); they now say "Flyte". No test matches on this text. The enum message also used backslash continuations inside the string, which put runs of spaces into the message; it is now one line.Not changed
Comments and links to flytekit PRs that explain history are left alone.
Checks
pytest tests/flyte/types tests/flyte/type_engine tests/user_api(1301 passed),make check-docstrings,ruff format --check,ruff check,codespell.🤖 Generated with Claude Code