Hello list,

personally, I started with Colander + Deform, then had to patch Deform to
work with Bootstrap 4, then switched to "schema" (no-frills but nice) for
the back-end, and JS stuff ("yup") for the front-end. And then Pydantic. I
love Pydantic, in my opinion it's THE way to go. The developer of FastAPI
and Typer relies heavily on it (maybe too heavily sometimes? ;)) but I can
understand why (and I love Typer - or, rather, I love "rich").

Pydantic is also what allows FastAPI to auto-generate a Swagger page. I
would love to have the same in Pyramid. We would probably need to add
schema validation to both the input and output of Pyramid views.

As for Cornice, I don't remember why I chose to use it over plain JSON
routes, but there was a reason. Still, I'm probably only using 5% of its
features, the rest is not useful for me.

Laurent.


Le ven. 4 oct. 2024 à 15:59, Mikko Ohtamaa <mi...@redinnovation.com> a
écrit :

> Hi,
>
> On Fri, 4 Oct 2024 at 15:18, Sergey Maranchuk <slav0n...@gmail.com> wrote:
>
>> Cornice is in `maintenance mode` now and not recommended for new projects.
>> https://github.com/Pylons/trypyramid.com/pull/388
>>
>> пятница, 4 октября 2024 г. в 15:51:46 UTC+3, Thierry Florac:
>>
>>> Hi Mikko,
>>> I use colander, cornice and cornice-swagger packages with Pyramid.
>>> They allow schema verification and validation, and OpenAPI specification
>>> generation...
>>>
>>
> I appreciate your recommendations. I did some Colander maintenance a
> decade ago. Let's not speak about those dark times. Even if it is not a
> perfect solution to every problem, I feel Pydantic could be a good future
> solution as it has a vibrant community and is not too opinionated.
>
> At least it is not Django.
>
> Br,
> Mikko
>
>
>>
>>> Best regards,
>>> Thierry
>>> --
>>>   https://www.ulthar.net -- http://pyams.readthedocs.io
>>>
>>> Le ven. 4 oct. 2024 à 09:58, Mikko Ohtamaa <mi...@redinnovation.com> a
>>> écrit :
>>>
>>>>
>>>>
>>>>> On the minus side, the dependency injection system seemed far from
>>>>> clear to me. But the two biggest problems, for my needs, were:
>>>>>
>>>>> - FastAPI doesn't offer rich security policies (the security system in
>>>>> Pyramid is based on Zope's, with roles, permissions, ACLs, route 
>>>>> factories,
>>>>> contexts, etc.). Itonly offers "Oauth2 scopes", which can represent global
>>>>> permissions. So, no contextual permissions, workflows, etc, at least not
>>>>> with a substantial amount of work.
>>>>>
>>>>> - FastAPI doesn't seem to allow application composition the way
>>>>> Pyramid does (the exact term in the Pyramid docs is "extending an
>>>>> application")
>>>>>
>>>>
>>>> Would it be possible to mix the best parts of FastAPI and Pyramid?
>>>>
>>>> - FastAPI for schema generation and validation
>>>> - Pyramid as a web server and routing
>>>>
>>>> As pointed our earlier, FastAPI uses Starlette web server. Would we be
>>>> able to replace Starlette with Pyramid?
>>>>
>>>> Or more generally:
>>>>
>>>> Do we have any OpenAPI specification (YAML, JSON) generation tools from
>>>> Pyramid endpoints? (As discussed earlier, we have the opposite, manually
>>>> writing YAML and then importing it through pyramid_openapi3).
>>>>
>>>> Br,
>>>> Mikko
>>>>
>>>> --
>>>>
>>> You received this message because you are subscribed to the Google
>>>> Groups "pylons-discuss" group.
>>>> To unsubscribe from this group and stop receiving emails from it, send
>>>> an email to pylons-discus...@googlegroups.com.
>>>>
>>> To view this discussion on the web visit
>>>> https://groups.google.com/d/msgid/pylons-discuss/CAK8RCUtrjtxH3dneehNu9mQzz28s4G3g1gMvu1iC1ziFrR6afg%40mail.gmail.com
>>>> <https://groups.google.com/d/msgid/pylons-discuss/CAK8RCUtrjtxH3dneehNu9mQzz28s4G3g1gMvu1iC1ziFrR6afg%40mail.gmail.com?utm_medium=email&utm_source=footer>
>>>> .
>>>>
>>> --
>> You received this message because you are subscribed to the Google Groups
>> "pylons-discuss" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to pylons-discuss+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/pylons-discuss/6265acb6-f16b-4a8a-9de9-c577f2b1354dn%40googlegroups.com
>> <https://groups.google.com/d/msgid/pylons-discuss/6265acb6-f16b-4a8a-9de9-c577f2b1354dn%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
> --
> You received this message because you are subscribed to the Google Groups
> "pylons-discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to pylons-discuss+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/pylons-discuss/CAK8RCUuETnH2QdqG73oqSLQo7WJGdmR4%2BCHPpot%3DAvZ4m4YtrA%40mail.gmail.com
> <https://groups.google.com/d/msgid/pylons-discuss/CAK8RCUuETnH2QdqG73oqSLQo7WJGdmR4%2BCHPpot%3DAvZ4m4YtrA%40mail.gmail.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"pylons-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to pylons-discuss+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/pylons-discuss/CAB7cU6ydDuWBvKwPdvsLZys%3DYyBNW1n2OWu9gEd418N3hAfY2Q%40mail.gmail.com.

Reply via email to