PrEditor 0.8.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.

Potentially problematic release.


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

Files changed (195) hide show
  1. preditor-0.8.0/.coveragerc +17 -0
  2. preditor-0.8.0/.github/ISSUE_TEMPLATE/BUG_REPORT.md +45 -0
  3. preditor-0.8.0/.github/ISSUE_TEMPLATE/FEATURE_REQUEST.md +28 -0
  4. preditor-0.8.0/.github/PULL_REQUEST_TEMPLATE.md +29 -0
  5. preditor-0.8.0/.github/workflows/release.yml +48 -0
  6. preditor-0.8.0/.github/workflows/static-analysis-and-test.yml +189 -0
  7. preditor-0.8.0/.gitignore +35 -0
  8. preditor-0.8.0/.pre-commit-config.yaml +40 -0
  9. preditor-0.8.0/CODE_OF_CONDUCT.md +44 -0
  10. preditor-0.8.0/CONTRIBUTING.md +77 -0
  11. preditor-0.8.0/LICENSE +165 -0
  12. preditor-0.8.0/MANIFEST.in +3 -0
  13. preditor-0.8.0/PKG-INFO +213 -0
  14. preditor-0.8.0/PrEditor.egg-info/PKG-INFO +213 -0
  15. preditor-0.8.0/PrEditor.egg-info/SOURCES.txt +194 -0
  16. preditor-0.8.0/PrEditor.egg-info/dependency_links.txt +1 -0
  17. preditor-0.8.0/PrEditor.egg-info/entry_points.txt +18 -0
  18. preditor-0.8.0/PrEditor.egg-info/requires.txt +27 -0
  19. preditor-0.8.0/PrEditor.egg-info/top_level.txt +1 -0
  20. preditor-0.8.0/README.md +170 -0
  21. preditor-0.8.0/examples/add_to_app.py +72 -0
  22. preditor-0.8.0/examples/output_capture_and_show.py +12 -0
  23. preditor-0.8.0/preditor/__init__.py +306 -0
  24. preditor-0.8.0/preditor/__main__.py +13 -0
  25. preditor-0.8.0/preditor/about_module.py +166 -0
  26. preditor-0.8.0/preditor/cli.py +192 -0
  27. preditor-0.8.0/preditor/contexts.py +119 -0
  28. preditor-0.8.0/preditor/cores/__init__.py +0 -0
  29. preditor-0.8.0/preditor/cores/core.py +65 -0
  30. preditor-0.8.0/preditor/dccs/maya/PrEditor_maya.mod +2 -0
  31. preditor-0.8.0/preditor/dccs/maya/plug-ins/PrEditor_maya.py +108 -0
  32. preditor-0.8.0/preditor/debug.py +294 -0
  33. preditor-0.8.0/preditor/delayable_engine/__init__.py +310 -0
  34. preditor-0.8.0/preditor/delayable_engine/delayables.py +85 -0
  35. preditor-0.8.0/preditor/enum.py +728 -0
  36. preditor-0.8.0/preditor/gui/__init__.py +84 -0
  37. preditor-0.8.0/preditor/gui/app.py +159 -0
  38. preditor-0.8.0/preditor/gui/codehighlighter.py +209 -0
  39. preditor-0.8.0/preditor/gui/completer.py +226 -0
  40. preditor-0.8.0/preditor/gui/console.py +868 -0
  41. preditor-0.8.0/preditor/gui/dialog.py +200 -0
  42. preditor-0.8.0/preditor/gui/drag_tab_bar.py +190 -0
  43. preditor-0.8.0/preditor/gui/editor_chooser.py +57 -0
  44. preditor-0.8.0/preditor/gui/errordialog.py +101 -0
  45. preditor-0.8.0/preditor/gui/find_files.py +125 -0
  46. preditor-0.8.0/preditor/gui/fuzzy_search/__init__.py +0 -0
  47. preditor-0.8.0/preditor/gui/fuzzy_search/fuzzy_search.py +93 -0
  48. preditor-0.8.0/preditor/gui/group_tab_widget/__init__.py +319 -0
  49. preditor-0.8.0/preditor/gui/group_tab_widget/grouped_tab_menu.py +35 -0
  50. preditor-0.8.0/preditor/gui/group_tab_widget/grouped_tab_models.py +108 -0
  51. preditor-0.8.0/preditor/gui/group_tab_widget/grouped_tab_widget.py +78 -0
  52. preditor-0.8.0/preditor/gui/group_tab_widget/one_tab_widget.py +54 -0
  53. preditor-0.8.0/preditor/gui/level_buttons.py +349 -0
  54. preditor-0.8.0/preditor/gui/logger_window_handler.py +46 -0
  55. preditor-0.8.0/preditor/gui/loggerwindow.py +1320 -0
  56. preditor-0.8.0/preditor/gui/newtabwidget.py +69 -0
  57. preditor-0.8.0/preditor/gui/redmine_login_dialog.py +63 -0
  58. preditor-0.8.0/preditor/gui/set_text_editor_path_dialog.py +59 -0
  59. preditor-0.8.0/preditor/gui/status_label.py +99 -0
  60. preditor-0.8.0/preditor/gui/suggest_path_quotes_dialog.py +50 -0
  61. preditor-0.8.0/preditor/gui/ui/editor_chooser.ui +93 -0
  62. preditor-0.8.0/preditor/gui/ui/errordialog.ui +81 -0
  63. preditor-0.8.0/preditor/gui/ui/find_files.ui +140 -0
  64. preditor-0.8.0/preditor/gui/ui/loggerwindow.ui +1114 -0
  65. preditor-0.8.0/preditor/gui/ui/redmine_login_dialog.ui +124 -0
  66. preditor-0.8.0/preditor/gui/ui/set_text_editor_path_dialog.ui +189 -0
  67. preditor-0.8.0/preditor/gui/ui/suggest_path_quotes_dialog.ui +225 -0
  68. preditor-0.8.0/preditor/gui/window.py +183 -0
  69. preditor-0.8.0/preditor/gui/workbox_mixin.py +389 -0
  70. preditor-0.8.0/preditor/gui/workbox_text_edit.py +137 -0
  71. preditor-0.8.0/preditor/gui/workboxwidget.py +298 -0
  72. preditor-0.8.0/preditor/logging_config.py +52 -0
  73. preditor-0.8.0/preditor/osystem.py +401 -0
  74. preditor-0.8.0/preditor/plugins.py +65 -0
  75. preditor-0.8.0/preditor/prefs.py +74 -0
  76. preditor-0.8.0/preditor/resource/environment_variables.html +26 -0
  77. preditor-0.8.0/preditor/resource/error_mail.html +85 -0
  78. preditor-0.8.0/preditor/resource/error_mail_inline.html +41 -0
  79. preditor-0.8.0/preditor/resource/img/README.md +17 -0
  80. preditor-0.8.0/preditor/resource/img/arrow_forward.png +0 -0
  81. preditor-0.8.0/preditor/resource/img/check-bold.png +0 -0
  82. preditor-0.8.0/preditor/resource/img/chevron-down.png +0 -0
  83. preditor-0.8.0/preditor/resource/img/chevron-up.png +0 -0
  84. preditor-0.8.0/preditor/resource/img/close-thick.png +0 -0
  85. preditor-0.8.0/preditor/resource/img/comment-edit.png +0 -0
  86. preditor-0.8.0/preditor/resource/img/content-copy.png +0 -0
  87. preditor-0.8.0/preditor/resource/img/content-cut.png +0 -0
  88. preditor-0.8.0/preditor/resource/img/content-duplicate.png +0 -0
  89. preditor-0.8.0/preditor/resource/img/content-paste.png +0 -0
  90. preditor-0.8.0/preditor/resource/img/content-save.png +0 -0
  91. preditor-0.8.0/preditor/resource/img/debug_disabled.png +0 -0
  92. preditor-0.8.0/preditor/resource/img/eye-check.png +0 -0
  93. preditor-0.8.0/preditor/resource/img/file-plus.png +0 -0
  94. preditor-0.8.0/preditor/resource/img/file-remove.png +0 -0
  95. preditor-0.8.0/preditor/resource/img/format-align-left.png +0 -0
  96. preditor-0.8.0/preditor/resource/img/format-letter-case-lower.png +0 -0
  97. preditor-0.8.0/preditor/resource/img/format-letter-case-upper.png +0 -0
  98. preditor-0.8.0/preditor/resource/img/format-letter-case.svg +1 -0
  99. preditor-0.8.0/preditor/resource/img/information.png +0 -0
  100. preditor-0.8.0/preditor/resource/img/logging_critical.png +0 -0
  101. preditor-0.8.0/preditor/resource/img/logging_custom.png +0 -0
  102. preditor-0.8.0/preditor/resource/img/logging_debug.png +0 -0
  103. preditor-0.8.0/preditor/resource/img/logging_error.png +0 -0
  104. preditor-0.8.0/preditor/resource/img/logging_info.png +0 -0
  105. preditor-0.8.0/preditor/resource/img/logging_not_set.png +0 -0
  106. preditor-0.8.0/preditor/resource/img/logging_warning.png +0 -0
  107. preditor-0.8.0/preditor/resource/img/marker.png +0 -0
  108. preditor-0.8.0/preditor/resource/img/play.png +0 -0
  109. preditor-0.8.0/preditor/resource/img/playlist-play.png +0 -0
  110. preditor-0.8.0/preditor/resource/img/plus-minus-variant.png +0 -0
  111. preditor-0.8.0/preditor/resource/img/preditor.ico +0 -0
  112. preditor-0.8.0/preditor/resource/img/preditor.png +0 -0
  113. preditor-0.8.0/preditor/resource/img/preditor.psd +0 -0
  114. preditor-0.8.0/preditor/resource/img/preditor.svg +44 -0
  115. preditor-0.8.0/preditor/resource/img/regex.svg +1 -0
  116. preditor-0.8.0/preditor/resource/img/restart.svg +1 -0
  117. preditor-0.8.0/preditor/resource/img/skip-forward-outline.png +0 -0
  118. preditor-0.8.0/preditor/resource/img/skip-next-outline.png +0 -0
  119. preditor-0.8.0/preditor/resource/img/skip-next.png +0 -0
  120. preditor-0.8.0/preditor/resource/img/skip-previous.png +0 -0
  121. preditor-0.8.0/preditor/resource/img/subdirectory-arrow-right.png +0 -0
  122. preditor-0.8.0/preditor/resource/img/text-search-variant.png +0 -0
  123. preditor-0.8.0/preditor/resource/img/warning-big.png +0 -0
  124. preditor-0.8.0/preditor/resource/lang/python.json +30 -0
  125. preditor-0.8.0/preditor/resource/settings.ini +25 -0
  126. preditor-0.8.0/preditor/resource/stylesheet/Bright.css +65 -0
  127. preditor-0.8.0/preditor/resource/stylesheet/Dark.css +199 -0
  128. preditor-0.8.0/preditor/scintilla/__init__.py +22 -0
  129. preditor-0.8.0/preditor/scintilla/delayables/__init__.py +11 -0
  130. preditor-0.8.0/preditor/scintilla/delayables/smart_highlight.py +94 -0
  131. preditor-0.8.0/preditor/scintilla/delayables/spell_check.py +173 -0
  132. preditor-0.8.0/preditor/scintilla/documenteditor.py +2039 -0
  133. preditor-0.8.0/preditor/scintilla/finddialog.py +68 -0
  134. preditor-0.8.0/preditor/scintilla/lang/__init__.py +80 -0
  135. preditor-0.8.0/preditor/scintilla/lang/config/bash.ini +15 -0
  136. preditor-0.8.0/preditor/scintilla/lang/config/batch.ini +14 -0
  137. preditor-0.8.0/preditor/scintilla/lang/config/cpp.ini +19 -0
  138. preditor-0.8.0/preditor/scintilla/lang/config/css.ini +19 -0
  139. preditor-0.8.0/preditor/scintilla/lang/config/eyeonscript.ini +17 -0
  140. preditor-0.8.0/preditor/scintilla/lang/config/html.ini +21 -0
  141. preditor-0.8.0/preditor/scintilla/lang/config/javascript.ini +24 -0
  142. preditor-0.8.0/preditor/scintilla/lang/config/lua.ini +16 -0
  143. preditor-0.8.0/preditor/scintilla/lang/config/maxscript.ini +20 -0
  144. preditor-0.8.0/preditor/scintilla/lang/config/mel.ini +18 -0
  145. preditor-0.8.0/preditor/scintilla/lang/config/mu.ini +22 -0
  146. preditor-0.8.0/preditor/scintilla/lang/config/nsi.ini +19 -0
  147. preditor-0.8.0/preditor/scintilla/lang/config/perl.ini +19 -0
  148. preditor-0.8.0/preditor/scintilla/lang/config/puppet.ini +19 -0
  149. preditor-0.8.0/preditor/scintilla/lang/config/python.ini +28 -0
  150. preditor-0.8.0/preditor/scintilla/lang/config/ruby.ini +19 -0
  151. preditor-0.8.0/preditor/scintilla/lang/config/sql.ini +7 -0
  152. preditor-0.8.0/preditor/scintilla/lang/config/xml.ini +21 -0
  153. preditor-0.8.0/preditor/scintilla/lang/config/yaml.ini +18 -0
  154. preditor-0.8.0/preditor/scintilla/lang/language.py +240 -0
  155. preditor-0.8.0/preditor/scintilla/lexers/__init__.py +0 -0
  156. preditor-0.8.0/preditor/scintilla/lexers/cpplexer.py +21 -0
  157. preditor-0.8.0/preditor/scintilla/lexers/javascriptlexer.py +25 -0
  158. preditor-0.8.0/preditor/scintilla/lexers/maxscriptlexer.py +234 -0
  159. preditor-0.8.0/preditor/scintilla/lexers/mellexer.py +368 -0
  160. preditor-0.8.0/preditor/scintilla/lexers/mulexer.py +32 -0
  161. preditor-0.8.0/preditor/scintilla/lexers/pythonlexer.py +41 -0
  162. preditor-0.8.0/preditor/scintilla/ui/finddialog.ui +160 -0
  163. preditor-0.8.0/preditor/settings.py +71 -0
  164. preditor-0.8.0/preditor/stream/__init__.py +80 -0
  165. preditor-0.8.0/preditor/stream/director.py +73 -0
  166. preditor-0.8.0/preditor/stream/manager.py +74 -0
  167. preditor-0.8.0/preditor/streamhandler_helper.py +46 -0
  168. preditor-0.8.0/preditor/utils/__init__.py +0 -0
  169. preditor-0.8.0/preditor/utils/cute.py +30 -0
  170. preditor-0.8.0/preditor/utils/stylesheets.py +54 -0
  171. preditor-0.8.0/preditor/utils/text_search.py +342 -0
  172. preditor-0.8.0/preditor/version.py +5 -0
  173. preditor-0.8.0/preditor/weakref.py +363 -0
  174. preditor-0.8.0/pyproject.toml +17 -0
  175. preditor-0.8.0/requirements.txt +6 -0
  176. preditor-0.8.0/setup.cfg +107 -0
  177. preditor-0.8.0/setup.py +7 -0
  178. preditor-0.8.0/tests/find_files/re_greedy_False_0_True.md +16 -0
  179. preditor-0.8.0/tests/find_files/re_greedy_False_2_True.md +25 -0
  180. preditor-0.8.0/tests/find_files/re_greedy_True_2_True.md +25 -0
  181. preditor-0.8.0/tests/find_files/re_greedy_upper_True_2_True.md +13 -0
  182. preditor-0.8.0/tests/find_files/re_simple_False_0_True.md +16 -0
  183. preditor-0.8.0/tests/find_files/re_simple_False_2_True.md +25 -0
  184. preditor-0.8.0/tests/find_files/re_simple_False_3_True.md +25 -0
  185. preditor-0.8.0/tests/find_files/re_simple_True_2_True.md +25 -0
  186. preditor-0.8.0/tests/find_files/simple_False_0_False.md +16 -0
  187. preditor-0.8.0/tests/find_files/simple_False_1_False.md +22 -0
  188. preditor-0.8.0/tests/find_files/simple_False_2_False.md +25 -0
  189. preditor-0.8.0/tests/find_files/simple_False_3_False.md +25 -0
  190. preditor-0.8.0/tests/find_files/simple_True_2_False.md +25 -0
  191. preditor-0.8.0/tests/find_files/tab_text.txt +20 -0
  192. preditor-0.8.0/tests/find_files/test_find_files.py +74 -0
  193. preditor-0.8.0/tests/ide/test_delayable_engine.py +171 -0
  194. preditor-0.8.0/tests/test_stream.py +221 -0
  195. preditor-0.8.0/tox.ini +76 -0
@@ -0,0 +1,17 @@
1
+ [report]
2
+ show_missing = false
3
+ skip_covered = true
4
+ skip_empty = true
5
+
6
+ [run]
7
+ # Ensure all python modules in preditor have their coverage reported,
8
+ # not just files that pytest touches.
9
+ source = preditor
10
+ omit =
11
+ */site-packages/*
12
+ tests/*
13
+ # This file is automatically generated by setuptools_scm
14
+ preditor/version.py
15
+ parallel=True
16
+ relative_files=True
17
+ data_file=.coverage/.coverage
@@ -0,0 +1,45 @@
1
+ ---
2
+ name: Bug Report
3
+ about: File a bug report. (Please search exisiting issues before submitting. Also see CONTRIBUTING.md.)
4
+ title: ""
5
+ labels: bug
6
+ assignees: ""
7
+ ---
8
+
9
+ ## Summary
10
+
11
+ <!--
12
+ What went wrong? What is the current behavior?
13
+ Please be as clear and concise as possible.
14
+ -->
15
+
16
+ ## Expected Behavior
17
+
18
+ <!--
19
+ What did you expect to happen?
20
+ -->
21
+
22
+ ## Steps to Reproduce Behavior
23
+
24
+ <!--
25
+ If possible, please share the steps to reproduce the issue.
26
+ If relevant, feel free to include any code that reliably reproduces the issue.
27
+ -->
28
+
29
+ ### Solution
30
+
31
+ <!--
32
+ If you have any suggestions on fixing the issue.
33
+ -->
34
+
35
+ ## Environment
36
+
37
+ - Version: <!-- [e.g. 0.1.0] -->
38
+ - OS and Python version: <!-- [e.g. Linux/Python 3.8.7] -->
39
+
40
+ ## Additional Context
41
+
42
+ <!--
43
+ Append any additional context regarding the problem here.
44
+ Screenshots are always welcome!
45
+ -->
@@ -0,0 +1,28 @@
1
+ ---
2
+ name: Feature Request
3
+ about: Suggest an idea for the project. (Please search exisiting issues before submitting. Also see CONTRIBUTING.md.)
4
+ title: ""
5
+ labels: enhancement
6
+ assignees: ""
7
+ ---
8
+
9
+
10
+ ## Description
11
+
12
+ <!--
13
+ Describe the functionality you would like to see added the project.
14
+ Please be as clear and concise as possible.
15
+ -->
16
+
17
+ ## Solution
18
+
19
+ <!--
20
+ Describe what a possible solution would look and/or act like.
21
+ -->
22
+
23
+ ## Additional Context
24
+
25
+ <!--
26
+ Append any additional context regarding the request here.
27
+ Screenshots are always welcome!
28
+ -->
@@ -0,0 +1,29 @@
1
+ ## Checklist
2
+
3
+ <!--
4
+ Place an `x` in the boxes you have addressed. You can also fill these out after creating the Pull Request. If you're unsure about any of them, don't hesitate to ask. This is simply a reminder of what we are going to look for before merging your code.
5
+ -->
6
+
7
+ - [ ] I have read the [CONTRIBUTING.md](../CONTRIBUTING.md) document
8
+ - [ ] I formatted my changes with [black](https://github.com/psf/black)
9
+ - [ ] I linted my changes with [flake8](https://github.com/PyCQA/flake8)
10
+ - [ ] I have added documentation regarding my changes where necessary
11
+ - [ ] Any pre-existing tests continue to pass
12
+ - [ ] Additional tests were made covering my changes
13
+
14
+ ## Types of Changes
15
+
16
+ <!--
17
+ Place an `x` in the box that applies.
18
+ -->
19
+
20
+ - [ ] Bugfix (change that fixes an issue)
21
+ - [ ] New Feature (change that adds functionality)
22
+ - [ ] Documentation Update (if none of the other choices apply)
23
+
24
+ ## Proposed Changes
25
+
26
+ <!--
27
+ Describe the big picture of your changes here to communicate to why this pull request has been made and should be accepted.
28
+ If it fixes a bug or resolves a feature request, please be sure to link to that issue.
29
+ -->
@@ -0,0 +1,48 @@
1
+ name: PyPi Release
2
+
3
+ on:
4
+ release:
5
+ types: [created]
6
+
7
+ jobs:
8
+
9
+ build-and-publish:
10
+ runs-on: ubuntu-latest
11
+
12
+ steps:
13
+ - name: Checkout code
14
+ uses: actions/checkout@v4
15
+ with:
16
+ fetch-depth: 0
17
+
18
+ - name: Setup Python
19
+ uses: actions/setup-python@v5
20
+ with:
21
+ python-version: "3.x"
22
+
23
+ - name: Install dependencies
24
+ run: |
25
+ python -m pip install --upgrade pip
26
+ python -m pip install --upgrade build setuptools wheel twine
27
+
28
+ - name: Build wheel
29
+ run: |
30
+ python -m build --wheel --sdist
31
+
32
+ # Upload the built pip packages so we can inspect them
33
+ - name: Upload packages.
34
+ uses: actions/upload-artifact@v4
35
+ with:
36
+ name: pip-packages
37
+ path: |
38
+ dist/preditor-*.whl
39
+ dist/preditor-*.tar.gz
40
+ # This is only used if there is a problem with the next step
41
+ retention-days: 1
42
+
43
+ - name: Publish to PyPI
44
+ env:
45
+ TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
46
+ TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
47
+ run: |
48
+ twine upload --verbose dist/*
@@ -0,0 +1,189 @@
1
+ name: Static Analysis & Test
2
+
3
+ on: [push, pull_request]
4
+
5
+ jobs:
6
+
7
+ static-analysis:
8
+ # We want to run on external PRs, but not on our own internal PRs as they'll
9
+ # be run by the push to the branch. Without this if check, checks are
10
+ # duplicated since internal PRs match both the push and pull_request events.
11
+ # https://github.com/psf/black/blob/f51e53726b39a177355a7917c91c56f390dda7ef/.github/workflows/lint.yml#L7-L12
12
+ if:
13
+ github.event_name == 'push' ||
14
+ github.event.pull_request.head.repo.full_name != github.repository
15
+
16
+ runs-on: ubuntu-latest
17
+
18
+ steps:
19
+ - name: Checkout code
20
+ uses: actions/checkout@v4
21
+
22
+ - name: Setup Python
23
+ uses: actions/setup-python@v5
24
+ with:
25
+ python-version: "3.x"
26
+
27
+ - name: Install dependencies
28
+ run: |
29
+ python -m pip install --upgrade pip
30
+ python -m pip install tox
31
+
32
+ - name: Lint with flake8
33
+ run: tox -e flake8
34
+
35
+ - name: Format with black
36
+ run: tox -e black
37
+
38
+ - name: Py 2 and 3 compatibility
39
+ run: tox -e modernize
40
+
41
+
42
+ test:
43
+ # We want to run on external PRs, but not on our own internal PRs as they'll
44
+ # be run by the push to the branch. Without this if check, checks are
45
+ # duplicated since internal PRs match both the push and pull_request events.
46
+ if:
47
+ github.event_name == 'push' ||
48
+ github.event.pull_request.head.repo.full_name != github.repository
49
+
50
+ strategy:
51
+ matrix:
52
+ os: ['ubuntu-latest']
53
+ python: ['3.8', '3.9', '3.10', '3.11']
54
+ # Works around the depreciation of python 3.6, 3.7 for ubuntu
55
+ # https://github.com/actions/setup-python/issues/544
56
+ include:
57
+ - os: 'ubuntu-22.04'
58
+ python: '3.7'
59
+
60
+ runs-on: ${{ matrix.os }}
61
+
62
+ steps:
63
+ - name: Checkout code
64
+ uses: actions/checkout@v4
65
+
66
+ - name: Setup Python
67
+ uses: actions/setup-python@v5
68
+ with:
69
+ python-version: ${{ matrix.python }}
70
+
71
+ - name: Install dependencies
72
+ run: |
73
+ python -m pip install --upgrade pip
74
+ python -m pip install tox
75
+
76
+ - name: Run Tox
77
+ run: |
78
+ tox -e begin,py -- --tb short
79
+
80
+ - name: Upload coverage
81
+ uses: actions/upload-artifact@v4
82
+ with:
83
+ name: coverage-${{ matrix.os }}-${{ matrix.python }}
84
+ path: .coverage/*
85
+ include-hidden-files: true
86
+ retention-days: 1
87
+
88
+
89
+ coverage:
90
+ # We want to run on external PRs, but not on our own internal PRs as they'll
91
+ # be run by the push to the branch. Without this if check, checks are
92
+ # duplicated since internal PRs match both the push and pull_request events.
93
+ if:
94
+ github.event_name == 'push' ||
95
+ github.event.pull_request.head.repo.full_name != github.repository
96
+
97
+ needs: test
98
+
99
+ runs-on: ubuntu-latest
100
+ steps:
101
+ - name: Checkout code
102
+ uses: actions/checkout@v4
103
+
104
+ - name: Setup Python
105
+ uses: actions/setup-python@v5
106
+ with:
107
+ python-version: "3.x"
108
+
109
+ - name: Install dependencies
110
+ run: |
111
+ python -m pip install --upgrade pip
112
+ python -m pip install tox coverage[toml]
113
+
114
+ # Ensure version.py is created so coverage can read it's source
115
+ - name: Run begin
116
+ run: |
117
+ tox -e begin
118
+
119
+ - name: Download coverage artifacts
120
+ uses: actions/download-artifact@v4
121
+ with:
122
+ path: .coverage/
123
+ pattern: coverage-*
124
+ merge-multiple: true
125
+
126
+ # Tox runs `coverage combine` and `coverage xml`
127
+ - name: Combine coverage and report
128
+ run: |
129
+ tox -e end
130
+
131
+ # Report and write to summary.
132
+ python -m coverage report --format=markdown >> $GITHUB_STEP_SUMMARY
133
+
134
+ # Write html coverage report to upload as an artifact
135
+ python -m coverage html
136
+
137
+ # # Report again and fail if under 100%.
138
+ # python -m coverage report --fail-under=100
139
+
140
+ - name: Upload HTML report if check failed.
141
+ uses: actions/upload-artifact@v4
142
+ with:
143
+ name: html-report
144
+ path: htmlcov
145
+ # # TODO: If we get 100% coverage we can re-enable this and the
146
+ # # `--fail-under` check so pull requests fail if the dev doesn't
147
+ # # add tests for new code.
148
+ # if: ${{ failure() }}
149
+
150
+
151
+ pip-package:
152
+ # We want to run on external PRs, but not on our own internal PRs as they'll
153
+ # be run by the push to the branch. Without this if check, checks are
154
+ # duplicated since internal PRs match both the push and pull_request events.
155
+ if:
156
+ github.event_name == 'push' ||
157
+ github.event.pull_request.head.repo.full_name != github.repository
158
+
159
+ # Build and upload pip packages as artifacts so we can inspect them and
160
+ # ensure they are correct for actual release
161
+ runs-on: ubuntu-latest
162
+
163
+ steps:
164
+ - name: Checkout code
165
+ uses: actions/checkout@v4
166
+ with:
167
+ fetch-depth: 0
168
+
169
+ - name: Setup Python
170
+ uses: actions/setup-python@v5
171
+ with:
172
+ python-version: "3.x"
173
+
174
+ - name: Install dependencies
175
+ run: |
176
+ python -m pip install --upgrade pip
177
+ python -m pip install --upgrade build setuptools wheel twine
178
+
179
+ - name: Build wheel
180
+ run: |
181
+ python -m build --wheel --sdist
182
+
183
+ - name: Upload packages.
184
+ uses: actions/upload-artifact@v4
185
+ with:
186
+ name: pip-packages
187
+ path: |
188
+ dist/preditor-*.whl
189
+ dist/preditor-*.tar.gz
@@ -0,0 +1,35 @@
1
+ *.pyc
2
+ *.pyo
3
+ *.rej
4
+ *.swp
5
+ .DS_Store
6
+
7
+ /.project
8
+ /.pydevproject
9
+ *.egg-info
10
+ .eggs/
11
+ /build/
12
+ /dist/
13
+ /venv/
14
+ *.sublime-*
15
+ pip-wheel-metadata
16
+
17
+ # Ignore the majority of the docs folder
18
+ /docs/*
19
+ !/docs/
20
+ /docs/source/*
21
+ !/docs/source/
22
+ !/docs/source/conf.py
23
+ !/docs/source/index.rst
24
+
25
+ # Used by the ci
26
+ .cache/
27
+ downloads/
28
+ shared-venv/
29
+ .tox/
30
+
31
+ # /preditor
32
+ /preditor/version.py
33
+
34
+ # Coverage
35
+ .coverage
@@ -0,0 +1,40 @@
1
+ ---
2
+ repos:
3
+
4
+ - repo: https://github.com/psf/black
5
+ rev: 22.12.0
6
+ hooks:
7
+ - id: black
8
+
9
+ - repo: https://github.com/PyCQA/flake8
10
+ rev: 5.0.4
11
+ hooks:
12
+ - id: flake8
13
+ additional_dependencies:
14
+ - flake8-bugbear==22.12.6
15
+ - pep8-naming==0.13.3
16
+
17
+ - repo: https://github.com/asottile/setup-cfg-fmt
18
+ rev: v2.2.0
19
+ hooks:
20
+ - id: setup-cfg-fmt
21
+ args: [--min-py3-version=3.6]
22
+
23
+ - repo: https://github.com/pre-commit/pre-commit-hooks
24
+ rev: v4.4.0
25
+ hooks:
26
+ - id: check-json
27
+ - id: check-toml
28
+ - id: check-xml
29
+ - id: check-yaml
30
+ - id: debug-statements
31
+ - id: end-of-file-fixer
32
+ - id: requirements-txt-fixer
33
+ - id: trailing-whitespace
34
+ exclude: ^(tests/find_files/)
35
+
36
+ - repo: https://github.com/pycqa/isort
37
+ rev: 5.12.0
38
+ hooks:
39
+ - id: isort
40
+ name: isort (python)
@@ -0,0 +1,44 @@
1
+ # Code of Conduct
2
+
3
+ Those who participate and/or contribute to projects maintained by Blur Studio are expected to treat one another with respect.
4
+
5
+ ## Our Pledge
6
+
7
+ In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to make participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, sex characteristics, gender identity and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, religion, or sexual identity and orientation.
8
+
9
+ ## Our Standards
10
+
11
+ Examples of behavior that contributes to creating a positive environment include:
12
+
13
+ * Using welcoming and inclusive language
14
+ * Being respectful of differing viewpoints and experiences
15
+ * Gracefully accepting constructive criticism
16
+ * Focusing on what is best for the community
17
+ * Showing empathy towards other community members
18
+
19
+ Examples of unacceptable behavior by participants include:
20
+
21
+ * The use of sexualized language or imagery and unwelcome sexual attention or advances
22
+ * Trolling, insulting/derogatory comments, and personal or political attacks
23
+ * Public or private harassment
24
+ * Publishing others' private information, such as a physical or electronic address, without explicit permission
25
+ * Other conduct which could reasonably be considered inappropriate in a professional setting
26
+
27
+ ## Our Responsibilities
28
+
29
+ Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior.
30
+ Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.
31
+
32
+ ## Scope
33
+
34
+ This Code of Conduct applies within all project spaces, and it also applies when an individual is representing the project or its community in public spaces. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers.
35
+
36
+ ## Enforcement
37
+
38
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the open source team at opensource@blur.com. All complaints will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.
39
+
40
+ Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership.
41
+
42
+ ## Attribution
43
+
44
+ This Code of Conduct is adapted from [Contributor Covenant](https://www.contributor-covenant.org).
@@ -0,0 +1,77 @@
1
+ # Contributing to Blur Projects
2
+
3
+ We at Blur are excited to contribute to the Visual Effects community by open sourcing our internal projects. We welcome others to integrate these projects into their pipelines and contribute to them as they deem fit via bug reports, feature suggestions, and pull requests.
4
+
5
+ <!-- MarkdownTOC -->
6
+
7
+ - [Code of Conduct](#code-of-conduct)
8
+ - [How to Contribute](#how-to-contribute)
9
+ - [Reporting Issues / Bugs](#reporting-issues--bugs)
10
+ - [Suggesting a Feature](#suggesting-a-feature)
11
+ - [Submitting a Pull Request](#submitting-a-pull-request)
12
+ - [Coding Style & Formatting](#coding-style--formatting)
13
+ - [Creating a Release](#creating-a-release)
14
+
15
+ <!-- /MarkdownTOC -->
16
+
17
+ ## Code of Conduct
18
+
19
+ Before contributing we recommend checking out our _[code of conduct]_. Thanks! :smile:
20
+
21
+ ## How to Contribute
22
+
23
+ ### Reporting Issues / Bugs
24
+
25
+ - Double check that the bug has not already been reported by searching the project's GitHub [Issues].
26
+ - If an issue already exists, you're welcome to add additional context that may not already be present in the original message via the comments.
27
+ - Once you have verified no pre-existing bug report exists, [create a new issue].
28
+ - Provide a title and concise description.
29
+ - Include as much detailed information regarding the problem as possible.
30
+ - Supply reproducible steps that demonstrate the behavior.
31
+
32
+ ### Suggesting a Feature
33
+
34
+ - Double check that a similar request has not already been made by searching the project's GitHub [Issues].
35
+ - If no issue exists pertaining to your feature request, [create a new issue].
36
+ - Provide a title and concise description.
37
+ - Describe what functionality is missing and why it would be useful for yourself and others.
38
+ - If relevant, include any screenshots, animated GIFs, or sketches that might further demonstrate the desired feature.
39
+
40
+ ### Submitting a Pull Request
41
+
42
+ 1. Fork the Project
43
+ 2. Create your Branch (`git checkout -b my-amazing-feature`)
44
+ 3. Commit your Changes (`git commit -m 'Add some AmazingFeature'`)
45
+ - Be sure to follow our coding style and formatting conventions (below).
46
+ 4. Push to the Branch (`git push origin my-amazing-feature`)
47
+ 5. Open a Pull Request
48
+ - List what you've done.
49
+ - Link to any related or addressed issues or feature requests.
50
+
51
+ ## Coding Style & Formatting
52
+
53
+ In order to streamline reviews and reduce the barrier-to-entry for developers, we've adopted several standardized tools and workflows to maintain a consistent and reliable code appearance.
54
+
55
+ A set of GitHub Action workflows are in place to perform the following style and formatting checks against every push to our project repositories. These checks must successfully pass before a pull request can be accepted.
56
+
57
+ **Styling**
58
+
59
+ Styling or linting is performed via [flake8] along with the plugins [flake8-bugbear] & [pep8-naming]. A minor amount of configuration has been added to _[setup.cfg]_ in order to provide better compatibility with our formatter black (see next section).
60
+
61
+ **Formatting**
62
+
63
+ Code formatting is completed by [black]. By relinquishing code appearance standards to Black we manage to greatly reduce semantic arguments/discussions that might distract from progress on a project.
64
+
65
+
66
+ ## Creating a Release
67
+
68
+ Releases are made manually by project managers and will automatically be uploaded to PyPI (via GitHib Action workflow) once completed.
69
+
70
+ [flake8]: https://github.com/PyCQA/flake8
71
+ [flake8-bugbear]: https://github.com/PyCQA/flake8-bugbear
72
+ [pep8-naming]: https://github.com/PyCQA/pep8-naming
73
+ [setup.cfg]: https://github.com/blurstudio/preditor/blob/master/setup.cfg
74
+ [black]: https://github.com/psf/black
75
+ [Issues]: https://github.com/blurstudio/preditor/issues
76
+ [create a new issue]: https://github.com/blurstudio/preditor/issues/new
77
+ [code of conduct]: https://github.com/blurstudio/preditor/blob/master/CODE_OF_CONDUCT.md