Server Test Python

Server Test Python

rev. aa5c29a987f7f91566c4691a6049ccdb8d69ba9a

Files changed:

tmp-codegen-diff/codegen-server-test-python/rest_json/rust-server-codegen-python/python/rest_json/model/__init__.pyi

@@ -46,46 +117,117 @@
   66     66   
    zero_double: float
   67     67   
   68     68   
    zero_float: float
   69     69   
   70     70   
    zero_integer: int
   71     71   
   72     72   
    zero_long: int
   73     73   
   74     74   
    zero_short: int
   75     75   
   76         -
    def __init__(self, default_string: str, default_boolean: bool, default_list: typing.List[str], default_document_map: rest_json.types.Document, default_document_string: rest_json.types.Document, default_document_boolean: rest_json.types.Document, default_document_list: rest_json.types.Document, default_null_document: typing.Optional[rest_json.types.Document] = ..., default_timestamp: rest_json.types.DateTime, default_blob: rest_json.types.Blob, default_byte: int, default_short: int, default_integer: int, default_long: int, default_float: float, default_double: float, default_map: typing.Dict[str, str], default_enum: rest_json.model.TestEnum, default_int_enum: int, empty_string: str, false_boolean: bool, empty_blob: rest_json.types.Blob, zero_byte: int, zero_short: int, zero_integer: int, zero_long: int, zero_float: float, zero_double: float) -> None:
          76  +
    def __init__(self, default_string: str, default_boolean: bool, default_list: typing.List[str], default_document_map: rest_json.types.Document, default_document_string: rest_json.types.Document, default_document_boolean: rest_json.types.Document, default_document_list: rest_json.types.Document, default_timestamp: rest_json.types.DateTime, default_blob: rest_json.types.Blob, default_byte: int, default_short: int, default_integer: int, default_long: int, default_float: float, default_double: float, default_map: typing.Dict[str, str], default_enum: rest_json.model.TestEnum, default_int_enum: int, empty_string: str, false_boolean: bool, empty_blob: rest_json.types.Blob, zero_byte: int, zero_short: int, zero_integer: int, zero_long: int, zero_float: float, zero_double: float, default_null_document: typing.Optional[rest_json.types.Document] = ...) -> None:
   77     77   
        ...
   78     78   
   79     79   
   80     80   
class Dialog:
   81     81   
    farewell: typing.Optional[rest_json.model.Farewell]
   82     82   
   83     83   
    greeting: str
   84     84   
   85     85   
    language: typing.Optional[str]
   86     86   
   87         -
    def __init__(self, language: typing.Optional[str] = ..., greeting: str, farewell: typing.Optional[rest_json.model.Farewell] = ...) -> None:
          87  +
    def __init__(self, greeting: str, language: typing.Optional[str] = ..., farewell: typing.Optional[rest_json.model.Farewell] = ...) -> None:
   88     88   
        ...
   89     89   
   90     90   
   91     91   
class Farewell:
   92     92   
    phrase: str
   93     93   
   94     94   
    def __init__(self, phrase: str) -> None:
   95     95   
        ...
   96     96   
   97     97   

tmp-codegen-diff/codegen-server-test-python/rest_json/rust-server-codegen-python/python/rest_json/output/__init__.pyi

@@ -595,595 +655,655 @@
  615    615   
    zero_double: float
  616    616   
  617    617   
    zero_float: float
  618    618   
  619    619   
    zero_integer: int
  620    620   
  621    621   
    zero_long: int
  622    622   
  623    623   
    zero_short: int
  624    624   
  625         -
    def __init__(self, default_string: str, default_boolean: bool, default_list: typing.List[str], default_document_map: rest_json.types.Document, default_document_string: rest_json.types.Document, default_document_boolean: rest_json.types.Document, default_document_list: rest_json.types.Document, default_null_document: typing.Optional[rest_json.types.Document] = ..., default_timestamp: rest_json.types.DateTime, default_blob: rest_json.types.Blob, default_byte: int, default_short: int, default_integer: int, default_long: int, default_float: float, default_double: float, default_map: typing.Dict[str, str], default_enum: rest_json.model.TestEnum, default_int_enum: int, empty_string: str, false_boolean: bool, empty_blob: rest_json.types.Blob, zero_byte: int, zero_short: int, zero_integer: int, zero_long: int, zero_float: float, zero_double: float) -> None:
         625  +
    def __init__(self, default_string: str, default_boolean: bool, default_list: typing.List[str], default_document_map: rest_json.types.Document, default_document_string: rest_json.types.Document, default_document_boolean: rest_json.types.Document, default_document_list: rest_json.types.Document, default_timestamp: rest_json.types.DateTime, default_blob: rest_json.types.Blob, default_byte: int, default_short: int, default_integer: int, default_long: int, default_float: float, default_double: float, default_map: typing.Dict[str, str], default_enum: rest_json.model.TestEnum, default_int_enum: int, empty_string: str, false_boolean: bool, empty_blob: rest_json.types.Blob, zero_byte: int, zero_short: int, zero_integer: int, zero_long: int, zero_float: float, zero_double: float, default_null_document: typing.Optional[rest_json.types.Document] = ...) -> None:
  626    626   
        ...
  627    627   
  628    628   
  629    629   
class OperationWithNestedStructureOutput:
  630    630   
    dialog: rest_json.model.Dialog
  631    631   
  632    632   
    dialog_list: typing.List[rest_json.model.Dialog]
  633    633   
  634    634   
    dialog_map: typing.Dict[str, rest_json.model.Dialog]
  635    635   
@@ -705,705 +779,779 @@
  725    725   
  726    726   
    def __init__(self, sparse_struct_map: typing.Optional[typing.Dict[str, typing.Optional[rest_json.model.GreetingStruct]]] = ..., sparse_number_map: typing.Optional[typing.Dict[str, typing.Optional[int]]] = ..., sparse_boolean_map: typing.Optional[typing.Dict[str, typing.Optional[bool]]] = ..., sparse_string_map: typing.Optional[typing.Dict[str, typing.Optional[str]]] = ..., sparse_set_map: typing.Optional[typing.Dict[str, typing.Optional[typing.List[str]]]] = ...) -> None:
  727    727   
        ...
  728    728   
  729    729   
  730    730   
class StreamingTraitsOutput:
  731    731   
    blob: rest_json.types.ByteStream
  732    732   
  733    733   
    foo: typing.Optional[str]
  734    734   
  735         -
    def __init__(self, foo: typing.Optional[str] = ..., blob: rest_json.types.ByteStream) -> None:
         735  +
    def __init__(self, blob: rest_json.types.ByteStream, foo: typing.Optional[str] = ...) -> None:
  736    736   
        ...
  737    737   
  738    738   
  739    739   
class StreamingTraitsRequireLengthOutput:
  740    740   
    def __init__(self) -> None:
  741    741   
        ...
  742    742   
  743    743   
  744    744   
class StreamingTraitsWithMediaTypeOutput:
  745    745   
    blob: rest_json.types.ByteStream
  746    746   
  747    747   
    foo: typing.Optional[str]
  748    748   
  749         -
    def __init__(self, foo: typing.Optional[str] = ..., blob: rest_json.types.ByteStream) -> None:
         749  +
    def __init__(self, blob: rest_json.types.ByteStream, foo: typing.Optional[str] = ...) -> None:
  750    750   
        ...
  751    751   
  752    752   
  753    753   
class TestBodyStructureOutput:
  754    754   
    test_config: typing.Optional[rest_json.model.TestConfig]
  755    755   
  756    756   
    test_id: typing.Optional[str]
  757    757   
  758    758   
    def __init__(self, test_id: typing.Optional[str] = ..., test_config: typing.Optional[rest_json.model.TestConfig] = ...) -> None:
  759    759   
        ...

tmp-codegen-diff/codegen-server-test-python/rest_json/rust-server-codegen-python/src/input.rs

@@ -27,27 +148,148 @@
   47     47   
    type Unconstrained = crate::input::operation_with_nested_structure_input_internal::Builder;
   48     48   
}
   49     49   
impl OperationWithNestedStructureInput {
   50     50   
    /// Creates a new builder-style object to manufacture [`OperationWithNestedStructureInput`](crate::input::OperationWithNestedStructureInput).
   51     51   
    pub fn builder() -> crate::input::operation_with_nested_structure_input::Builder {
   52     52   
        crate::input::operation_with_nested_structure_input::Builder::default()
   53     53   
    }
   54     54   
}
   55     55   
   56     56   
#[::pyo3::pyclass]
   57         -
/// :param defaults typing.Optional\[rest_json.model.Defaults\]:
   58         -
/// :param client_optional_defaults typing.Optional\[rest_json.model.ClientOptionalDefaults\]:
   59     57   
/// :param top_level_default str:
   60     58   
/// :param other_top_level_default int:
          59  +
/// :param defaults typing.Optional\[rest_json.model.Defaults\]:
          60  +
/// :param client_optional_defaults typing.Optional\[rest_json.model.ClientOptionalDefaults\]:
   61     61   
/// :rtype None:
   62     62   
#[allow(missing_docs)] // documentation missing in model
   63     63   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
   64     64   
pub struct OperationWithDefaultsInput {
   65     65   
    #[pyo3(get, set)]
   66     66   
    /// :type typing.Optional\[rest_json.model.Defaults\]:
   67     67   
    #[allow(missing_docs)] // documentation missing in model
   68     68   
    pub defaults: ::std::option::Option<crate::model::Defaults>,
   69     69   
    #[pyo3(get, set)]
   70     70   
    /// :type typing.Optional\[rest_json.model.ClientOptionalDefaults\]:
   71     71   
    #[allow(missing_docs)] // documentation missing in model
   72     72   
    pub client_optional_defaults: ::std::option::Option<crate::model::ClientOptionalDefaults>,
   73     73   
    #[pyo3(get, set)]
   74     74   
    /// :type str:
   75     75   
    #[allow(missing_docs)] // documentation missing in model
   76     76   
    pub top_level_default: ::std::string::String,
   77     77   
    #[pyo3(get, set)]
   78     78   
    /// :type int:
   79     79   
    #[allow(missing_docs)] // documentation missing in model
   80     80   
    pub other_top_level_default: i32,
   81     81   
}
   82     82   
impl OperationWithDefaultsInput {
   83     83   
    #[allow(missing_docs)] // documentation missing in model
   84     84   
    pub fn defaults(&self) -> ::std::option::Option<&crate::model::Defaults> {
   85     85   
        self.defaults.as_ref()
   86     86   
    }
   87     87   
    #[allow(missing_docs)] // documentation missing in model
   88     88   
    pub fn client_optional_defaults(
   89     89   
        &self,
   90     90   
    ) -> ::std::option::Option<&crate::model::ClientOptionalDefaults> {
   91     91   
        self.client_optional_defaults.as_ref()
   92     92   
    }
   93     93   
    #[allow(missing_docs)] // documentation missing in model
   94     94   
    pub fn top_level_default(&self) -> &str {
   95     95   
        use std::ops::Deref;
   96     96   
        self.top_level_default.deref()
   97     97   
    }
   98     98   
    #[allow(missing_docs)] // documentation missing in model
   99     99   
    pub fn other_top_level_default(&self) -> i32 {
  100    100   
        self.other_top_level_default
  101    101   
    }
  102    102   
}
  103    103   
#[allow(clippy::new_without_default)]
  104    104   
#[allow(clippy::too_many_arguments)]
  105    105   
#[::pyo3::pymethods]
  106    106   
impl OperationWithDefaultsInput {
  107    107   
    #[new]
  108    108   
    pub fn new(
  109         -
        defaults: ::std::option::Option<crate::model::Defaults>,
  110         -
        client_optional_defaults: ::std::option::Option<crate::model::ClientOptionalDefaults>,
  111    109   
        top_level_default: ::std::string::String,
  112    110   
        other_top_level_default: i32,
         111  +
        defaults: ::std::option::Option<crate::model::Defaults>,
         112  +
        client_optional_defaults: ::std::option::Option<crate::model::ClientOptionalDefaults>,
  113    113   
    ) -> Self {
  114    114   
        Self {
  115         -
            defaults,
  116         -
            client_optional_defaults,
  117    115   
            top_level_default,
  118    116   
            other_top_level_default,
         117  +
            defaults,
         118  +
            client_optional_defaults,
  119    119   
        }
  120    120   
    }
  121    121   
    fn __repr__(&self) -> String {
  122    122   
        format!("{self:?}")
  123    123   
    }
  124    124   
    fn __str__(&self) -> String {
  125    125   
        format!("{self:?}")
  126    126   
    }
  127    127   
}
  128    128   
impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<OperationWithDefaultsInput> {
@@ -1834,1834 +2316,2316 @@
 1854   1854   
    type Unconstrained = crate::input::malformed_string_input_internal::Builder;
 1855   1855   
}
 1856   1856   
impl MalformedStringInput {
 1857   1857   
    /// Creates a new builder-style object to manufacture [`MalformedStringInput`](crate::input::MalformedStringInput).
 1858   1858   
    pub fn builder() -> crate::input::malformed_string_input::Builder {
 1859   1859   
        crate::input::malformed_string_input::Builder::default()
 1860   1860   
    }
 1861   1861   
}
 1862   1862   
 1863   1863   
#[::pyo3::pyclass]
 1864         -
/// :param double_in_body typing.Optional\[float\]:
 1865   1864   
/// :param double_in_path float:
        1865  +
/// :param double_in_body typing.Optional\[float\]:
 1866   1866   
/// :param double_in_query typing.Optional\[float\]:
 1867   1867   
/// :param double_in_header typing.Optional\[float\]:
 1868   1868   
/// :rtype None:
 1869   1869   
#[allow(missing_docs)] // documentation missing in model
 1870   1870   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
 1871   1871   
pub struct MalformedDoubleInput {
 1872   1872   
    #[pyo3(get, set)]
 1873   1873   
    /// :type typing.Optional\[float\]:
 1874   1874   
    #[allow(missing_docs)] // documentation missing in model
 1875   1875   
    pub double_in_body: ::std::option::Option<f64>,
 1876   1876   
    #[pyo3(get, set)]
 1877   1877   
    /// :type float:
 1878   1878   
    #[allow(missing_docs)] // documentation missing in model
 1879   1879   
    pub double_in_path: f64,
 1880   1880   
    #[pyo3(get, set)]
 1881   1881   
    /// :type typing.Optional\[float\]:
 1882   1882   
    #[allow(missing_docs)] // documentation missing in model
 1883   1883   
    pub double_in_query: ::std::option::Option<f64>,
 1884   1884   
    #[pyo3(get, set)]
 1885   1885   
    /// :type typing.Optional\[float\]:
 1886   1886   
    #[allow(missing_docs)] // documentation missing in model
 1887   1887   
    pub double_in_header: ::std::option::Option<f64>,
 1888   1888   
}
 1889   1889   
impl MalformedDoubleInput {
 1890   1890   
    #[allow(missing_docs)] // documentation missing in model
 1891   1891   
    pub fn double_in_body(&self) -> ::std::option::Option<f64> {
 1892   1892   
        self.double_in_body
 1893   1893   
    }
 1894   1894   
    #[allow(missing_docs)] // documentation missing in model
 1895   1895   
    pub fn double_in_path(&self) -> f64 {
 1896   1896   
        self.double_in_path
 1897   1897   
    }
 1898   1898   
    #[allow(missing_docs)] // documentation missing in model
 1899   1899   
    pub fn double_in_query(&self) -> ::std::option::Option<f64> {
 1900   1900   
        self.double_in_query
 1901   1901   
    }
 1902   1902   
    #[allow(missing_docs)] // documentation missing in model
 1903   1903   
    pub fn double_in_header(&self) -> ::std::option::Option<f64> {
 1904   1904   
        self.double_in_header
 1905   1905   
    }
 1906   1906   
}
 1907   1907   
#[allow(clippy::new_without_default)]
 1908   1908   
#[allow(clippy::too_many_arguments)]
 1909   1909   
#[::pyo3::pymethods]
 1910   1910   
impl MalformedDoubleInput {
 1911   1911   
    #[new]
 1912   1912   
    pub fn new(
 1913         -
        double_in_body: ::std::option::Option<f64>,
 1914   1913   
        double_in_path: f64,
        1914  +
        double_in_body: ::std::option::Option<f64>,
 1915   1915   
        double_in_query: ::std::option::Option<f64>,
 1916   1916   
        double_in_header: ::std::option::Option<f64>,
 1917   1917   
    ) -> Self {
 1918   1918   
        Self {
 1919         -
            double_in_body,
 1920   1919   
            double_in_path,
        1920  +
            double_in_body,
 1921   1921   
            double_in_query,
 1922   1922   
            double_in_header,
 1923   1923   
        }
 1924   1924   
    }
 1925   1925   
    fn __repr__(&self) -> String {
 1926   1926   
        format!("{self:?}")
 1927   1927   
    }
 1928   1928   
    fn __str__(&self) -> String {
 1929   1929   
        format!("{self:?}")
 1930   1930   
    }
 1931   1931   
}
 1932   1932   
impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<MalformedDoubleInput> {
 1933   1933   
    fn extract(ob: &'source ::pyo3::PyAny) -> ::pyo3::PyResult<Self> {
 1934   1934   
        ob.extract::<MalformedDoubleInput>().map(Box::new)
 1935   1935   
    }
 1936   1936   
}
 1937   1937   
 1938   1938   
impl ::pyo3::IntoPy<::pyo3::PyObject> for std::boxed::Box<MalformedDoubleInput> {
 1939   1939   
    fn into_py(self, py: ::pyo3::Python<'_>) -> ::pyo3::PyObject {
 1940   1940   
        (*self).into_py(py)
 1941   1941   
    }
 1942   1942   
}
 1943   1943   
impl crate::constrained::Constrained for crate::input::MalformedDoubleInput {
 1944   1944   
    type Unconstrained = crate::input::malformed_double_input_internal::Builder;
 1945   1945   
}
 1946   1946   
impl MalformedDoubleInput {
 1947   1947   
    /// Creates a new builder-style object to manufacture [`MalformedDoubleInput`](crate::input::MalformedDoubleInput).
 1948   1948   
    pub fn builder() -> crate::input::malformed_double_input::Builder {
 1949   1949   
        crate::input::malformed_double_input::Builder::default()
 1950   1950   
    }
 1951   1951   
}
 1952   1952   
 1953   1953   
#[::pyo3::pyclass]
 1954         -
/// :param float_in_body typing.Optional\[float\]:
 1955   1954   
/// :param float_in_path float:
        1955  +
/// :param float_in_body typing.Optional\[float\]:
 1956   1956   
/// :param float_in_query typing.Optional\[float\]:
 1957   1957   
/// :param float_in_header typing.Optional\[float\]:
 1958   1958   
/// :rtype None:
 1959   1959   
#[allow(missing_docs)] // documentation missing in model
 1960   1960   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
 1961   1961   
pub struct MalformedFloatInput {
 1962   1962   
    #[pyo3(get, set)]
 1963   1963   
    /// :type typing.Optional\[float\]:
 1964   1964   
    #[allow(missing_docs)] // documentation missing in model
 1965   1965   
    pub float_in_body: ::std::option::Option<f32>,
 1966   1966   
    #[pyo3(get, set)]
 1967   1967   
    /// :type float:
 1968   1968   
    #[allow(missing_docs)] // documentation missing in model
 1969   1969   
    pub float_in_path: f32,
 1970   1970   
    #[pyo3(get, set)]
 1971   1971   
    /// :type typing.Optional\[float\]:
 1972   1972   
    #[allow(missing_docs)] // documentation missing in model
 1973   1973   
    pub float_in_query: ::std::option::Option<f32>,
 1974   1974   
    #[pyo3(get, set)]
 1975   1975   
    /// :type typing.Optional\[float\]:
 1976   1976   
    #[allow(missing_docs)] // documentation missing in model
 1977   1977   
    pub float_in_header: ::std::option::Option<f32>,
 1978   1978   
}
 1979   1979   
impl MalformedFloatInput {
 1980   1980   
    #[allow(missing_docs)] // documentation missing in model
 1981   1981   
    pub fn float_in_body(&self) -> ::std::option::Option<f32> {
 1982   1982   
        self.float_in_body
 1983   1983   
    }
 1984   1984   
    #[allow(missing_docs)] // documentation missing in model
 1985   1985   
    pub fn float_in_path(&self) -> f32 {
 1986   1986   
        self.float_in_path
 1987   1987   
    }
 1988   1988   
    #[allow(missing_docs)] // documentation missing in model
 1989   1989   
    pub fn float_in_query(&self) -> ::std::option::Option<f32> {
 1990   1990   
        self.float_in_query
 1991   1991   
    }
 1992   1992   
    #[allow(missing_docs)] // documentation missing in model
 1993   1993   
    pub fn float_in_header(&self) -> ::std::option::Option<f32> {
 1994   1994   
        self.float_in_header
 1995   1995   
    }
 1996   1996   
}
 1997   1997   
#[allow(clippy::new_without_default)]
 1998   1998   
#[allow(clippy::too_many_arguments)]
 1999   1999   
#[::pyo3::pymethods]
 2000   2000   
impl MalformedFloatInput {
 2001   2001   
    #[new]
 2002   2002   
    pub fn new(
 2003         -
        float_in_body: ::std::option::Option<f32>,
 2004   2003   
        float_in_path: f32,
        2004  +
        float_in_body: ::std::option::Option<f32>,
 2005   2005   
        float_in_query: ::std::option::Option<f32>,
 2006   2006   
        float_in_header: ::std::option::Option<f32>,
 2007   2007   
    ) -> Self {
 2008   2008   
        Self {
 2009         -
            float_in_body,
 2010   2009   
            float_in_path,
        2010  +
            float_in_body,
 2011   2011   
            float_in_query,
 2012   2012   
            float_in_header,
 2013   2013   
        }
 2014   2014   
    }
 2015   2015   
    fn __repr__(&self) -> String {
 2016   2016   
        format!("{self:?}")
 2017   2017   
    }
 2018   2018   
    fn __str__(&self) -> String {
 2019   2019   
        format!("{self:?}")
 2020   2020   
    }
 2021   2021   
}
 2022   2022   
impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<MalformedFloatInput> {
 2023   2023   
    fn extract(ob: &'source ::pyo3::PyAny) -> ::pyo3::PyResult<Self> {
 2024   2024   
        ob.extract::<MalformedFloatInput>().map(Box::new)
 2025   2025   
    }
 2026   2026   
}
 2027   2027   
 2028   2028   
impl ::pyo3::IntoPy<::pyo3::PyObject> for std::boxed::Box<MalformedFloatInput> {
 2029   2029   
    fn into_py(self, py: ::pyo3::Python<'_>) -> ::pyo3::PyObject {
 2030   2030   
        (*self).into_py(py)
 2031   2031   
    }
 2032   2032   
}
 2033   2033   
impl crate::constrained::Constrained for crate::input::MalformedFloatInput {
 2034   2034   
    type Unconstrained = crate::input::malformed_float_input_internal::Builder;
 2035   2035   
}
 2036   2036   
impl MalformedFloatInput {
 2037   2037   
    /// Creates a new builder-style object to manufacture [`MalformedFloatInput`](crate::input::MalformedFloatInput).
 2038   2038   
    pub fn builder() -> crate::input::malformed_float_input::Builder {
 2039   2039   
        crate::input::malformed_float_input::Builder::default()
 2040   2040   
    }
 2041   2041   
}
 2042   2042   
 2043   2043   
#[::pyo3::pyclass]
 2044         -
/// :param long_in_body typing.Optional\[int\]:
 2045   2044   
/// :param long_in_path int:
        2045  +
/// :param long_in_body typing.Optional\[int\]:
 2046   2046   
/// :param long_in_query typing.Optional\[int\]:
 2047   2047   
/// :param long_in_header typing.Optional\[int\]:
 2048   2048   
/// :rtype None:
 2049   2049   
#[allow(missing_docs)] // documentation missing in model
 2050   2050   
#[derive(
 2051   2051   
    ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
 2052   2052   
)]
 2053   2053   
pub struct MalformedLongInput {
 2054   2054   
    #[pyo3(get, set)]
 2055   2055   
    /// :type typing.Optional\[int\]:
 2056   2056   
    #[allow(missing_docs)] // documentation missing in model
 2057   2057   
    pub long_in_body: ::std::option::Option<i64>,
 2058   2058   
    #[pyo3(get, set)]
 2059   2059   
    /// :type int:
 2060   2060   
    #[allow(missing_docs)] // documentation missing in model
 2061   2061   
    pub long_in_path: i64,
 2062   2062   
    #[pyo3(get, set)]
 2063   2063   
    /// :type typing.Optional\[int\]:
 2064   2064   
    #[allow(missing_docs)] // documentation missing in model
 2065   2065   
    pub long_in_query: ::std::option::Option<i64>,
 2066   2066   
    #[pyo3(get, set)]
 2067   2067   
    /// :type typing.Optional\[int\]:
 2068   2068   
    #[allow(missing_docs)] // documentation missing in model
 2069   2069   
    pub long_in_header: ::std::option::Option<i64>,
 2070   2070   
}
 2071   2071   
impl MalformedLongInput {
 2072   2072   
    #[allow(missing_docs)] // documentation missing in model
 2073   2073   
    pub fn long_in_body(&self) -> ::std::option::Option<i64> {
 2074   2074   
        self.long_in_body
 2075   2075   
    }
 2076   2076   
    #[allow(missing_docs)] // documentation missing in model
 2077   2077   
    pub fn long_in_path(&self) -> i64 {
 2078   2078   
        self.long_in_path
 2079   2079   
    }
 2080   2080   
    #[allow(missing_docs)] // documentation missing in model
 2081   2081   
    pub fn long_in_query(&self) -> ::std::option::Option<i64> {
 2082   2082   
        self.long_in_query
 2083   2083   
    }
 2084   2084   
    #[allow(missing_docs)] // documentation missing in model
 2085   2085   
    pub fn long_in_header(&self) -> ::std::option::Option<i64> {
 2086   2086   
        self.long_in_header
 2087   2087   
    }
 2088   2088   
}
 2089   2089   
#[allow(clippy::new_without_default)]
 2090   2090   
#[allow(clippy::too_many_arguments)]
 2091   2091   
#[::pyo3::pymethods]
 2092   2092   
impl MalformedLongInput {
 2093   2093   
    #[new]
 2094   2094   
    pub fn new(
 2095         -
        long_in_body: ::std::option::Option<i64>,
 2096   2095   
        long_in_path: i64,
        2096  +
        long_in_body: ::std::option::Option<i64>,
 2097   2097   
        long_in_query: ::std::option::Option<i64>,
 2098   2098   
        long_in_header: ::std::option::Option<i64>,
 2099   2099   
    ) -> Self {
 2100   2100   
        Self {
 2101         -
            long_in_body,
 2102   2101   
            long_in_path,
        2102  +
            long_in_body,
 2103   2103   
            long_in_query,
 2104   2104   
            long_in_header,
 2105   2105   
        }
 2106   2106   
    }
 2107   2107   
    fn __repr__(&self) -> String {
 2108   2108   
        format!("{self:?}")
 2109   2109   
    }
 2110   2110   
    fn __str__(&self) -> String {
 2111   2111   
        format!("{self:?}")
 2112   2112   
    }
 2113   2113   
}
 2114   2114   
impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<MalformedLongInput> {
 2115   2115   
    fn extract(ob: &'source ::pyo3::PyAny) -> ::pyo3::PyResult<Self> {
 2116   2116   
        ob.extract::<MalformedLongInput>().map(Box::new)
 2117   2117   
    }
 2118   2118   
}
 2119   2119   
 2120   2120   
impl ::pyo3::IntoPy<::pyo3::PyObject> for std::boxed::Box<MalformedLongInput> {
 2121   2121   
    fn into_py(self, py: ::pyo3::Python<'_>) -> ::pyo3::PyObject {
 2122   2122   
        (*self).into_py(py)
 2123   2123   
    }
 2124   2124   
}
 2125   2125   
impl crate::constrained::Constrained for crate::input::MalformedLongInput {
 2126   2126   
    type Unconstrained = crate::input::malformed_long_input_internal::Builder;
 2127   2127   
}
 2128   2128   
impl MalformedLongInput {
 2129   2129   
    /// Creates a new builder-style object to manufacture [`MalformedLongInput`](crate::input::MalformedLongInput).
 2130   2130   
    pub fn builder() -> crate::input::malformed_long_input::Builder {
 2131   2131   
        crate::input::malformed_long_input::Builder::default()
 2132   2132   
    }
 2133   2133   
}
 2134   2134   
 2135   2135   
#[::pyo3::pyclass]
 2136         -
/// :param short_in_body typing.Optional\[int\]:
 2137   2136   
/// :param short_in_path int:
        2137  +
/// :param short_in_body typing.Optional\[int\]:
 2138   2138   
/// :param short_in_query typing.Optional\[int\]:
 2139   2139   
/// :param short_in_header typing.Optional\[int\]:
 2140   2140   
/// :rtype None:
 2141   2141   
#[allow(missing_docs)] // documentation missing in model
 2142   2142   
#[derive(
 2143   2143   
    ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
 2144   2144   
)]
 2145   2145   
pub struct MalformedShortInput {
 2146   2146   
    #[pyo3(get, set)]
 2147   2147   
    /// :type typing.Optional\[int\]:
 2148   2148   
    #[allow(missing_docs)] // documentation missing in model
 2149   2149   
    pub short_in_body: ::std::option::Option<i16>,
 2150   2150   
    #[pyo3(get, set)]
 2151   2151   
    /// :type int:
 2152   2152   
    #[allow(missing_docs)] // documentation missing in model
 2153   2153   
    pub short_in_path: i16,
 2154   2154   
    #[pyo3(get, set)]
 2155   2155   
    /// :type typing.Optional\[int\]:
 2156   2156   
    #[allow(missing_docs)] // documentation missing in model
 2157   2157   
    pub short_in_query: ::std::option::Option<i16>,
 2158   2158   
    #[pyo3(get, set)]
 2159   2159   
    /// :type typing.Optional\[int\]:
 2160   2160   
    #[allow(missing_docs)] // documentation missing in model
 2161   2161   
    pub short_in_header: ::std::option::Option<i16>,
 2162   2162   
}
 2163   2163   
impl MalformedShortInput {
 2164   2164   
    #[allow(missing_docs)] // documentation missing in model
 2165   2165   
    pub fn short_in_body(&self) -> ::std::option::Option<i16> {
 2166   2166   
        self.short_in_body
 2167   2167   
    }
 2168   2168   
    #[allow(missing_docs)] // documentation missing in model
 2169   2169   
    pub fn short_in_path(&self) -> i16 {
 2170   2170   
        self.short_in_path
 2171   2171   
    }
 2172   2172   
    #[allow(missing_docs)] // documentation missing in model
 2173   2173   
    pub fn short_in_query(&self) -> ::std::option::Option<i16> {
 2174   2174   
        self.short_in_query
 2175   2175   
    }
 2176   2176   
    #[allow(missing_docs)] // documentation missing in model
 2177   2177   
    pub fn short_in_header(&self) -> ::std::option::Option<i16> {
 2178   2178   
        self.short_in_header
 2179   2179   
    }
 2180   2180   
}
 2181   2181   
#[allow(clippy::new_without_default)]
 2182   2182   
#[allow(clippy::too_many_arguments)]
 2183   2183   
#[::pyo3::pymethods]
 2184   2184   
impl MalformedShortInput {
 2185   2185   
    #[new]
 2186   2186   
    pub fn new(
 2187         -
        short_in_body: ::std::option::Option<i16>,
 2188   2187   
        short_in_path: i16,
        2188  +
        short_in_body: ::std::option::Option<i16>,
 2189   2189   
        short_in_query: ::std::option::Option<i16>,
 2190   2190   
        short_in_header: ::std::option::Option<i16>,
 2191   2191   
    ) -> Self {
 2192   2192   
        Self {
 2193         -
            short_in_body,
 2194   2193   
            short_in_path,
        2194  +
            short_in_body,
 2195   2195   
            short_in_query,
 2196   2196   
            short_in_header,
 2197   2197   
        }
 2198   2198   
    }
 2199   2199   
    fn __repr__(&self) -> String {
 2200   2200   
        format!("{self:?}")
 2201   2201   
    }
 2202   2202   
    fn __str__(&self) -> String {
 2203   2203   
        format!("{self:?}")
 2204   2204   
    }
 2205   2205   
}
 2206   2206   
impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<MalformedShortInput> {
 2207   2207   
    fn extract(ob: &'source ::pyo3::PyAny) -> ::pyo3::PyResult<Self> {
 2208   2208   
        ob.extract::<MalformedShortInput>().map(Box::new)
 2209   2209   
    }
 2210   2210   
}
 2211   2211   
 2212   2212   
impl ::pyo3::IntoPy<::pyo3::PyObject> for std::boxed::Box<MalformedShortInput> {
 2213   2213   
    fn into_py(self, py: ::pyo3::Python<'_>) -> ::pyo3::PyObject {
 2214   2214   
        (*self).into_py(py)
 2215   2215   
    }
 2216   2216   
}
 2217   2217   
impl crate::constrained::Constrained for crate::input::MalformedShortInput {
 2218   2218   
    type Unconstrained = crate::input::malformed_short_input_internal::Builder;
 2219   2219   
}
 2220   2220   
impl MalformedShortInput {
 2221   2221   
    /// Creates a new builder-style object to manufacture [`MalformedShortInput`](crate::input::MalformedShortInput).
 2222   2222   
    pub fn builder() -> crate::input::malformed_short_input::Builder {
 2223   2223   
        crate::input::malformed_short_input::Builder::default()
 2224   2224   
    }
 2225   2225   
}
 2226   2226   
 2227   2227   
#[::pyo3::pyclass]
 2228         -
/// :param byte_in_body typing.Optional\[int\]:
 2229   2228   
/// :param byte_in_path int:
        2229  +
/// :param byte_in_body typing.Optional\[int\]:
 2230   2230   
/// :param byte_in_query typing.Optional\[int\]:
 2231   2231   
/// :param byte_in_header typing.Optional\[int\]:
 2232   2232   
/// :rtype None:
 2233   2233   
#[allow(missing_docs)] // documentation missing in model
 2234   2234   
#[derive(
 2235   2235   
    ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
 2236   2236   
)]
 2237   2237   
pub struct MalformedByteInput {
 2238   2238   
    #[pyo3(get, set)]
 2239   2239   
    /// :type typing.Optional\[int\]:
 2240   2240   
    #[allow(missing_docs)] // documentation missing in model
 2241   2241   
    pub byte_in_body: ::std::option::Option<i8>,
 2242   2242   
    #[pyo3(get, set)]
 2243   2243   
    /// :type int:
 2244   2244   
    #[allow(missing_docs)] // documentation missing in model
 2245   2245   
    pub byte_in_path: i8,
 2246   2246   
    #[pyo3(get, set)]
 2247   2247   
    /// :type typing.Optional\[int\]:
 2248   2248   
    #[allow(missing_docs)] // documentation missing in model
 2249   2249   
    pub byte_in_query: ::std::option::Option<i8>,
 2250   2250   
    #[pyo3(get, set)]
 2251   2251   
    /// :type typing.Optional\[int\]:
 2252   2252   
    #[allow(missing_docs)] // documentation missing in model
 2253   2253   
    pub byte_in_header: ::std::option::Option<i8>,
 2254   2254   
}
 2255   2255   
impl MalformedByteInput {
 2256   2256   
    #[allow(missing_docs)] // documentation missing in model
 2257   2257   
    pub fn byte_in_body(&self) -> ::std::option::Option<i8> {
 2258   2258   
        self.byte_in_body
 2259   2259   
    }
 2260   2260   
    #[allow(missing_docs)] // documentation missing in model
 2261   2261   
    pub fn byte_in_path(&self) -> i8 {
 2262   2262   
        self.byte_in_path
 2263   2263   
    }
 2264   2264   
    #[allow(missing_docs)] // documentation missing in model
 2265   2265   
    pub fn byte_in_query(&self) -> ::std::option::Option<i8> {
 2266   2266   
        self.byte_in_query
 2267   2267   
    }
 2268   2268   
    #[allow(missing_docs)] // documentation missing in model
 2269   2269   
    pub fn byte_in_header(&self) -> ::std::option::Option<i8> {
 2270   2270   
        self.byte_in_header
 2271   2271   
    }
 2272   2272   
}
 2273   2273   
#[allow(clippy::new_without_default)]
 2274   2274   
#[allow(clippy::too_many_arguments)]
 2275   2275   
#[::pyo3::pymethods]
 2276   2276   
impl MalformedByteInput {
 2277   2277   
    #[new]
 2278   2278   
    pub fn new(
 2279         -
        byte_in_body: ::std::option::Option<i8>,
 2280   2279   
        byte_in_path: i8,
        2280  +
        byte_in_body: ::std::option::Option<i8>,
 2281   2281   
        byte_in_query: ::std::option::Option<i8>,
 2282   2282   
        byte_in_header: ::std::option::Option<i8>,
 2283   2283   
    ) -> Self {
 2284   2284   
        Self {
 2285         -
            byte_in_body,
 2286   2285   
            byte_in_path,
        2286  +
            byte_in_body,
 2287   2287   
            byte_in_query,
 2288   2288   
            byte_in_header,
 2289   2289   
        }
 2290   2290   
    }
 2291   2291   
    fn __repr__(&self) -> String {
 2292   2292   
        format!("{self:?}")
 2293   2293   
    }
 2294   2294   
    fn __str__(&self) -> String {
 2295   2295   
        format!("{self:?}")
 2296   2296   
    }
@@ -2463,2463 +2581,2581 @@
 2483   2483   
    type Unconstrained = crate::input::malformed_list_input_internal::Builder;
 2484   2484   
}
 2485   2485   
impl MalformedListInput {
 2486   2486   
    /// Creates a new builder-style object to manufacture [`MalformedListInput`](crate::input::MalformedListInput).
 2487   2487   
    pub fn builder() -> crate::input::malformed_list_input::Builder {
 2488   2488   
        crate::input::malformed_list_input::Builder::default()
 2489   2489   
    }
 2490   2490   
}
 2491   2491   
 2492   2492   
#[::pyo3::pyclass]
 2493         -
/// :param boolean_in_body typing.Optional\[bool\]:
 2494   2493   
/// :param boolean_in_path bool:
        2494  +
/// :param boolean_in_body typing.Optional\[bool\]:
 2495   2495   
/// :param boolean_in_query typing.Optional\[bool\]:
 2496   2496   
/// :param boolean_in_header typing.Optional\[bool\]:
 2497   2497   
/// :rtype None:
 2498   2498   
#[allow(missing_docs)] // documentation missing in model
 2499   2499   
#[derive(
 2500   2500   
    ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
 2501   2501   
)]
 2502   2502   
pub struct MalformedBooleanInput {
 2503   2503   
    #[pyo3(get, set)]
 2504   2504   
    /// :type typing.Optional\[bool\]:
 2505   2505   
    #[allow(missing_docs)] // documentation missing in model
 2506   2506   
    pub boolean_in_body: ::std::option::Option<bool>,
 2507   2507   
    #[pyo3(get, set)]
 2508   2508   
    /// :type bool:
 2509   2509   
    #[allow(missing_docs)] // documentation missing in model
 2510   2510   
    pub boolean_in_path: bool,
 2511   2511   
    #[pyo3(get, set)]
 2512   2512   
    /// :type typing.Optional\[bool\]:
 2513   2513   
    #[allow(missing_docs)] // documentation missing in model
 2514   2514   
    pub boolean_in_query: ::std::option::Option<bool>,
 2515   2515   
    #[pyo3(get, set)]
 2516   2516   
    /// :type typing.Optional\[bool\]:
 2517   2517   
    #[allow(missing_docs)] // documentation missing in model
 2518   2518   
    pub boolean_in_header: ::std::option::Option<bool>,
 2519   2519   
}
 2520   2520   
impl MalformedBooleanInput {
 2521   2521   
    #[allow(missing_docs)] // documentation missing in model
 2522   2522   
    pub fn boolean_in_body(&self) -> ::std::option::Option<bool> {
 2523   2523   
        self.boolean_in_body
 2524   2524   
    }
 2525   2525   
    #[allow(missing_docs)] // documentation missing in model
 2526   2526   
    pub fn boolean_in_path(&self) -> bool {
 2527   2527   
        self.boolean_in_path
 2528   2528   
    }
 2529   2529   
    #[allow(missing_docs)] // documentation missing in model
 2530   2530   
    pub fn boolean_in_query(&self) -> ::std::option::Option<bool> {
 2531   2531   
        self.boolean_in_query
 2532   2532   
    }
 2533   2533   
    #[allow(missing_docs)] // documentation missing in model
 2534   2534   
    pub fn boolean_in_header(&self) -> ::std::option::Option<bool> {
 2535   2535   
        self.boolean_in_header
 2536   2536   
    }
 2537   2537   
}
 2538   2538   
#[allow(clippy::new_without_default)]
 2539   2539   
#[allow(clippy::too_many_arguments)]
 2540   2540   
#[::pyo3::pymethods]
 2541   2541   
impl MalformedBooleanInput {
 2542   2542   
    #[new]
 2543   2543   
    pub fn new(
 2544         -
        boolean_in_body: ::std::option::Option<bool>,
 2545   2544   
        boolean_in_path: bool,
        2545  +
        boolean_in_body: ::std::option::Option<bool>,
 2546   2546   
        boolean_in_query: ::std::option::Option<bool>,
 2547   2547   
        boolean_in_header: ::std::option::Option<bool>,
 2548   2548   
    ) -> Self {
 2549   2549   
        Self {
 2550         -
            boolean_in_body,
 2551   2550   
            boolean_in_path,
        2551  +
            boolean_in_body,
 2552   2552   
            boolean_in_query,
 2553   2553   
            boolean_in_header,
 2554   2554   
        }
 2555   2555   
    }
 2556   2556   
    fn __repr__(&self) -> String {
 2557   2557   
        format!("{self:?}")
 2558   2558   
    }
 2559   2559   
    fn __str__(&self) -> String {
 2560   2560   
        format!("{self:?}")
 2561   2561   
    }
@@ -2610,2610 +2728,2728 @@
 2630   2630   
    type Unconstrained = crate::input::malformed_union_input_internal::Builder;
 2631   2631   
}
 2632   2632   
impl MalformedUnionInput {
 2633   2633   
    /// Creates a new builder-style object to manufacture [`MalformedUnionInput`](crate::input::MalformedUnionInput).
 2634   2634   
    pub fn builder() -> crate::input::malformed_union_input::Builder {
 2635   2635   
        crate::input::malformed_union_input::Builder::default()
 2636   2636   
    }
 2637   2637   
}
 2638   2638   
 2639   2639   
#[::pyo3::pyclass]
 2640         -
/// :param integer_in_body typing.Optional\[int\]:
 2641   2640   
/// :param integer_in_path int:
        2641  +
/// :param integer_in_body typing.Optional\[int\]:
 2642   2642   
/// :param integer_in_query typing.Optional\[int\]:
 2643   2643   
/// :param integer_in_header typing.Optional\[int\]:
 2644   2644   
/// :rtype None:
 2645   2645   
#[allow(missing_docs)] // documentation missing in model
 2646   2646   
#[derive(
 2647   2647   
    ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
 2648   2648   
)]
 2649   2649   
pub struct MalformedIntegerInput {
 2650   2650   
    #[pyo3(get, set)]
 2651   2651   
    /// :type typing.Optional\[int\]:
 2652   2652   
    #[allow(missing_docs)] // documentation missing in model
 2653   2653   
    pub integer_in_body: ::std::option::Option<i32>,
 2654   2654   
    #[pyo3(get, set)]
 2655   2655   
    /// :type int:
 2656   2656   
    #[allow(missing_docs)] // documentation missing in model
 2657   2657   
    pub integer_in_path: i32,
 2658   2658   
    #[pyo3(get, set)]
 2659   2659   
    /// :type typing.Optional\[int\]:
 2660   2660   
    #[allow(missing_docs)] // documentation missing in model
 2661   2661   
    pub integer_in_query: ::std::option::Option<i32>,
 2662   2662   
    #[pyo3(get, set)]
 2663   2663   
    /// :type typing.Optional\[int\]:
 2664   2664   
    #[allow(missing_docs)] // documentation missing in model
 2665   2665   
    pub integer_in_header: ::std::option::Option<i32>,
 2666   2666   
}
 2667   2667   
impl MalformedIntegerInput {
 2668   2668   
    #[allow(missing_docs)] // documentation missing in model
 2669   2669   
    pub fn integer_in_body(&self) -> ::std::option::Option<i32> {
 2670   2670   
        self.integer_in_body
 2671   2671   
    }
 2672   2672   
    #[allow(missing_docs)] // documentation missing in model
 2673   2673   
    pub fn integer_in_path(&self) -> i32 {
 2674   2674   
        self.integer_in_path
 2675   2675   
    }
 2676   2676   
    #[allow(missing_docs)] // documentation missing in model
 2677   2677   
    pub fn integer_in_query(&self) -> ::std::option::Option<i32> {
 2678   2678   
        self.integer_in_query
 2679   2679   
    }
 2680   2680   
    #[allow(missing_docs)] // documentation missing in model
 2681   2681   
    pub fn integer_in_header(&self) -> ::std::option::Option<i32> {
 2682   2682   
        self.integer_in_header
 2683   2683   
    }
 2684   2684   
}
 2685   2685   
#[allow(clippy::new_without_default)]
 2686   2686   
#[allow(clippy::too_many_arguments)]
 2687   2687   
#[::pyo3::pymethods]
 2688   2688   
impl MalformedIntegerInput {
 2689   2689   
    #[new]
 2690   2690   
    pub fn new(
 2691         -
        integer_in_body: ::std::option::Option<i32>,
 2692   2691   
        integer_in_path: i32,
        2692  +
        integer_in_body: ::std::option::Option<i32>,
 2693   2693   
        integer_in_query: ::std::option::Option<i32>,
 2694   2694   
        integer_in_header: ::std::option::Option<i32>,
 2695   2695   
    ) -> Self {
 2696   2696   
        Self {
 2697         -
            integer_in_body,
 2698   2697   
            integer_in_path,
        2698  +
            integer_in_body,
 2699   2699   
            integer_in_query,
 2700   2700   
            integer_in_header,
 2701   2701   
        }
 2702   2702   
    }
 2703   2703   
    fn __repr__(&self) -> String {
 2704   2704   
        format!("{self:?}")
 2705   2705   
    }
 2706   2706   
    fn __str__(&self) -> String {
 2707   2707   
        format!("{self:?}")
 2708   2708   
    }
@@ -4562,4562 +4788,4788 @@
 4582   4582   
    type Unconstrained = crate::input::greeting_with_errors_input_internal::Builder;
 4583   4583   
}
 4584   4584   
impl GreetingWithErrorsInput {
 4585   4585   
    /// Creates a new builder-style object to manufacture [`GreetingWithErrorsInput`](crate::input::GreetingWithErrorsInput).
 4586   4586   
    pub fn builder() -> crate::input::greeting_with_errors_input::Builder {
 4587   4587   
        crate::input::greeting_with_errors_input::Builder::default()
 4588   4588   
    }
 4589   4589   
}
 4590   4590   
 4591   4591   
#[::pyo3::pyclass]
 4592         -
/// :param foo typing.Optional\[str\]:
 4593   4592   
/// :param blob rest_json.types.ByteStream:
        4593  +
/// :param foo typing.Optional\[str\]:
 4594   4594   
/// :rtype None:
 4595   4595   
#[allow(missing_docs)] // documentation missing in model
 4596   4596   
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
 4597   4597   
pub struct StreamingTraitsWithMediaTypeInput {
 4598   4598   
    #[pyo3(get, set)]
 4599   4599   
    /// :type typing.Optional\[str\]:
 4600   4600   
    #[allow(missing_docs)] // documentation missing in model
 4601   4601   
    pub foo: ::std::option::Option<::std::string::String>,
 4602   4602   
    #[pyo3(get, set)]
 4603   4603   
    /// :type rest_json.types.ByteStream:
 4604   4604   
    #[allow(missing_docs)] // documentation missing in model
 4605   4605   
    pub blob: ::aws_smithy_http_server_python::types::ByteStream,
 4606   4606   
}
 4607   4607   
impl StreamingTraitsWithMediaTypeInput {
 4608   4608   
    #[allow(missing_docs)] // documentation missing in model
 4609   4609   
    pub fn foo(&self) -> ::std::option::Option<&str> {
 4610   4610   
        self.foo.as_deref()
 4611   4611   
    }
 4612   4612   
    #[allow(missing_docs)] // documentation missing in model
 4613   4613   
    pub fn blob(&self) -> &::aws_smithy_http_server_python::types::ByteStream {
 4614   4614   
        &self.blob
 4615   4615   
    }
 4616   4616   
}
 4617   4617   
#[allow(clippy::new_without_default)]
 4618   4618   
#[allow(clippy::too_many_arguments)]
 4619   4619   
#[::pyo3::pymethods]
 4620   4620   
impl StreamingTraitsWithMediaTypeInput {
 4621   4621   
    #[new]
 4622   4622   
    pub fn new(
 4623         -
        foo: ::std::option::Option<::std::string::String>,
 4624   4623   
        blob: ::aws_smithy_http_server_python::types::ByteStream,
        4624  +
        foo: ::std::option::Option<::std::string::String>,
 4625   4625   
    ) -> Self {
 4626         -
        Self { foo, blob }
        4626  +
        Self { blob, foo }
 4627   4627   
    }
 4628   4628   
    fn __repr__(&self) -> String {
 4629   4629   
        format!("{self:?}")
 4630   4630   
    }
 4631   4631   
    fn __str__(&self) -> String {
 4632   4632   
        format!("{self:?}")
 4633   4633   
    }
 4634   4634   
}
 4635   4635   
impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<StreamingTraitsWithMediaTypeInput> {
 4636   4636   
    fn extract(ob: &'source ::pyo3::PyAny) -> ::pyo3::PyResult<Self> {
 4637   4637   
        ob.extract::<StreamingTraitsWithMediaTypeInput>()
 4638   4638   
            .map(Box::new)
 4639   4639   
    }
 4640   4640   
}
 4641   4641   
 4642   4642   
impl ::pyo3::IntoPy<::pyo3::PyObject> for std::boxed::Box<StreamingTraitsWithMediaTypeInput> {
 4643   4643   
    fn into_py(self, py: ::pyo3::Python<'_>) -> ::pyo3::PyObject {
 4644   4644   
        (*self).into_py(py)
 4645   4645   
    }
 4646   4646   
}
 4647   4647   
impl crate::constrained::Constrained for crate::input::StreamingTraitsWithMediaTypeInput {
 4648   4648   
    type Unconstrained = crate::input::streaming_traits_with_media_type_input_internal::Builder;
 4649   4649   
}
 4650   4650   
impl StreamingTraitsWithMediaTypeInput {
 4651   4651   
    /// Creates a new builder-style object to manufacture [`StreamingTraitsWithMediaTypeInput`](crate::input::StreamingTraitsWithMediaTypeInput).
 4652   4652   
    pub fn builder() -> crate::input::streaming_traits_with_media_type_input::Builder {
 4653   4653   
        crate::input::streaming_traits_with_media_type_input::Builder::default()
 4654   4654   
    }
 4655   4655   
}
 4656   4656   
 4657   4657   
#[::pyo3::pyclass]
 4658         -
/// :param foo typing.Optional\[str\]:
 4659   4658   
/// :param blob rest_json.types.ByteStream:
        4659  +
/// :param foo typing.Optional\[str\]:
 4660   4660   
/// :rtype None:
 4661   4661   
#[allow(missing_docs)] // documentation missing in model
 4662   4662   
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
 4663   4663   
pub struct StreamingTraitsRequireLengthInput {
 4664   4664   
    #[pyo3(get, set)]
 4665   4665   
    /// :type typing.Optional\[str\]:
 4666   4666   
    #[allow(missing_docs)] // documentation missing in model
 4667   4667   
    pub foo: ::std::option::Option<::std::string::String>,
 4668   4668   
    #[pyo3(get, set)]
 4669   4669   
    /// :type rest_json.types.ByteStream:
 4670   4670   
    #[allow(missing_docs)] // documentation missing in model
 4671   4671   
    pub blob: ::aws_smithy_http_server_python::types::ByteStream,
 4672   4672   
}
 4673   4673   
impl StreamingTraitsRequireLengthInput {
 4674   4674   
    #[allow(missing_docs)] // documentation missing in model
 4675   4675   
    pub fn foo(&self) -> ::std::option::Option<&str> {
 4676   4676   
        self.foo.as_deref()
 4677   4677   
    }
 4678   4678   
    #[allow(missing_docs)] // documentation missing in model
 4679   4679   
    pub fn blob(&self) -> &::aws_smithy_http_server_python::types::ByteStream {
 4680   4680   
        &self.blob
 4681   4681   
    }
 4682   4682   
}
 4683   4683   
#[allow(clippy::new_without_default)]
 4684   4684   
#[allow(clippy::too_many_arguments)]
 4685   4685   
#[::pyo3::pymethods]
 4686   4686   
impl StreamingTraitsRequireLengthInput {
 4687   4687   
    #[new]
 4688   4688   
    pub fn new(
 4689         -
        foo: ::std::option::Option<::std::string::String>,
 4690   4689   
        blob: ::aws_smithy_http_server_python::types::ByteStream,
        4690  +
        foo: ::std::option::Option<::std::string::String>,
 4691   4691   
    ) -> Self {
 4692         -
        Self { foo, blob }
        4692  +
        Self { blob, foo }
 4693   4693   
    }
 4694   4694   
    fn __repr__(&self) -> String {
 4695   4695   
        format!("{self:?}")
 4696   4696   
    }
 4697   4697   
    fn __str__(&self) -> String {
 4698   4698   
        format!("{self:?}")
 4699   4699   
    }
 4700   4700   
}
 4701   4701   
impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<StreamingTraitsRequireLengthInput> {
 4702   4702   
    fn extract(ob: &'source ::pyo3::PyAny) -> ::pyo3::PyResult<Self> {
 4703   4703   
        ob.extract::<StreamingTraitsRequireLengthInput>()
 4704   4704   
            .map(Box::new)
 4705   4705   
    }
 4706   4706   
}
 4707   4707   
 4708   4708   
impl ::pyo3::IntoPy<::pyo3::PyObject> for std::boxed::Box<StreamingTraitsRequireLengthInput> {
 4709   4709   
    fn into_py(self, py: ::pyo3::Python<'_>) -> ::pyo3::PyObject {
 4710   4710   
        (*self).into_py(py)
 4711   4711   
    }
 4712   4712   
}
 4713   4713   
impl crate::constrained::Constrained for crate::input::StreamingTraitsRequireLengthInput {
 4714   4714   
    type Unconstrained = crate::input::streaming_traits_require_length_input_internal::Builder;
 4715   4715   
}
 4716   4716   
impl StreamingTraitsRequireLengthInput {
 4717   4717   
    /// Creates a new builder-style object to manufacture [`StreamingTraitsRequireLengthInput`](crate::input::StreamingTraitsRequireLengthInput).
 4718   4718   
    pub fn builder() -> crate::input::streaming_traits_require_length_input::Builder {
 4719   4719   
        crate::input::streaming_traits_require_length_input::Builder::default()
 4720   4720   
    }
 4721   4721   
}
 4722   4722   
 4723   4723   
#[::pyo3::pyclass]
 4724         -
/// :param foo typing.Optional\[str\]:
 4725   4724   
/// :param blob rest_json.types.ByteStream:
        4725  +
/// :param foo typing.Optional\[str\]:
 4726   4726   
/// :rtype None:
 4727   4727   
#[allow(missing_docs)] // documentation missing in model
 4728   4728   
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
 4729   4729   
pub struct StreamingTraitsInput {
 4730   4730   
    #[pyo3(get, set)]
 4731   4731   
    /// :type typing.Optional\[str\]:
 4732   4732   
    #[allow(missing_docs)] // documentation missing in model
 4733   4733   
    pub foo: ::std::option::Option<::std::string::String>,
 4734   4734   
    #[pyo3(get, set)]
 4735   4735   
    /// :type rest_json.types.ByteStream:
 4736   4736   
    #[allow(missing_docs)] // documentation missing in model
 4737   4737   
    pub blob: ::aws_smithy_http_server_python::types::ByteStream,
 4738   4738   
}
 4739   4739   
impl StreamingTraitsInput {
 4740   4740   
    #[allow(missing_docs)] // documentation missing in model
 4741   4741   
    pub fn foo(&self) -> ::std::option::Option<&str> {
 4742   4742   
        self.foo.as_deref()
 4743   4743   
    }
 4744   4744   
    #[allow(missing_docs)] // documentation missing in model
 4745   4745   
    pub fn blob(&self) -> &::aws_smithy_http_server_python::types::ByteStream {
 4746   4746   
        &self.blob
 4747   4747   
    }
 4748   4748   
}
 4749   4749   
#[allow(clippy::new_without_default)]
 4750   4750   
#[allow(clippy::too_many_arguments)]
 4751   4751   
#[::pyo3::pymethods]
 4752   4752   
impl StreamingTraitsInput {
 4753   4753   
    #[new]
 4754   4754   
    pub fn new(
 4755         -
        foo: ::std::option::Option<::std::string::String>,
 4756   4755   
        blob: ::aws_smithy_http_server_python::types::ByteStream,
        4756  +
        foo: ::std::option::Option<::std::string::String>,
 4757   4757   
    ) -> Self {
 4758         -
        Self { foo, blob }
        4758  +
        Self { blob, foo }
 4759   4759   
    }
 4760   4760   
    fn __repr__(&self) -> String {
 4761   4761   
        format!("{self:?}")
 4762   4762   
    }
 4763   4763   
    fn __str__(&self) -> String {
 4764   4764   
        format!("{self:?}")
 4765   4765   
    }
 4766   4766   
}
 4767   4767   
impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<StreamingTraitsInput> {
 4768   4768   
    fn extract(ob: &'source ::pyo3::PyAny) -> ::pyo3::PyResult<Self> {

tmp-codegen-diff/codegen-server-test-python/rest_json/rust-server-codegen-python/src/model.rs

@@ -36,36 +145,145 @@
   56     56   
    }
   57     57   
}
   58     58   
impl ValidationExceptionField {
   59     59   
    /// Creates a new builder-style object to manufacture [`ValidationExceptionField`](crate::model::ValidationExceptionField).
   60     60   
    pub fn builder() -> crate::model::validation_exception_field::Builder {
   61     61   
        crate::model::validation_exception_field::Builder::default()
   62     62   
    }
   63     63   
}
   64     64   
   65     65   
#[::pyo3::pyclass]
   66         -
/// :param language typing.Optional\[str\]:
   67     66   
/// :param greeting str:
          67  +
/// :param language typing.Optional\[str\]:
   68     68   
/// :param farewell typing.Optional\[rest_json.model.Farewell\]:
   69     69   
/// :rtype None:
   70     70   
#[allow(missing_docs)] // documentation missing in model
   71     71   
#[derive(
   72     72   
    ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
   73     73   
)]
   74     74   
pub struct Dialog {
   75     75   
    #[pyo3(get, set)]
   76     76   
    /// :type typing.Optional\[str\]:
   77     77   
    #[allow(missing_docs)] // documentation missing in model
   78     78   
    pub language: ::std::option::Option<::std::string::String>,
   79     79   
    #[pyo3(get, set)]
   80     80   
    /// :type str:
   81     81   
    #[allow(missing_docs)] // documentation missing in model
   82     82   
    pub greeting: ::std::string::String,
   83     83   
    #[pyo3(get, set)]
   84     84   
    /// :type typing.Optional\[rest_json.model.Farewell\]:
   85     85   
    #[allow(missing_docs)] // documentation missing in model
   86     86   
    pub farewell: ::std::option::Option<crate::model::Farewell>,
   87     87   
}
   88     88   
impl Dialog {
   89     89   
    #[allow(missing_docs)] // documentation missing in model
   90     90   
    pub fn language(&self) -> ::std::option::Option<&str> {
   91     91   
        self.language.as_deref()
   92     92   
    }
   93     93   
    #[allow(missing_docs)] // documentation missing in model
   94     94   
    pub fn greeting(&self) -> &str {
   95     95   
        use std::ops::Deref;
   96     96   
        self.greeting.deref()
   97     97   
    }
   98     98   
    #[allow(missing_docs)] // documentation missing in model
   99     99   
    pub fn farewell(&self) -> ::std::option::Option<&crate::model::Farewell> {
  100    100   
        self.farewell.as_ref()
  101    101   
    }
  102    102   
}
  103    103   
#[allow(clippy::new_without_default)]
  104    104   
#[allow(clippy::too_many_arguments)]
  105    105   
#[::pyo3::pymethods]
  106    106   
impl Dialog {
  107    107   
    #[new]
  108    108   
    pub fn new(
  109         -
        language: ::std::option::Option<::std::string::String>,
  110    109   
        greeting: ::std::string::String,
         110  +
        language: ::std::option::Option<::std::string::String>,
  111    111   
        farewell: ::std::option::Option<crate::model::Farewell>,
  112    112   
    ) -> Self {
  113    113   
        Self {
  114         -
            language,
  115    114   
            greeting,
         115  +
            language,
  116    116   
            farewell,
  117    117   
        }
  118    118   
    }
  119    119   
    fn __repr__(&self) -> String {
  120    120   
        format!("{self:?}")
  121    121   
    }
  122    122   
    fn __str__(&self) -> String {
  123    123   
        format!("{self:?}")
  124    124   
    }
  125    125   
}
@@ -448,448 +528,528 @@
  468    468   
}
  469    469   
  470    470   
#[::pyo3::pyclass]
  471    471   
/// :param default_string str:
  472    472   
/// :param default_boolean bool:
  473    473   
/// :param default_list typing.List\[str\]:
  474    474   
/// :param default_document_map rest_json.types.Document:
  475    475   
/// :param default_document_string rest_json.types.Document:
  476    476   
/// :param default_document_boolean rest_json.types.Document:
  477    477   
/// :param default_document_list rest_json.types.Document:
  478         -
/// :param default_null_document typing.Optional\[rest_json.types.Document\]:
  479    478   
/// :param default_timestamp rest_json.types.DateTime:
  480    479   
/// :param default_blob rest_json.types.Blob:
  481    480   
/// :param default_byte int:
  482    481   
/// :param default_short int:
  483    482   
/// :param default_integer int:
  484    483   
/// :param default_long int:
  485    484   
/// :param default_float float:
  486    485   
/// :param default_double float:
  487    486   
/// :param default_map typing.Dict\[str, str\]:
  488    487   
/// :param default_enum rest_json.model.TestEnum:
  489    488   
/// :param default_int_enum int:
  490    489   
/// :param empty_string str:
  491    490   
/// :param false_boolean bool:
  492    491   
/// :param empty_blob rest_json.types.Blob:
  493    492   
/// :param zero_byte int:
  494    493   
/// :param zero_short int:
  495    494   
/// :param zero_integer int:
  496    495   
/// :param zero_long int:
  497    496   
/// :param zero_float float:
  498    497   
/// :param zero_double float:
         498  +
/// :param default_null_document typing.Optional\[rest_json.types.Document\]:
  499    499   
/// :rtype None:
  500    500   
#[allow(missing_docs)] // documentation missing in model
  501    501   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
  502    502   
pub struct Defaults {
  503    503   
    #[pyo3(get, set)]
  504    504   
    /// :type str:
  505    505   
    #[allow(missing_docs)] // documentation missing in model
  506    506   
    pub default_string: ::std::string::String,
  507    507   
    #[pyo3(get, set)]
  508    508   
    /// :type bool:
@@ -721,721 +833,833 @@
  741    741   
impl Defaults {
  742    742   
    #[new]
  743    743   
    pub fn new(
  744    744   
        default_string: ::std::string::String,
  745    745   
        default_boolean: bool,
  746    746   
        default_list: ::std::vec::Vec<::std::string::String>,
  747    747   
        default_document_map: ::aws_smithy_http_server_python::types::Document,
  748    748   
        default_document_string: ::aws_smithy_http_server_python::types::Document,
  749    749   
        default_document_boolean: ::aws_smithy_http_server_python::types::Document,
  750    750   
        default_document_list: ::aws_smithy_http_server_python::types::Document,
  751         -
        default_null_document: ::std::option::Option<
  752         -
            ::aws_smithy_http_server_python::types::Document,
  753         -
        >,
  754    751   
        default_timestamp: ::aws_smithy_http_server_python::types::DateTime,
  755    752   
        default_blob: ::aws_smithy_http_server_python::types::Blob,
  756    753   
        default_byte: i8,
  757    754   
        default_short: i16,
  758    755   
        default_integer: i32,
  759    756   
        default_long: i64,
  760    757   
        default_float: f32,
  761    758   
        default_double: f64,
  762    759   
        default_map: ::std::collections::HashMap<::std::string::String, ::std::string::String>,
  763    760   
        default_enum: crate::model::TestEnum,
  764    761   
        default_int_enum: i32,
  765    762   
        empty_string: ::std::string::String,
  766    763   
        false_boolean: bool,
  767    764   
        empty_blob: ::aws_smithy_http_server_python::types::Blob,
  768    765   
        zero_byte: i8,
  769    766   
        zero_short: i16,
  770    767   
        zero_integer: i32,
  771    768   
        zero_long: i64,
  772    769   
        zero_float: f32,
  773    770   
        zero_double: f64,
         771  +
        default_null_document: ::std::option::Option<
         772  +
            ::aws_smithy_http_server_python::types::Document,
         773  +
        >,
  774    774   
    ) -> Self {
  775    775   
        Self {
  776    776   
            default_string,
  777    777   
            default_boolean,
  778    778   
            default_list,
  779    779   
            default_document_map,
  780    780   
            default_document_string,
  781    781   
            default_document_boolean,
  782    782   
            default_document_list,
  783         -
            default_null_document,
  784    783   
            default_timestamp,
  785    784   
            default_blob,
  786    785   
            default_byte,
  787    786   
            default_short,
  788    787   
            default_integer,
  789    788   
            default_long,
  790    789   
            default_float,
  791    790   
            default_double,
  792    791   
            default_map,
  793    792   
            default_enum,
  794    793   
            default_int_enum,
  795    794   
            empty_string,
  796    795   
            false_boolean,
  797    796   
            empty_blob,
  798    797   
            zero_byte,
  799    798   
            zero_short,
  800    799   
            zero_integer,
  801    800   
            zero_long,
  802    801   
            zero_float,
  803    802   
            zero_double,
         803  +
            default_null_document,
  804    804   
        }
  805    805   
    }
  806    806   
    fn __repr__(&self) -> String {
  807    807   
        format!("{self:?}")
  808    808   
    }
  809    809   
    fn __str__(&self) -> String {
  810    810   
        format!("{self:?}")
  811    811   
    }
  812    812   
}
  813    813   
impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<Defaults> {

tmp-codegen-diff/codegen-server-test-python/rest_json/rust-server-codegen-python/src/output.rs

@@ -62,62 +142,142 @@
   82     82   
}
   83     83   
   84     84   
#[::pyo3::pyclass]
   85     85   
/// :param default_string str:
   86     86   
/// :param default_boolean bool:
   87     87   
/// :param default_list typing.List\[str\]:
   88     88   
/// :param default_document_map rest_json.types.Document:
   89     89   
/// :param default_document_string rest_json.types.Document:
   90     90   
/// :param default_document_boolean rest_json.types.Document:
   91     91   
/// :param default_document_list rest_json.types.Document:
   92         -
/// :param default_null_document typing.Optional\[rest_json.types.Document\]:
   93     92   
/// :param default_timestamp rest_json.types.DateTime:
   94     93   
/// :param default_blob rest_json.types.Blob:
   95     94   
/// :param default_byte int:
   96     95   
/// :param default_short int:
   97     96   
/// :param default_integer int:
   98     97   
/// :param default_long int:
   99     98   
/// :param default_float float:
  100     99   
/// :param default_double float:
  101    100   
/// :param default_map typing.Dict\[str, str\]:
  102    101   
/// :param default_enum rest_json.model.TestEnum:
  103    102   
/// :param default_int_enum int:
  104    103   
/// :param empty_string str:
  105    104   
/// :param false_boolean bool:
  106    105   
/// :param empty_blob rest_json.types.Blob:
  107    106   
/// :param zero_byte int:
  108    107   
/// :param zero_short int:
  109    108   
/// :param zero_integer int:
  110    109   
/// :param zero_long int:
  111    110   
/// :param zero_float float:
  112    111   
/// :param zero_double float:
         112  +
/// :param default_null_document typing.Optional\[rest_json.types.Document\]:
  113    113   
/// :rtype None:
  114    114   
#[allow(missing_docs)] // documentation missing in model
  115    115   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
  116    116   
pub struct OperationWithDefaultsOutput {
  117    117   
    #[pyo3(get, set)]
  118    118   
    /// :type str:
  119    119   
    #[allow(missing_docs)] // documentation missing in model
  120    120   
    pub default_string: ::std::string::String,
  121    121   
    #[pyo3(get, set)]
  122    122   
    /// :type bool:
@@ -335,335 +447,447 @@
  355    355   
impl OperationWithDefaultsOutput {
  356    356   
    #[new]
  357    357   
    pub fn new(
  358    358   
        default_string: ::std::string::String,
  359    359   
        default_boolean: bool,
  360    360   
        default_list: ::std::vec::Vec<::std::string::String>,
  361    361   
        default_document_map: ::aws_smithy_http_server_python::types::Document,
  362    362   
        default_document_string: ::aws_smithy_http_server_python::types::Document,
  363    363   
        default_document_boolean: ::aws_smithy_http_server_python::types::Document,
  364    364   
        default_document_list: ::aws_smithy_http_server_python::types::Document,
  365         -
        default_null_document: ::std::option::Option<
  366         -
            ::aws_smithy_http_server_python::types::Document,
  367         -
        >,
  368    365   
        default_timestamp: ::aws_smithy_http_server_python::types::DateTime,
  369    366   
        default_blob: ::aws_smithy_http_server_python::types::Blob,
  370    367   
        default_byte: i8,
  371    368   
        default_short: i16,
  372    369   
        default_integer: i32,
  373    370   
        default_long: i64,
  374    371   
        default_float: f32,
  375    372   
        default_double: f64,
  376    373   
        default_map: ::std::collections::HashMap<::std::string::String, ::std::string::String>,
  377    374   
        default_enum: crate::model::TestEnum,
  378    375   
        default_int_enum: i32,
  379    376   
        empty_string: ::std::string::String,
  380    377   
        false_boolean: bool,
  381    378   
        empty_blob: ::aws_smithy_http_server_python::types::Blob,
  382    379   
        zero_byte: i8,
  383    380   
        zero_short: i16,
  384    381   
        zero_integer: i32,
  385    382   
        zero_long: i64,
  386    383   
        zero_float: f32,
  387    384   
        zero_double: f64,
         385  +
        default_null_document: ::std::option::Option<
         386  +
            ::aws_smithy_http_server_python::types::Document,
         387  +
        >,
  388    388   
    ) -> Self {
  389    389   
        Self {
  390    390   
            default_string,
  391    391   
            default_boolean,
  392    392   
            default_list,
  393    393   
            default_document_map,
  394    394   
            default_document_string,
  395    395   
            default_document_boolean,
  396    396   
            default_document_list,
  397         -
            default_null_document,
  398    397   
            default_timestamp,
  399    398   
            default_blob,
  400    399   
            default_byte,
  401    400   
            default_short,
  402    401   
            default_integer,
  403    402   
            default_long,
  404    403   
            default_float,
  405    404   
            default_double,
  406    405   
            default_map,
  407    406   
            default_enum,
  408    407   
            default_int_enum,
  409    408   
            empty_string,
  410    409   
            false_boolean,
  411    410   
            empty_blob,
  412    411   
            zero_byte,
  413    412   
            zero_short,
  414    413   
            zero_integer,
  415    414   
            zero_long,
  416    415   
            zero_float,
  417    416   
            zero_double,
         417  +
            default_null_document,
  418    418   
        }
  419    419   
    }
  420    420   
    fn __repr__(&self) -> String {
  421    421   
        format!("{self:?}")
  422    422   
    }
  423    423   
    fn __str__(&self) -> String {
  424    424   
        format!("{self:?}")
  425    425   
    }
  426    426   
}
  427    427   
impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<OperationWithDefaultsOutput> {
@@ -4118,4118 +4212,4212 @@
 4138   4138   
    }
 4139   4139   
}
 4140   4140   
impl GreetingWithErrorsOutput {
 4141   4141   
    /// Creates a new builder-style object to manufacture [`GreetingWithErrorsOutput`](crate::output::GreetingWithErrorsOutput).
 4142   4142   
    pub fn builder() -> crate::output::greeting_with_errors_output::Builder {
 4143   4143   
        crate::output::greeting_with_errors_output::Builder::default()
 4144   4144   
    }
 4145   4145   
}
 4146   4146   
 4147   4147   
#[::pyo3::pyclass]
 4148         -
/// :param foo typing.Optional\[str\]:
 4149   4148   
/// :param blob rest_json.types.ByteStream:
        4149  +
/// :param foo typing.Optional\[str\]:
 4150   4150   
/// :rtype None:
 4151   4151   
#[allow(missing_docs)] // documentation missing in model
 4152   4152   
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
 4153   4153   
pub struct StreamingTraitsWithMediaTypeOutput {
 4154   4154   
    #[pyo3(get, set)]
 4155   4155   
    /// :type typing.Optional\[str\]:
 4156   4156   
    #[allow(missing_docs)] // documentation missing in model
 4157   4157   
    pub foo: ::std::option::Option<::std::string::String>,
 4158   4158   
    #[pyo3(get, set)]
 4159   4159   
    /// :type rest_json.types.ByteStream:
 4160   4160   
    #[allow(missing_docs)] // documentation missing in model
 4161   4161   
    pub blob: ::aws_smithy_http_server_python::types::ByteStream,
 4162   4162   
}
 4163   4163   
impl StreamingTraitsWithMediaTypeOutput {
 4164   4164   
    #[allow(missing_docs)] // documentation missing in model
 4165   4165   
    pub fn foo(&self) -> ::std::option::Option<&str> {
 4166   4166   
        self.foo.as_deref()
 4167   4167   
    }
 4168   4168   
    #[allow(missing_docs)] // documentation missing in model
 4169   4169   
    pub fn blob(&self) -> &::aws_smithy_http_server_python::types::ByteStream {
 4170   4170   
        &self.blob
 4171   4171   
    }
 4172   4172   
}
 4173   4173   
#[allow(clippy::new_without_default)]
 4174   4174   
#[allow(clippy::too_many_arguments)]
 4175   4175   
#[::pyo3::pymethods]
 4176   4176   
impl StreamingTraitsWithMediaTypeOutput {
 4177   4177   
    #[new]
 4178   4178   
    pub fn new(
 4179         -
        foo: ::std::option::Option<::std::string::String>,
 4180   4179   
        blob: ::aws_smithy_http_server_python::types::ByteStream,
        4180  +
        foo: ::std::option::Option<::std::string::String>,
 4181   4181   
    ) -> Self {
 4182         -
        Self { foo, blob }
        4182  +
        Self { blob, foo }
 4183   4183   
    }
 4184   4184   
    fn __repr__(&self) -> String {
 4185   4185   
        format!("{self:?}")
 4186   4186   
    }
 4187   4187   
    fn __str__(&self) -> String {
 4188   4188   
        format!("{self:?}")
 4189   4189   
    }
 4190   4190   
}
 4191   4191   
impl<'source> ::pyo3::FromPyObject<'source>
 4192   4192   
    for std::boxed::Box<StreamingTraitsWithMediaTypeOutput>
@@ -4226,4226 +4320,4320 @@
 4246   4246   
    }
 4247   4247   
}
 4248   4248   
impl StreamingTraitsRequireLengthOutput {
 4249   4249   
    /// Creates a new builder-style object to manufacture [`StreamingTraitsRequireLengthOutput`](crate::output::StreamingTraitsRequireLengthOutput).
 4250   4250   
    pub fn builder() -> crate::output::streaming_traits_require_length_output::Builder {
 4251   4251   
        crate::output::streaming_traits_require_length_output::Builder::default()
 4252   4252   
    }
 4253   4253   
}
 4254   4254   
 4255   4255   
#[::pyo3::pyclass]
 4256         -
/// :param foo typing.Optional\[str\]:
 4257   4256   
/// :param blob rest_json.types.ByteStream:
        4257  +
/// :param foo typing.Optional\[str\]:
 4258   4258   
/// :rtype None:
 4259   4259   
#[allow(missing_docs)] // documentation missing in model
 4260   4260   
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
 4261   4261   
pub struct StreamingTraitsOutput {
 4262   4262   
    #[pyo3(get, set)]
 4263   4263   
    /// :type typing.Optional\[str\]:
 4264   4264   
    #[allow(missing_docs)] // documentation missing in model
 4265   4265   
    pub foo: ::std::option::Option<::std::string::String>,
 4266   4266   
    #[pyo3(get, set)]
 4267   4267   
    /// :type rest_json.types.ByteStream:
 4268   4268   
    #[allow(missing_docs)] // documentation missing in model
 4269   4269   
    pub blob: ::aws_smithy_http_server_python::types::ByteStream,
 4270   4270   
}
 4271   4271   
impl StreamingTraitsOutput {
 4272   4272   
    #[allow(missing_docs)] // documentation missing in model
 4273   4273   
    pub fn foo(&self) -> ::std::option::Option<&str> {
 4274   4274   
        self.foo.as_deref()
 4275   4275   
    }
 4276   4276   
    #[allow(missing_docs)] // documentation missing in model
 4277   4277   
    pub fn blob(&self) -> &::aws_smithy_http_server_python::types::ByteStream {
 4278   4278   
        &self.blob
 4279   4279   
    }
 4280   4280   
}
 4281   4281   
#[allow(clippy::new_without_default)]
 4282   4282   
#[allow(clippy::too_many_arguments)]
 4283   4283   
#[::pyo3::pymethods]
 4284   4284   
impl StreamingTraitsOutput {
 4285   4285   
    #[new]
 4286   4286   
    pub fn new(
 4287         -
        foo: ::std::option::Option<::std::string::String>,
 4288   4287   
        blob: ::aws_smithy_http_server_python::types::ByteStream,
        4288  +
        foo: ::std::option::Option<::std::string::String>,
 4289   4289   
    ) -> Self {
 4290         -
        Self { foo, blob }
        4290  +
        Self { blob, foo }
 4291   4291   
    }
 4292   4292   
    fn __repr__(&self) -> String {
 4293   4293   
        format!("{self:?}")
 4294   4294   
    }
 4295   4295   
    fn __str__(&self) -> String {
 4296   4296   
        format!("{self:?}")
 4297   4297   
    }
 4298   4298   
}
 4299   4299   
impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<StreamingTraitsOutput> {
 4300   4300   
    fn extract(ob: &'source ::pyo3::PyAny) -> ::pyo3::PyResult<Self> {

tmp-codegen-diff/codegen-server-test-python/rest_json/rust-server-codegen-python/src/python_module_export.rs

@@ -1,1 +33,33 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
#[::pyo3::pymodule]
    3         -
#[::pyo3(name = "rest_json")]
           3  +
#[pyo3(name = "rest_json")]
    4      4   
pub fn python_library(py: ::pyo3::Python<'_>, m: &::pyo3::types::PyModule) -> ::pyo3::PyResult<()> {
    5      5   
    let input = ::pyo3::types::PyModule::new(py, "input")?;
    6      6   
    let output = ::pyo3::types::PyModule::new(py, "output")?;
    7      7   
    let error = ::pyo3::types::PyModule::new(py, "error")?;
    8      8   
    error.add_class::<crate::error::InternalServerError>()?;
    9      9   
    error.add_class::<crate::error::ValidationException>()?;
   10     10   
    let model = ::pyo3::types::PyModule::new(py, "model")?;
   11     11   
    model.add_class::<crate::model::ValidationExceptionField>()?;
   12     12   
    output.add_class::<crate::output::OperationWithNestedStructureOutput>()?;
   13     13   
    model.add_class::<crate::model::Dialog>()?;

tmp-codegen-diff/codegen-server-test-python/rest_json_extras/rust-server-codegen-python/Cargo.toml

@@ -12,12 +64,64 @@
   32     32   
version = "0.3"
   33     33   
[dependencies.nom]
   34     34   
version = "7"
   35     35   
[dependencies.parking_lot]
   36     36   
version = "0.12"
   37     37   
[dependencies.percent-encoding]
   38     38   
version = "2.0.0"
   39     39   
[dependencies.pin-project-lite]
   40     40   
version = "0.2"
   41     41   
[dependencies.pyo3]
   42         -
version = "0.18"
          42  +
version = "0.20"
   43     43   
[dependencies.pyo3-asyncio]
   44         -
version = "0.18"
          44  +
version = "0.20"
   45     45   
features = ["attributes", "tokio-runtime"]
   46     46   
[dependencies.tower]
   47     47   
version = "0.4"
   48     48   
[dependencies.tracing]
   49     49   
version = "0.1"
   50     50   
[dev-dependencies.hyper]
   51     51   
version = "0.14.12"
   52     52   
[dev-dependencies.tokio]
   53     53   
version = "1.23.1"
   54     54   
[features]

tmp-codegen-diff/codegen-server-test-python/rest_json_extras/rust-server-codegen-python/src/python_module_export.rs

@@ -1,1 +33,33 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
#[::pyo3::pymodule]
    3         -
#[::pyo3(name = "rest_json_extras")]
           3  +
#[pyo3(name = "rest_json_extras")]
    4      4   
pub fn python_library(py: ::pyo3::Python<'_>, m: &::pyo3::types::PyModule) -> ::pyo3::PyResult<()> {
    5      5   
    let input = ::pyo3::types::PyModule::new(py, "input")?;
    6      6   
    let output = ::pyo3::types::PyModule::new(py, "output")?;
    7      7   
    let error = ::pyo3::types::PyModule::new(py, "error")?;
    8      8   
    error.add_class::<crate::error::ExtraError>()?;
    9      9   
    error.add_class::<crate::error::InternalServerError>()?;
   10     10   
    output.add_class::<crate::output::QueryPrecedenceOutput>()?;
   11     11   
    input.add_class::<crate::input::QueryPrecedenceInput>()?;
   12     12   
    output.add_class::<crate::output::EmptyStructWithContentOnWireOpOutput>()?;
   13     13   
    let model = ::pyo3::types::PyModule::new(py, "model")?;

tmp-codegen-diff/codegen-server-test-python/simple/rust-server-codegen-python/Cargo.toml

@@ -6,6 +58,58 @@
   26     26   
version = "0.2.9"
   27     27   
[dependencies.hyper]
   28     28   
version = "0.14.26"
   29     29   
[dependencies.mime]
   30     30   
version = "0.3"
   31     31   
[dependencies.parking_lot]
   32     32   
version = "0.12"
   33     33   
[dependencies.pin-project-lite]
   34     34   
version = "0.2"
   35     35   
[dependencies.pyo3]
   36         -
version = "0.18"
          36  +
version = "0.20"
   37     37   
[dependencies.pyo3-asyncio]
   38         -
version = "0.18"
          38  +
version = "0.20"
   39     39   
features = ["attributes", "tokio-runtime"]
   40     40   
[dependencies.tower]
   41     41   
version = "0.4"
   42     42   
[dependencies.tracing]
   43     43   
version = "0.1"
   44     44   
[dev-dependencies.hyper]
   45     45   
version = "0.14.12"
   46     46   
[dev-dependencies.tokio]
   47     47   
version = "1.23.1"
   48     48   
[features]

tmp-codegen-diff/codegen-server-test-python/simple/rust-server-codegen-python/src/python_module_export.rs

@@ -1,1 +33,33 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
#[::pyo3::pymodule]
    3         -
#[::pyo3(name = "simple")]
           3  +
#[pyo3(name = "simple")]
    4      4   
pub fn python_library(py: ::pyo3::Python<'_>, m: &::pyo3::types::PyModule) -> ::pyo3::PyResult<()> {
    5      5   
    let input = ::pyo3::types::PyModule::new(py, "input")?;
    6      6   
    let output = ::pyo3::types::PyModule::new(py, "output")?;
    7      7   
    let error = ::pyo3::types::PyModule::new(py, "error")?;
    8      8   
    error.add_class::<crate::error::InternalServerError>()?;
    9      9   
    output.add_class::<crate::output::OperationOutput>()?;
   10     10   
    input.add_class::<crate::input::OperationInput>()?;
   11     11   
    ::pyo3::py_run!(py, input, "import sys; sys.modules['simple.input'] = input");
   12     12   
    m.add_submodule(input)?;
   13     13   
    ::pyo3::py_run!(

tmp-codegen-diff/codegen-server-test-python/unique_items/rust-server-codegen-python/Cargo.toml

@@ -6,6 +58,58 @@
   26     26   
version = "0.2.9"
   27     27   
[dependencies.hyper]
   28     28   
version = "0.14.26"
   29     29   
[dependencies.mime]
   30     30   
version = "0.3"
   31     31   
[dependencies.parking_lot]
   32     32   
version = "0.12"
   33     33   
[dependencies.pin-project-lite]
   34     34   
version = "0.2"
   35     35   
[dependencies.pyo3]
   36         -
version = "0.18"
          36  +
version = "0.20"
   37     37   
[dependencies.pyo3-asyncio]
   38         -
version = "0.18"
          38  +
version = "0.20"
   39     39   
features = ["attributes", "tokio-runtime"]
   40     40   
[dependencies.tower]
   41     41   
version = "0.4"
   42     42   
[dependencies.tracing]
   43     43   
version = "0.1"
   44     44   
[dev-dependencies.hyper]
   45     45   
version = "0.14.12"
   46     46   
[dev-dependencies.tokio]
   47     47   
version = "1.23.1"
   48     48   
[features]

tmp-codegen-diff/codegen-server-test-python/unique_items/rust-server-codegen-python/src/python_module_export.rs

@@ -1,1 +33,33 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
#[::pyo3::pymodule]
    3         -
#[::pyo3(name = "unique_items")]
           3  +
#[pyo3(name = "unique_items")]
    4      4   
pub fn python_library(py: ::pyo3::Python<'_>, m: &::pyo3::types::PyModule) -> ::pyo3::PyResult<()> {
    5      5   
    let input = ::pyo3::types::PyModule::new(py, "input")?;
    6      6   
    let output = ::pyo3::types::PyModule::new(py, "output")?;
    7      7   
    let error = ::pyo3::types::PyModule::new(py, "error")?;
    8      8   
    error.add_class::<crate::error::InternalServerError>()?;
    9      9   
    error.add_class::<crate::error::ValidationException>()?;
   10     10   
    let model = ::pyo3::types::PyModule::new(py, "model")?;
   11     11   
    model.add_class::<crate::model::ValidationExceptionField>()?;
   12     12   
    output.add_class::<crate::output::MalformedUniqueItemsOutput>()?;
   13     13   
    input.add_class::<crate::input::MalformedUniqueItemsInput>()?;