dothttp-req 0.0.44a21__tar.gz → 0.0.44a22__tar.gz
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.
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/PKG-INFO +2 -2
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/handlers/basic_handlers.py +1 -1
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/parse/__init__.py +5 -5
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/utils/property_util.py +11 -3
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/pyproject.toml +2 -2
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/LICENSE.txt +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/README.md +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/__init__.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/__init__.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/__main__.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/agent.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/handlers/__init__.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/handlers/fs_handlers.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/handlers/gohandler.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/handlers/har2httphandler.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/handlers/http2har.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/handlers/http2postman.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/handlers/postman2http.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/models/__init__.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/models/har.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/postman/__init__.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/postman2_1/__init__.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/server.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/utils.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/version/__init__.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/version/__main__.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/__init__.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/__main__.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/__version__.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/auth/__init__.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/auth/azure_auth.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/exceptions.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/http.tx +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/models/__init__.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/models/computed.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/models/parse_models.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/parse/dsl_jsonparser.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/parse/expression.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/parse/request_base.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/postScript.js +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/property_schema.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/script/__init__.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/script/js3py.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/utils/__init__.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/utils/common.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/utils/constants.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/utils/curl_utils.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/utils/json_utils.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp/utils/log_utils.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp_test/__init__.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp_test/__main__.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp_test/conftest.py +0 -0
- {dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dothttp_test/dothttp_test.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: dothttp-req
|
|
3
|
-
Version: 0.0.
|
|
3
|
+
Version: 0.0.44a22
|
|
4
4
|
Summary: Dothttp is Simple http client for testing and development
|
|
5
5
|
License: MIT
|
|
6
6
|
Author: Prasanth
|
|
@@ -28,7 +28,7 @@ Requires-Dist: requests-hawk (==1.2.1)
|
|
|
28
28
|
Requires-Dist: requests-ntlm (==1.3.0)
|
|
29
29
|
Requires-Dist: requests-pkcs12 (==1.25)
|
|
30
30
|
Requires-Dist: restrictedpython (==7.4)
|
|
31
|
-
Requires-Dist: textx (==4.
|
|
31
|
+
Requires-Dist: textx (==4.2.2)
|
|
32
32
|
Requires-Dist: toml (==0.10.2)
|
|
33
33
|
Requires-Dist: xmltodict (>=0.14.2,<0.15.0)
|
|
34
34
|
Project-URL: Bug Tracker, https://github.com/cedric05/dothttp
|
{dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/handlers/basic_handlers.py
RENAMED
|
@@ -242,7 +242,7 @@ class ContentBase(BaseModelProcessor):
|
|
|
242
242
|
# if model is generated, try to figure out target
|
|
243
243
|
model: MultidefHttp = dothttp_model.model_from_str(context)
|
|
244
244
|
# by including targets in to model
|
|
245
|
-
self.load_properties_from_var(model, self.property_util)
|
|
245
|
+
self.load_properties_from_var(model, self.property_util, can_override=False)
|
|
246
246
|
self.model.allhttps = self.model.allhttps + model.allhttps
|
|
247
247
|
if model.import_list and model.import_list.filename:
|
|
248
248
|
if self.model.import_list and self.model.import_list.filename:
|
|
@@ -362,13 +362,13 @@ class BaseModelProcessor:
|
|
|
362
362
|
property_util.add_infile_properties(content)
|
|
363
363
|
|
|
364
364
|
@staticmethod
|
|
365
|
-
def load_properties_from_var(model:MultidefHttp, property_util: PropertyProvider):
|
|
365
|
+
def load_properties_from_var(model:MultidefHttp, property_util: PropertyProvider, can_override: bool = True):
|
|
366
366
|
## this has to taken care by property util
|
|
367
367
|
## but it will complicate the code
|
|
368
368
|
for variable in model.variables:
|
|
369
369
|
if variable.value:
|
|
370
370
|
var_value = jsonmodel_to_json(variable.value, property_util=property_util)
|
|
371
|
-
property_util.add_infile_property_from_var(variable.name, var_value)
|
|
371
|
+
property_util.add_infile_property_from_var(variable.name, var_value, can_override)
|
|
372
372
|
elif variable.func:
|
|
373
373
|
func_name = f"${variable.func.name}"
|
|
374
374
|
if func_name in property_util.rand_map:
|
|
@@ -380,10 +380,10 @@ class BaseModelProcessor:
|
|
|
380
380
|
var_value = func()
|
|
381
381
|
else:
|
|
382
382
|
var_value = variable.func.name
|
|
383
|
-
property_util.add_infile_property_from_var(variable.name, var_value)
|
|
383
|
+
property_util.add_infile_property_from_var(variable.name, var_value, can_override)
|
|
384
384
|
elif variable.inter:
|
|
385
385
|
var_value = variable.inter[2:-1].format_map(StringFormatPropertyResolver(property_util))
|
|
386
|
-
property_util.add_infile_property_from_var(variable.name, var_value)
|
|
386
|
+
property_util.add_infile_property_from_var(variable.name, var_value, can_override)
|
|
387
387
|
elif index_sub := variable.index:
|
|
388
388
|
# index operation applied on target
|
|
389
389
|
indexed_value = property_util.resolve_property_object(index_sub.target)
|
|
@@ -406,7 +406,7 @@ class BaseModelProcessor:
|
|
|
406
406
|
indexed_value = indexed_value[evaulated_key]
|
|
407
407
|
continue
|
|
408
408
|
raise VariableIndexNotAvailable(actual_key=evaulated_key, indexed_value=indexed_value, target=index_sub.target)
|
|
409
|
-
property_util.add_infile_property_from_var(variable.name, indexed_value)
|
|
409
|
+
property_util.add_infile_property_from_var(variable.name, indexed_value, can_override)
|
|
410
410
|
|
|
411
411
|
|
|
412
412
|
|
|
@@ -340,9 +340,17 @@ class PropertyProvider:
|
|
|
340
340
|
match = PropertyProvider.random_string_regex.match(prop)
|
|
341
341
|
return match
|
|
342
342
|
|
|
343
|
-
def add_infile_property_from_var(self, key, value):
|
|
344
|
-
|
|
345
|
-
|
|
343
|
+
def add_infile_property_from_var(self, key, value, can_override: bool = True):
|
|
344
|
+
"""
|
|
345
|
+
Adds a property from a variable to infile_properties.
|
|
346
|
+
If can_override is True, the property will always be added/updated.
|
|
347
|
+
If can_override is False, the property will only be added if it doesn't exist
|
|
348
|
+
or its value is None.
|
|
349
|
+
"""
|
|
350
|
+
if can_override or (
|
|
351
|
+
key not in self.infile_properties or self.infile_properties[key].value is None
|
|
352
|
+
):
|
|
353
|
+
self.infile_properties[key] = Property([''], key, value)
|
|
346
354
|
|
|
347
355
|
def resolve_system_command_prop(self, key):
|
|
348
356
|
command = self.system_command_properties.get(key)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[tool.poetry]
|
|
2
2
|
name = "dothttp-req"
|
|
3
|
-
version = "0.0.
|
|
3
|
+
version = "0.0.44a22"
|
|
4
4
|
description = "Dothttp is Simple http client for testing and development"
|
|
5
5
|
authors = ["Prasanth <kesavarapu.siva@gmail.com>"]
|
|
6
6
|
license = "MIT"
|
|
@@ -24,7 +24,7 @@ dothttp = 'dothttp.__main__:main'
|
|
|
24
24
|
python = ">=3.8,<3.14"
|
|
25
25
|
jsonschema = "4.23.0"
|
|
26
26
|
jstyleson = "0.0.2"
|
|
27
|
-
textx = "4.
|
|
27
|
+
textx = "4.2.2"
|
|
28
28
|
requests-pkcs12 = "1.25"
|
|
29
29
|
parsys-requests-unixsocket = "0.3.2"
|
|
30
30
|
requests-aws4auth = "1.3.1"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/handlers/fs_handlers.py
RENAMED
|
File without changes
|
|
File without changes
|
{dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/handlers/har2httphandler.py
RENAMED
|
File without changes
|
|
File without changes
|
{dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/handlers/http2postman.py
RENAMED
|
File without changes
|
{dothttp_req-0.0.44a21 → dothttp_req-0.0.44a22}/dotextensions/server/handlers/postman2http.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|