On 2026-02-17 07:39, Dietmar Maurer wrote:
>> I was wondering if we actually need/want a separate crate. This
>> could be part of `pve-api-types`, alongside the verifiers we'd also have
>> something like `external types` that the generator can use if specified
>> for specific endpoints. The rational here would be, that for endpoint
>> where we want more than just verifiers we could define the types
>> directly. This would also make it somewhat straightforward to introduce
>> concrete typing in other, unrelated, places where that would make sense.
>>
>> On the other hand, for re-usability without the general pve stuff having
>> a crate might be handy.
> 
> If you start implementing the firewall in Rust, you probably won't want
> to import
> all types from pve-api-types — that's unnecessary...
> 

yes. We actually do something very similar with `proxmox-apt-api-types`,
but also there it would be cool if we could tell the generator to use
the existing types in `proxmox-apt-api-types` instead of generating[1]
basically the same as we have in the crate[2]

[1]
https://git.proxmox.com/?p=proxmox.git;a=blob;f=pve-api-types/src/generated/types.rs;h=d0d39b5936585adb68d58d9d5eabe68c41e6b353;hb=refs/heads/master#l39

[2]
https://git.proxmox.com/?p=proxmox.git;a=blob;f=proxmox-apt-api-types/src/lib.rs;h=d3f5b3ebf5cba36461df16ba6da7e88b69b3c148;hb=refs/heads/master#l315

> - Dietmar
> 




Reply via email to