Skip to content

[proposal] Rename rust-to-python exports to be cleaner, normalize exception names#2663

Closed
timkpaine wants to merge 2 commits intomasterfrom
tkp/newapichanges
Closed

[proposal] Rename rust-to-python exports to be cleaner, normalize exception names#2663
timkpaine wants to merge 2 commits intomasterfrom
tkp/newapichanges

Conversation

@timkpaine
Copy link
Copy Markdown
Member

@timkpaine timkpaine commented Jul 5, 2024

I think PySyncClient et al are a bit weird in python land, so I propose normalizing on:

  • Client/Table/etc for synchronous
  • ClientAsync / TableAsync/etc for asynchronous
    This is pretty trivial to do it seems, so little downside

Separately, I propose using the following names:

  • PerspectiveError: Error in the C++/Rust perspective engine
  • PerspectivePythonError: error in just the python slice of the codebase

Ideally these should inherit from a common base class (maybe PerspectivePythonError can inherit from PerspectiveError, but it would be nice to very clearly disambiguate engine errors from python land errors (e.g. web server or other utilities' errors)

Signed-off-by: Tim Paine <3105306+timkpaine@users.noreply.github.com>
@timkpaine timkpaine changed the title Rename rust-to-python exports to be cleaner [proposal] Rename rust-to-python exports to be cleaner Jul 5, 2024
@timkpaine timkpaine changed the title [proposal] Rename rust-to-python exports to be cleaner [proposal] Rename rust-to-python exports to be cleaner, normalize exception names Jul 5, 2024
@timkpaine timkpaine requested a review from texodus July 5, 2024 16:36
…more sense and follow scheme

Signed-off-by: Tim Paine <3105306+timkpaine@users.noreply.github.com>
@timkpaine timkpaine marked this pull request as ready for review July 8, 2024 13:49
@texodus
Copy link
Copy Markdown
Member

texodus commented Jul 15, 2024

This has been subsumed by #2659

@texodus texodus closed this Jul 15, 2024
@timkpaine timkpaine deleted the tkp/newapichanges branch July 15, 2024 12:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants