Skip to content

Conversation

@andrii-balitskyi
Copy link
Contributor

@andrii-balitskyi andrii-balitskyi commented May 10, 2024

  • Remove routes and related types from top seam dir level
  • Bump generator to 1.11.0 and modify generate script to only include routes dir

@razor-x
Copy link
Member

razor-x commented May 14, 2024

Can you update https://github.com/seamapi/python-next/blob/main/.gitattributes so the diff shows the "no longer generated" files?

Comment on lines +1 to +2
from seam.types import AbstractSeam as Seam
from seam.routes.types import AbstractAccessCodes, AccessCode
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
from seam.types import AbstractSeam as Seam
from seam.routes.types import AbstractAccessCodes, AccessCode
from ..types import AbstractSeam as Seam
from .types import AbstractAccessCodes, AccessCode

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Relevant issue #54

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why a relative import ..types is better than an absolute seam.types? As for me, absolute imports from top level looks clearer.

SeamActionAttemptTimeoutError,
)

class SeamActionAttemptError(Exception):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we move the errors and special methods out of codegen? We can address this separately from this PR.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are there any other places in the codegen that are "special" like this, i.e., include code or special logic specific to a generated file?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think its only action attempts with their custom errors and polling methods.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Relevant issue #55

@razor-x
Copy link
Member

razor-x commented May 15, 2024

Ok to merge this and address the comments later, I know there are other PRs waiting on this. I just wanted to note anything I noticed while reviewing. I don't see any blockers and isolating the codegen to routes means contributing from this repo is unlocked!

andrii-balitskyi and others added 3 commits May 16, 2024 16:40
Co-authored-by: Evan Sosenko <evan@getseam.com>
Co-authored-by: Evan Sosenko <evan@getseam.com>
Co-authored-by: Evan Sosenko <evan@getseam.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants