appier 1.35.0__py2.py3-none-any.whl → 1.35.1__py2.py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
appier/asgi.py CHANGED
@@ -189,9 +189,16 @@ class ASGIApp(object):
189
189
  self._ensure_start(ctx, start_response)
190
190
  await ctx["start_task"]
191
191
 
192
+ # ensures the result is a sequence for iteration and if it's
193
+ # not initializes it as an empty list, notice the special case
194
+ # of a string that should be converted into a single element list
195
+ result = result if result else []
196
+ if legacy.is_string(result):
197
+ result = [result]
198
+
192
199
  # iterates over the complete set of chunks in the response
193
200
  # iterator to send each of them to the client side
194
- for chunk in result if result else []:
201
+ for chunk in result:
195
202
  if asyncio.iscoroutine(chunk):
196
203
  await chunk
197
204
  elif asyncio.isfuture(chunk):
appier/graph.py CHANGED
@@ -105,7 +105,7 @@ class Graph(object):
105
105
  queue.push(src, priority=0)
106
106
 
107
107
  while queue.length() > 0:
108
- (_, _, top) = queue.pop(full=True)
108
+ _, _, top = queue.pop(full=True)
109
109
  dist[top] = dist[top] if top in dist else defines.INFINITY
110
110
 
111
111
  edges = self.edges[top] if top in self.edges else []
appier/model.pyi CHANGED
@@ -42,6 +42,18 @@ class Model:
42
42
  before_callbacks: Sequence[Callable[[Self], None]] = ...,
43
43
  after_callbacks: Sequence[Callable[[Self], None]] = ...,
44
44
  ) -> Self: ...
45
+ def pre_validate(self) -> None: ...
46
+ def pre_save(self) -> None: ...
47
+ def pre_create(self) -> None: ...
48
+ def pre_update(self) -> None: ...
49
+ def pre_delete(self) -> None: ...
50
+ def post_validate(self) -> None: ...
51
+ def post_save(self) -> None: ...
52
+ def post_create(self) -> None: ...
53
+ def post_update(self) -> None: ...
54
+ def post_delete(self) -> None: ...
55
+ def pre_apply(self) -> None: ...
56
+ def post_apply(self) -> None: ...
45
57
  @property
46
58
  def identity(self) -> Any: ...
47
59
  ...
appier/test/smtp.py CHANGED
@@ -43,14 +43,11 @@ class SMTPTest(unittest.TestCase):
43
43
  mime["To"] = ", ".join([address_mime])
44
44
 
45
45
  result = mime.as_string()
46
- self.assertEqual(
47
- result,
48
- 'Content-Type: text/plain; charset="utf-8"\n\
46
+ self.assertEqual(result, 'Content-Type: text/plain; charset="utf-8"\n\
49
47
  MIME-Version: 1.0\n\
50
48
  Content-Transfer-Encoding: base64\n\
51
49
  Subject: Hello World\n\
52
50
  From: =?utf-8?q?Jo=C3=A3o_Magalh=C3=A3es?= <joamag@hive.pt>\n\
53
51
  To: =?utf-8?q?Jo=C3=A3o_Magalh=C3=A3es?= <joamag@hive.pt>\n\
54
52
  \n\
55
- SGVsbG8gV29ybGQ=\n',
56
- )
53
+ SGVsbG8gV29ybGQ=\n')
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: appier
3
- Version: 1.35.0
3
+ Version: 1.35.1
4
4
  Summary: Appier Framework
5
5
  Home-page: http://appier.hive.pt
6
6
  Author: Hive Solutions Lda.
@@ -3,7 +3,7 @@ appier/amqp.py,sha256=etYxUlfaK27Og_9FJ6qCgNLSYhnz9XgVhIhSmD2ITW4,3852
3
3
  appier/amqp.pyi,sha256=vTsGOj0IjsRiRxdKfIAg4hTu2kHwPosZT24HlEIZfQ8,377
4
4
  appier/api.py,sha256=ZWRdjrEEUvCDcW_pp2BDgGCdNnS7tjdaZSzUfzSRzmQ,14778
5
5
  appier/api.pyi,sha256=iStUeSkn1zwt8OHfVEeasWRmp_OjB897LuXRI_abR4g,4934
6
- appier/asgi.py,sha256=Gubv7W8aLeLhaBxInE2Gc7Y2rxacbSlglAaKj25T6NY,12622
6
+ appier/asgi.py,sha256=cjC3OUJ4XB3LzTdoJcM6aHvi-VpPQ2kjLwJOYL9YgMA,12959
7
7
  appier/asgi.pyi,sha256=PAbTl3yez12xz9p7VWzkjAn3doq6-DOZaQ9hdB6F32U,2641
8
8
  appier/async_neo.py,sha256=CqeVtKczXt3SZPvi0BYLujVTeN4i-sT8P1_0JPR5aiI,5448
9
9
  appier/async_old.py,sha256=83YuTmoZkLIeyNHLZusCXqxB_6onRmYdKJ-Sqd1Yi1E,9195
@@ -33,14 +33,14 @@ appier/extra_neo.py,sha256=oI8qsjhA7tLieR1fSl67e2lAxDXkaD3xT4nkjvVFDz0,2342
33
33
  appier/extra_old.py,sha256=5mwfHIrz6Um7-QpXiqnEm_lXXpWhNvnMgPWIFVegItU,1991
34
34
  appier/geo.py,sha256=5XzHFCwfUBNFe7rkvPKWV9LWswcbfMn9tPS1q_Twk0s,5178
35
35
  appier/git.py,sha256=-neM2mxqlyiCNu17CpLyiz3RN7Ti6LtAx5L1tipxAGA,9785
36
- appier/graph.py,sha256=jSgu-ookILujLm4ivW14SymVmuI1nbjbVZMgRS2ehOg,4054
36
+ appier/graph.py,sha256=9NdjTmlkUf6HbigBNB5ZvVKY2X7kafHhB8EXq7Xx-dM,4052
37
37
  appier/http.py,sha256=Ed-NL-VUGBCZtzIWMNZI0Z1iJ-lMbjLkF0WeH7nICdI,37662
38
38
  appier/legacy.py,sha256=o_oJ_2lqZELZKwkvfGt0aDam6ZSZiZiL7FYygNjrDbY,15881
39
39
  appier/log.py,sha256=jhV7ub5nZwrLzY7x-tZDJfb8tcsXu-ndWxxrCspBUdU,12825
40
40
  appier/meta.py,sha256=rgBLOjD6QU9CGYsbCQS3Fy4iY14uk1-Kd8ljkfmxxzc,7168
41
41
  appier/mock.py,sha256=WoWa67rb8qV_ogToQJCdT0R-rCw9RUY24EkA4bYR1G4,5800
42
42
  appier/model.py,sha256=0V_91vft3fMAFm5KzFILb-gdpoDqX6g66UGXxMYf_Jo,123021
43
- appier/model.pyi,sha256=prhI4tdSILryvLbDC65s4LwAt-LbkBtaTN5ltsotlOw,1897
43
+ appier/model.pyi,sha256=m6qpkKge8MfyZLHHng0oM0VszO1XJTdy9_UgSpBfSAE,2369
44
44
  appier/model_a.py,sha256=c6XpG4oIelXNDK0uicsZ69-f6isUgmh5-29F61PZt9c,16176
45
45
  appier/mongo.py,sha256=rU3lRroXij6x17aKFBAbuiu8Cu2xOIP-DbDtI59Ln44,11535
46
46
  appier/observer.py,sha256=T0QpkxdkcNuEOZJdmJT5nFSJ2e-0VPbGveX5YKtt7mA,4519
@@ -94,15 +94,15 @@ appier/test/request.py,sha256=h3DdvhEMARpYTp7eRcJ3-qLQyG-a8PHqSnWY52BiOeU,8176
94
94
  appier/test/scheduler.py,sha256=j-0byKZZfD36EenJg8kVm55plZ5p1lTLz9GsOT0FDxE,8384
95
95
  appier/test/serialize.py,sha256=roX01n86AQfnPxzPVdIjdIUQWC_x0C_HE3hNgF37ci8,2120
96
96
  appier/test/session.py,sha256=KdiYLLB5autIEu1sHwOuYJXVd0y6RMPgg0ITBuRTMfA,4419
97
- appier/test/smtp.py,sha256=XJNa0ZTmabdrX8MfVMgcqBxabvBfHgIimvozdziP4_E,1826
97
+ appier/test/smtp.py,sha256=xFFbtkxrIu97ChbKA5jRC1wmei2o2GdyLpg3r_nsnHs,1788
98
98
  appier/test/storage.py,sha256=GTrs-uo9-FyXbY_DC1gIKjRYi6y5ES0-q8XE1X13mUM,8932
99
99
  appier/test/structures.py,sha256=MRjUFRlnJi-i7YGWW5y792JbJwicNvOIzVAS220tgeQ,8367
100
100
  appier/test/tags.py,sha256=uf52pCsZL4-yp7i3Tk7F9T6aN4uYvYxbwcUUo-b7-0E,3861
101
101
  appier/test/typesf.py,sha256=KHumQFzx7wPZSCb8_mpIwobhIy2Fh_0XYviwPjXMbKI,9680
102
102
  appier/test/util.py,sha256=vfnleU3BUaqMs1mrpXjKom3V_zFOzrsjhmQ8sYp1GaQ,46668
103
103
  appier/test/validation.py,sha256=riOCsGKob1P5jnbcB5qGZ45ApimNAVS0byg9v_uUdrk,4952
104
- appier-1.35.0.dist-info/LICENSE,sha256=Pd-b5cKP4n2tFDpdx27qJSIq0d1ok0oEcGTlbtL6QMU,11560
105
- appier-1.35.0.dist-info/METADATA,sha256=EYoQXOc-YXg6Sfb3TqFxsIYBGffIxLf5aWJbXHXVlxE,1920
106
- appier-1.35.0.dist-info/WHEEL,sha256=kGT74LWyRUZrL4VgLh6_g12IeVl_9u9ZVhadrgXZUEY,110
107
- appier-1.35.0.dist-info/top_level.txt,sha256=Z2e_Y1ya06a554WwQZkfNRiaaQxqsdaPtBzrck384Lo,7
108
- appier-1.35.0.dist-info/RECORD,,
104
+ appier-1.35.1.dist-info/LICENSE,sha256=Pd-b5cKP4n2tFDpdx27qJSIq0d1ok0oEcGTlbtL6QMU,11560
105
+ appier-1.35.1.dist-info/METADATA,sha256=Cd_g6pvs3QMSs3j2H35WjGeLwpc-m8F09jGh_C4Awkc,1920
106
+ appier-1.35.1.dist-info/WHEEL,sha256=kGT74LWyRUZrL4VgLh6_g12IeVl_9u9ZVhadrgXZUEY,110
107
+ appier-1.35.1.dist-info/top_level.txt,sha256=Z2e_Y1ya06a554WwQZkfNRiaaQxqsdaPtBzrck384Lo,7
108
+ appier-1.35.1.dist-info/RECORD,,