daktari 0.0.224__tar.gz → 0.0.225__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.

Potentially problematic release.


This version of daktari might be problematic. Click here for more details.

Files changed (73) hide show
  1. {daktari-0.0.224/daktari.egg-info → daktari-0.0.225}/PKG-INFO +2 -2
  2. {daktari-0.0.224 → daktari-0.0.225}/README.md +1 -1
  3. daktari-0.0.225/daktari/__init__.py +1 -0
  4. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/intellij_idea.py +28 -1
  5. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/test_intellij_idea.py +26 -1
  6. {daktari-0.0.224 → daktari-0.0.225/daktari.egg-info}/PKG-INFO +2 -2
  7. {daktari-0.0.224 → daktari-0.0.225}/setup.py +1 -1
  8. daktari-0.0.224/daktari/__init__.py +0 -1
  9. {daktari-0.0.224 → daktari-0.0.225}/LICENSE.txt +0 -0
  10. {daktari-0.0.224 → daktari-0.0.225}/MANIFEST.in +0 -0
  11. {daktari-0.0.224 → daktari-0.0.225}/daktari/__main__.py +0 -0
  12. {daktari-0.0.224 → daktari-0.0.225}/daktari/asdf.py +0 -0
  13. {daktari-0.0.224 → daktari-0.0.225}/daktari/check.py +0 -0
  14. {daktari-0.0.224 → daktari-0.0.225}/daktari/check_runner.py +0 -0
  15. {daktari-0.0.224 → daktari-0.0.225}/daktari/check_sorter.py +0 -0
  16. {daktari-0.0.224 → daktari-0.0.225}/daktari/check_utils.py +0 -0
  17. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/__init__.py +0 -0
  18. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/android.py +0 -0
  19. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/aws.py +0 -0
  20. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/certs.py +0 -0
  21. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/conan.py +0 -0
  22. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/direnv.py +0 -0
  23. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/docker.py +0 -0
  24. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/files.py +0 -0
  25. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/flutter.py +0 -0
  26. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/git.py +0 -0
  27. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/google.py +0 -0
  28. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/java.py +0 -0
  29. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/kubernetes.py +0 -0
  30. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/misc.py +0 -0
  31. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/nodejs.py +0 -0
  32. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/onepassword.py +0 -0
  33. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/python.py +0 -0
  34. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/ssh.py +0 -0
  35. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/terraform.py +0 -0
  36. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/test_certs.py +0 -0
  37. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/test_java.py +0 -0
  38. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/test_misc.py +0 -0
  39. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/test_onepassword.py +0 -0
  40. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/test_ssh.py +0 -0
  41. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/test_yarn.py +0 -0
  42. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/xml.py +0 -0
  43. {daktari-0.0.224 → daktari-0.0.225}/daktari/checks/yarn.py +0 -0
  44. {daktari-0.0.224 → daktari-0.0.225}/daktari/collection_utils.py +0 -0
  45. {daktari-0.0.224 → daktari-0.0.225}/daktari/command_utils.py +0 -0
  46. {daktari-0.0.224 → daktari-0.0.225}/daktari/config.py +0 -0
  47. {daktari-0.0.224 → daktari-0.0.225}/daktari/file_utils.py +0 -0
  48. {daktari-0.0.224 → daktari-0.0.225}/daktari/options.py +0 -0
  49. {daktari-0.0.224 → daktari-0.0.225}/daktari/os.py +0 -0
  50. {daktari-0.0.224 → daktari-0.0.225}/daktari/resource_utils.py +0 -0
  51. {daktari-0.0.224 → daktari-0.0.225}/daktari/resources/__init__.py +0 -0
  52. {daktari-0.0.224 → daktari-0.0.225}/daktari/resources/daktari-local-template.yaml +0 -0
  53. {daktari-0.0.224 → daktari-0.0.225}/daktari/resources/mock_cert.pem +0 -0
  54. {daktari-0.0.224 → daktari-0.0.225}/daktari/result_printer.py +0 -0
  55. {daktari-0.0.224 → daktari-0.0.225}/daktari/test_asdf.py +0 -0
  56. {daktari-0.0.224 → daktari-0.0.225}/daktari/test_check.py +0 -0
  57. {daktari-0.0.224 → daktari-0.0.225}/daktari/test_check_factory.py +0 -0
  58. {daktari-0.0.224 → daktari-0.0.225}/daktari/test_check_runner.py +0 -0
  59. {daktari-0.0.224 → daktari-0.0.225}/daktari/test_check_sorter.py +0 -0
  60. {daktari-0.0.224 → daktari-0.0.225}/daktari/test_check_utils.py +0 -0
  61. {daktari-0.0.224 → daktari-0.0.225}/daktari/test_collection_utils.py +0 -0
  62. {daktari-0.0.224 → daktari-0.0.225}/daktari/test_config.py +0 -0
  63. {daktari-0.0.224 → daktari-0.0.225}/daktari/test_result_printer.py +0 -0
  64. {daktari-0.0.224 → daktari-0.0.225}/daktari/test_version_utils.py +0 -0
  65. {daktari-0.0.224 → daktari-0.0.225}/daktari/version_utils.py +0 -0
  66. {daktari-0.0.224 → daktari-0.0.225}/daktari.egg-info/SOURCES.txt +0 -0
  67. {daktari-0.0.224 → daktari-0.0.225}/daktari.egg-info/dependency_links.txt +0 -0
  68. {daktari-0.0.224 → daktari-0.0.225}/daktari.egg-info/entry_points.txt +0 -0
  69. {daktari-0.0.224 → daktari-0.0.225}/daktari.egg-info/requires.txt +0 -0
  70. {daktari-0.0.224 → daktari-0.0.225}/daktari.egg-info/top_level.txt +0 -0
  71. {daktari-0.0.224 → daktari-0.0.225}/pyproject.toml +0 -0
  72. {daktari-0.0.224 → daktari-0.0.225}/requirements.txt +0 -0
  73. {daktari-0.0.224 → daktari-0.0.225}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: daktari
3
- Version: 0.0.224
3
+ Version: 0.0.225
4
4
  Summary: Assist in setting up and maintaining developer environments
5
5
  Home-page: https://github.com/sonocent/daktari
6
6
  Author: Matt Russell
@@ -22,7 +22,7 @@ In the root of the project repository, create a `.daktari.py` configuration file
22
22
  ```python
23
23
  from daktari.checks.git import *
24
24
 
25
- version = "0.0.224"
25
+ version = "0.0.225"
26
26
  title = "My Project"
27
27
 
28
28
  checks = [
@@ -7,7 +7,7 @@ In the root of the project repository, create a `.daktari.py` configuration file
7
7
  ```python
8
8
  from daktari.checks.git import *
9
9
 
10
- version = "0.0.224"
10
+ version = "0.0.225"
11
11
  title = "My Project"
12
12
 
13
13
  checks = [
@@ -0,0 +1 @@
1
+ __version__ = "0.0.225"
@@ -1,6 +1,6 @@
1
1
  import json
2
2
  import logging
3
- import os.path
3
+ import os
4
4
  from json.decoder import JSONDecodeError
5
5
  from pathlib import Path
6
6
  from typing import Optional
@@ -186,6 +186,33 @@ class IntelliJNodePackageManagerConfigured(XmlFileXPathCheck):
186
186
  return current_package_manager.__contains__(self.package_manager_path)
187
187
 
188
188
 
189
+ class IntelliJTypescriptCompilerPathConfigured(XmlFileXPathCheck):
190
+ name = "intellij.typescriptCompilerPathConfigured"
191
+ file_path = ".idea/compiler.xml"
192
+ xpath_query = "./component[@name='TypeScriptCompiler']/option[@name='typeScriptServiceDirectory']"
193
+ depends_on = [IntelliJProjectImported]
194
+
195
+ def __init__(self, typescript_compiler_path: str):
196
+ self.typescript_compiler_path = typescript_compiler_path
197
+ resolved_path = typescript_compiler_path.replace("$PROJECT_DIR$", os.getcwd())
198
+ self.pass_fail_message = f"IntelliJ typescript compiler path has <not/> been set to {resolved_path}"
199
+
200
+ self.suggestions = {
201
+ OS.GENERIC: f"""
202
+ Follow the steps to set {resolved_path} as your typescript compiler path:
203
+ https://www.jetbrains.com/help/idea/typescript-support.html#ws_ts_use_ts_service_checkbox
204
+ """
205
+ }
206
+
207
+ def validate_query_result(self, result):
208
+ if result is None:
209
+ self.pass_fail_message = "IntelliJ typescript compiler path is <not/> set"
210
+ return False
211
+ current_typescript_compiler_path = result.get("value")
212
+ logging.debug(f"IntelliJ typescript compiler set to: {current_typescript_compiler_path}")
213
+ return current_typescript_compiler_path == self.typescript_compiler_path
214
+
215
+
189
216
  class IntelliJProjectSdkJavaVersion(XmlFileXPathCheck):
190
217
  name = "intellij.jdkVersionConfigured"
191
218
  file_path = ".idea/misc.xml"
@@ -3,7 +3,11 @@ import unittest
3
3
  from semver import VersionInfo
4
4
 
5
5
  from daktari.check import CheckStatus
6
- from daktari.checks.intellij_idea import IntelliJProjectSdkJavaVersion, get_intellij_version_from_product_info
6
+ from daktari.checks.intellij_idea import (
7
+ IntelliJProjectSdkJavaVersion,
8
+ get_intellij_version_from_product_info,
9
+ IntelliJTypescriptCompilerPathConfigured,
10
+ )
7
11
 
8
12
 
9
13
  class TestIntellijIdea(unittest.TestCase):
@@ -39,3 +43,24 @@ class TestIntellijIdea(unittest.TestCase):
39
43
  result = check.check()
40
44
  self.assertEqual(result.status, CheckStatus.PASS)
41
45
  self.assertEqual(result.summary, "IntelliJ Project SDK is set to Java 17: JDK_17")
46
+
47
+ def test_project_typescript_path_unset(self):
48
+ check = IntelliJTypescriptCompilerPathConfigured("$PROJECT_DIR$/node_modules/typescript")
49
+ check.file_path = "checks/test_resources/intellij_misc_no_ts_path.xml"
50
+ result = check.check()
51
+ self.assertEqual(result.status, CheckStatus.FAIL)
52
+ self.assertIn("IntelliJ typescript compiler path is not set", result.summary)
53
+
54
+ def test_project_typescript_path_set_wrong(self):
55
+ check = IntelliJTypescriptCompilerPathConfigured("/some/project/node_modules/typescript")
56
+ check.file_path = "checks/test_resources/intellij_misc_custom_ts_path.xml"
57
+ result = check.check()
58
+ self.assertEqual(result.status, CheckStatus.FAIL)
59
+ self.assertIn("IntelliJ typescript compiler path has not been set to", result.summary)
60
+
61
+ def test_project_typescript_path_set_correctly(self):
62
+ check = IntelliJTypescriptCompilerPathConfigured("$PROJECT_DIR$/node_modules/typescript")
63
+ check.file_path = "checks/test_resources/intellij_misc_custom_ts_path.xml"
64
+ result = check.check()
65
+ self.assertEqual(result.status, CheckStatus.PASS)
66
+ self.assertIn("IntelliJ typescript compiler path has been set to", result.summary)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: daktari
3
- Version: 0.0.224
3
+ Version: 0.0.225
4
4
  Summary: Assist in setting up and maintaining developer environments
5
5
  Home-page: https://github.com/sonocent/daktari
6
6
  Author: Matt Russell
@@ -22,7 +22,7 @@ In the root of the project repository, create a `.daktari.py` configuration file
22
22
  ```python
23
23
  from daktari.checks.git import *
24
24
 
25
- version = "0.0.224"
25
+ version = "0.0.225"
26
26
  title = "My Project"
27
27
 
28
28
  checks = [
@@ -10,7 +10,7 @@ README = (HERE / "README.md").read_text()
10
10
 
11
11
  setuptools.setup(
12
12
  name="daktari",
13
- version="0.0.224",
13
+ version="0.0.225",
14
14
  description="Assist in setting up and maintaining developer environments",
15
15
  long_description=README,
16
16
  long_description_content_type="text/markdown",
@@ -1 +0,0 @@
1
- __version__ = "0.0.224"
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