inmanta-module-std 8.3.2__tar.gz → 8.4.0__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.
Files changed (29) hide show
  1. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/PKG-INFO +1 -1
  2. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/inmanta_module_std.egg-info/PKG-INFO +1 -1
  3. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/inmanta_plugins/std/__init__.py +7 -2
  4. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/inmanta_plugins/std/setup.cfg +1 -1
  5. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/setup.cfg +1 -1
  6. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/tests/test_reference.py +3 -0
  7. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/MANIFEST.in +0 -0
  8. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/README.md +0 -0
  9. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/inmanta_module_std.egg-info/SOURCES.txt +0 -0
  10. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/inmanta_module_std.egg-info/dependency_links.txt +0 -0
  11. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/inmanta_module_std.egg-info/not-zip-safe +0 -0
  12. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/inmanta_module_std.egg-info/requires.txt +0 -0
  13. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/inmanta_module_std.egg-info/top_level.txt +0 -0
  14. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/inmanta_plugins/std/model/_init.cf +0 -0
  15. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/inmanta_plugins/std/model/testing.cf +0 -0
  16. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/inmanta_plugins/std/resources.py +0 -0
  17. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/inmanta_plugins/std/templates/host_uri.j2 +0 -0
  18. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/inmanta_plugins/std/types.py +0 -0
  19. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/pyproject.toml +0 -0
  20. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/tests/test_agent.py +0 -0
  21. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/tests/test_agentconfig.py +0 -0
  22. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/tests/test_get_attribute.py +0 -0
  23. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/tests/test_mutables.py +0 -0
  24. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/tests/test_plugins.py +0 -0
  25. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/tests/test_resource.py +0 -0
  26. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/tests/test_template.py +0 -0
  27. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/tests/test_types.py +0 -0
  28. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/tests/test_unknown.py +0 -0
  29. {inmanta_module_std-8.3.2 → inmanta_module_std-8.4.0}/tests/test_warnings.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: inmanta-module-std
3
- Version: 8.3.2
3
+ Version: 8.4.0
4
4
  License: Apache 2.0
5
5
  Requires-Dist: Jinja2<4,>=3.1
6
6
  Requires-Dist: email_validator<3,>=1.3
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: inmanta-module-std
3
- Version: 8.3.2
3
+ Version: 8.4.0
4
4
  License: Apache 2.0
5
5
  Requires-Dist: Jinja2<4,>=3.1
6
6
  Requires-Dist: email_validator<3,>=1.3
@@ -777,8 +777,6 @@ def getfact(
777
777
  """
778
778
  Retrieve a fact of the given resource
779
779
  """
780
- global fact_cache
781
-
782
780
  resource_id = inmanta.resources.to_id(resource)
783
781
  if resource_id is None:
784
782
  raise Exception("Facts can only be retreived from resources.")
@@ -1352,6 +1350,13 @@ try:
1352
1350
  raise LookupError(f"Environment variable {env_var_name} is not set")
1353
1351
  return value
1354
1352
 
1353
+ def __eq__(self, value: object) -> bool:
1354
+ match value:
1355
+ case EnvironmentReference():
1356
+ return self.name == value.name
1357
+ case _:
1358
+ return False
1359
+
1355
1360
  @plugin
1356
1361
  def create_environment_reference(name: str | Reference[str]) -> Reference[str]:
1357
1362
  """Create an environment reference
@@ -27,7 +27,7 @@ skip_tests = False
27
27
  name = inmanta-module-std
28
28
  freeze_recursive = False
29
29
  freeze_operator = ~=
30
- version = 8.3.2
30
+ version = 8.4.0
31
31
  license = Apache 2.0
32
32
  four_digit_version = False
33
33
 
@@ -27,7 +27,7 @@ skip_tests = False
27
27
  name = inmanta-module-std
28
28
  freeze_recursive = False
29
29
  freeze_operator = ~=
30
- version = 8.3.2
30
+ version = 8.4.0
31
31
  license = Apache 2.0
32
32
  four_digit_version = False
33
33
 
@@ -37,6 +37,9 @@ def test_references_resource(project: Project, monkeypatch) -> None:
37
37
  metavalue = std::create_environment_reference("METATESTENV")
38
38
  value = std::create_environment_reference(metavalue)
39
39
  std::testing::NullResource(agentname="test", name="aaa", value=value)
40
+
41
+ # Test that identical references are the same value for the compiler
42
+ value = std::create_environment_reference(metavalue)
40
43
  """
41
44
  )
42
45