Commit Graph
14659 Commits
Author SHA1 Message Date
Kyle AltendorfandGitHub 8ca6d8dd71 Remove unneeded 's from stale issue message (#8826)
When the `>` approach was used the `'` became part of the text.  Note https://github.com/Chia-Network/chia-blockchain/issues/8344#issuecomment-938552667 vs. https://github.com/Chia-Network/chia-blockchain/issues/8629#issuecomment-943250731.

```console
$ python -c 'import yaml; f = open(".github/workflows/stale-issue.yml"); x = yaml.safe_load(f); print(x)'
{'name': 'Close stale issues', True: {'schedule': [{'cron': '0 11 * * *'}]}, 'jobs': {'stale': {'runs-on': 'ubuntu-latest', 'steps': [{'uses': 'chia-network/stale@main', 'with': {'operations-per-run': 10000, 'ascending': True, 'days-before-issue-stale': 14, 'days-before-issue-close': 7, 'days-before-pr-stale': 60, 'days-before-pr-close': -1, 'exempt-all-pr-milestones': True, 'exempt-all-issue-milestones': True, 'exempt-all-assignees': True, 'stale-issue-label': 'stale-issue', 'stale-pr-label': 'stale-pr', 'remove-stale-when-updated': True, 'stale-issue-message': "'This issue has been flagged as stale, as there has been no activity on it in the last 14 days. If this issue is still affecting you and in need of further review, please comment on it with an update to keep it open.'\n", 'close-issue-message': "'This issue was automatically closed because it has been flagged as stale, and subsequently passed 7 days with no further activity from the submitter or watchers.'\n", 'stale-pr-message': "'This PR has been flagged as stale due to no activity for over 60 days. It will not be automatically closed, but it has been given a stale-pr label and should be manually reviewed by the relevant parties.'\n"}}]}}}
```

```console
$ git diff
diff --git a/.github/workflows/stale-issue.yml b/.github/workflows/stale-issue.yml
index 2c7c5839a..1ddb819c6 100644
--- a/.github/workflows/stale-issue.yml
+++ b/.github/workflows/stale-issue.yml
@@ -22,16 +22,16 @@ jobs:
           stale-pr-label: stale-pr
           remove-stale-when-updated: true
           stale-issue-message: >
-            'This issue has been flagged as stale, as there has been no
+            This issue has been flagged as stale, as there has been no
             activity on it in the last 14 days. If this issue is still
             affecting you and in need of further review, please comment
-            on it with an update to keep it open.'
+            on it with an update to keep it open.
           close-issue-message: >
-            'This issue was automatically closed because it has been flagged
+            This issue was automatically closed because it has been flagged
             as stale, and subsequently passed 7 days with no further activity
-            from the submitter or watchers.'
+            from the submitter or watchers.
           stale-pr-message: >
-            'This PR has been flagged as stale due to no activity for over 60
+            This PR has been flagged as stale due to no activity for over 60
             days. It will not be automatically closed, but it has been given a
             stale-pr label and should be manually reviewed by the relevant
-            parties.'
+            parties.
```

```console
$ venv/bin/python -c 'import yaml; f = open(".github/workflows/stale-issue.yml"); x = yaml.safe_load(f); print(x)'
{'name': 'Close stale issues', True: {'schedule': [{'cron': '0 11 * * *'}]}, 'jobs': {'stale': {'runs-on': 'ubuntu-latest', 'steps': [{'uses': 'chia-network/stale@main', 'with': {'operations-per-run': 10000, 'ascending': True, 'days-before-issue-stale': 14, 'days-before-issue-close': 7, 'days-before-pr-stale': 60, 'days-before-pr-close': -1, 'exempt-all-pr-milestones': True, 'exempt-all-issue-milestones': True, 'exempt-all-assignees': True, 'stale-issue-label': 'stale-issue', 'stale-pr-label': 'stale-pr', 'remove-stale-when-updated': True, 'stale-issue-message': 'This issue has been flagged as stale, as there has been no activity on it in the last 14 days. If this issue is still affecting you and in need of further review, please comment on it with an update to keep it open.\n', 'close-issue-message': 'This issue was automatically closed because it has been flagged as stale, and subsequently passed 7 days with no further activity from the submitter or watchers.\n', 'stale-pr-message': 'This PR has been flagged as stale due to no activity for over 60 days. It will not be automatically closed, but it has been given a stale-pr label and should be manually reviewed by the relevant parties.\n'}}]}}}
```

Adding the `-` after the `>` additionally avoids the trailing newline.

```console
$ git diff
diff --git a/.github/workflows/stale-issue.yml b/.github/workflows/stale-issue.yml
index 2c7c5839a..1bee15516 100644
--- a/.github/workflows/stale-issue.yml
+++ b/.github/workflows/stale-issue.yml
@@ -21,17 +21,17 @@ jobs:
           stale-issue-label: stale-issue
           stale-pr-label: stale-pr
           remove-stale-when-updated: true
-          stale-issue-message: >
-            'This issue has been flagged as stale, as there has been no
+          stale-issue-message: >-
+            This issue has been flagged as stale, as there has been no
             activity on it in the last 14 days. If this issue is still
             affecting you and in need of further review, please comment
-            on it with an update to keep it open.'
-          close-issue-message: >
-            'This issue was automatically closed because it has been flagged
+            on it with an update to keep it open.
+          close-issue-message: >-
+            This issue was automatically closed because it has been flagged
             as stale, and subsequently passed 7 days with no further activity
-            from the submitter or watchers.'
-          stale-pr-message: >
-            'This PR has been flagged as stale due to no activity for over 60
+            from the submitter or watchers.
+          stale-pr-message: >-
+            This PR has been flagged as stale due to no activity for over 60
             days. It will not be automatically closed, but it has been given a
             stale-pr label and should be manually reviewed by the relevant
-            parties.'
+            parties.
```

```console
$ python -c 'import yaml; f = open(".github/workflows/stale-issue.yml"); x = yaml.safe_load(f); print(x)'
{'name': 'Close stale issues', True: {'schedule': [{'cron': '0 11 * * *'}]}, 'jobs': {'stale': {'runs-on': 'ubuntu-latest', 'steps': [{'uses': 'chia-network/stale@main', 'with': {'operations-per-run': 10000, 'ascending': True, 'days-before-issue-stale': 14, 'days-before-issue-close': 7, 'days-before-pr-stale': 60, 'days-before-pr-close': -1, 'exempt-all-pr-milestones': True, 'exempt-all-issue-milestones': True, 'exempt-all-assignees': True, 'stale-issue-label': 'stale-issue', 'stale-pr-label': 'stale-pr', 'remove-stale-when-updated': True, 'stale-issue-message': 'This issue has been flagged as stale, as there has been no activity on it in the last 14 days. If this issue is still affecting you and in need of further review, please comment on it with an update to keep it open.', 'close-issue-message': 'This issue was automatically closed because it has been flagged as stale, and subsequently passed 7 days with no further activity from the submitter or watchers.', 'stale-pr-message': 'This PR has been flagged as stale due to no activity for over 60 days. It will not be automatically closed, but it has been given a stale-pr label and should be manually reviewed by the relevant parties.'}}]}}}
```
2021-10-15 10:35:57 -07:00
051829d855 use a conftest.py for shared blockchain fixtures (#8821)
* use a conftest.py for shared blockchain fixtures

* try delaying import

* Revert "try delaying import"

This reverts commit f86cc305b1.

* debug

* debug

* debug

* create the .chia dir for tests before creating a broken symlink

* go back

* delay more imports

* black

* provide an explanatory TODO

* Apply suggestions from code review

Co-authored-by: dustinface <35775977+xdustinface@users.noreply.github.com>

Co-authored-by: dustinface <35775977+xdustinface@users.noreply.github.com>
2021-10-15 10:35:13 -07:00
Earle LoweandGitHub 8cabdc66bf Remove flaky mtime check for plots (#8590)
* Change logic for mtime mismatch to log but ignore

* Remove entirely flaky mtime check
2021-10-15 10:34:32 -07:00
dustinfaceandGitHub 71f2c68831 plotting: Fix log output for duplicated plots (#8812) 2021-10-15 09:39:50 -07:00
Kyle Altendorf 24b07e481c data store tidy 2021-10-15 11:29:53 -04:00
Kyle Altendorf b1753eaad0 data store tidy 2021-10-15 11:11:51 -04:00
Kyle Altendorf a0cdf87545 remove DataStore tree table 2021-10-15 10:59:37 -04:00
Kyle Altendorf 4d55b9f8b8 add DataStore._check_roots_are_incrementing() 2021-10-15 10:50:42 -04:00
Kyle Altendorf bf624f77d1 " not """ 2021-10-15 09:55:27 -04:00
Kyle Altendorf 88f837d526 lint 2021-10-15 00:01:27 -04:00
Kyle Altendorf 71ac17e86f Add some initial DataStore integrity checks 2021-10-14 23:42:50 -04:00
Kyle Altendorf 60a71f71b3 cleanup DataStore.insert() and .delete() 2021-10-14 21:53:48 -04:00
Kyle Altendorf 94246111df add TODO: 2021-10-14 14:58:01 -04:00
Kyle Altendorf 13c2f431f1 group DataStore._insert_*() 2021-10-14 14:56:38 -04:00
Kyle Altendorf 594d885aae factor out to DataStore._insert_internal_node() and ._insert_terminal_node() 2021-10-14 14:48:22 -04:00
Kyle Altendorf 2e47cb72b3 xfail test_data_store.test_create_tree_fails_for_not_bytes32 for now 2021-10-14 14:43:47 -04:00
Kyle Altendorf 0bc4a54e80 factor out to DataStore._insert_root() 2021-10-14 14:38:07 -04:00
Kyle Altendorf d3614e9c43 remove a stray r 2021-10-14 13:47:39 -04:00
Kyle Altendorf 21b9416f1a rework DataStore.get_heritage() to .get_ancestors() 2021-10-14 12:06:16 -04:00
Kyle Altendorf bb5d06d7be correct test_data_store.test_delete_from_left_both_terminal 2021-10-14 11:15:27 -04:00
matt 515c220e52 test that runs db layer report and a bunch of fixes 2021-10-14 16:40:19 +02:00
almog e08f9a4809 cli, some refactoring 2021-10-14 16:25:21 +03:00
matt 5951b664b7 formatting and renaming for clarity 2021-10-14 13:44:32 +02:00
Arvid NorbergandGitHub dbe4829669 regenerate workflow files. fix test_hint_store.py (#8725) 2021-10-13 16:05:07 -07:00
Kyle Altendorf d1c1b06be7 expand DataStore.delete() testing 2021-10-13 18:34:31 -04:00
dustinfaceandGitHub 5fae0aae41 plotting|harvester|tests: Drop some parts of PlotRefreshResult (#8760)
* plotting|harvester|tests: Drop `loaded_size` from `PlotRefreshResult`

* rename: Drop `_plots` and `_files` suffixes in `PlotRefreshResult`

* plotting: Drop `PlotRefreshResult.__add__`

I introduced it but i don't really like it because its not a "real" add
any only works in one direction because of `remaining`.
2021-10-13 14:20:32 -07:00
Kyle Altendorf af21ec681e lint 2021-10-13 16:30:08 -04:00
Kyle Altendorf d13e578e4a remove outdated comment 2021-10-13 16:14:21 -04:00
Kyle Altendorf 88f1ea31da drop hexstr_to_bytes32() 2021-10-13 16:08:21 -04:00
almog 23a6bc943d add wallet to data_layer.py 2021-10-13 21:18:00 +03:00
Jeff CruikshankandGitHub 3864f750b4 Backend changes to support passphrase hints and additional GUI passphrase support (#8779)
* Expose GUI option to save passphrase (where available)
Prevent GUI from showing the option to remove migrated keys

* Backend support for getting/setting the passphrase hint. The hint data is stored in keyring.yaml in the clear.

* CLI support for showing/setting/removing the passphrase hint

* Tests for setting/retrieving passphrase hints

* Squelch LGTM false positive

* Fixed issue when running without passphrase support enabled

* CLI updates based on feedback

* Initialize passphrase_hint earlier.

* Minor restructuring to address linter complaint.
2021-10-13 10:36:10 -07:00
dustinfaceandGitHub 5b7bb5e0f6 github|setup: Introduce pre-commit.yml to force pre-commit to pass (#8811)
* github: Add `pre-commit.yml`

This runs `pre-commit` as github action for all PRs and on pushes to 
`main`.

* github: Drop trailing whitespaces in `stale_issue.yml`

* setup: Ignore type errors for `setup` call
2021-10-13 10:26:15 -07:00
matt 758887b14e add compilation tests and fix compilation error 2021-10-13 17:02:22 +02:00
almog f3bb62eaa3 Merge branch 'altendky-data_layer_exploration' of github.com:Chia-Network/chia-blockchain into altendky-data_layer_exploration 2021-10-13 16:15:34 +03:00
almog c23a42064c fix bugs in rpc_api 2021-10-13 16:13:44 +03:00
ce143311a7 Update tests/core/data_layer/test_data_store.py
remove comment

Co-authored-by: Kyle Altendorf <sda@fstab.net>
2021-10-13 12:26:54 +03:00
Kyle Altendorf fe83bebf7f Merge branch 'main' into altendky-data_layer_exploration 2021-10-12 21:11:23 -04:00
Kyle Altendorf 22cd0927b7 preliminary DataStore.delete() 2021-10-12 20:50:42 -04:00
Kyle Altendorf e10821c0b4 lint 2021-10-12 20:39:19 -04:00
Kyle Altendorf e270b93d8d make DataStore.get_node_by_key[_bytes]() tree id aware 2021-10-12 20:38:47 -04:00
Kyle Altendorf 6fdfa59486 add lock parameter to DbWrapper.locked_transaction() 2021-10-12 18:14:04 -04:00
Jeff CruikshankandGitHub ab7d07ad30 Renamed chia.util.ssl to avoid conflicting with aiohttp's ssl import. (#8805)
Removed hacky sys.path reordering in dump_keyring.py
2021-10-12 13:59:29 -07:00
Kyle Altendorf 1a7e6dc4d7 'simplify' data layer test example data definition 2021-10-12 16:59:08 -04:00
Kyle Altendorf fd727fa800 remove no longer used data store test data 2021-10-12 14:29:22 -04:00
Kyle Altendorf a3ac331ebc lint 2021-10-12 14:20:27 -04:00
Kyle Altendorf 57a487e72e catch up data store with some refactors 2021-10-12 14:08:24 -04:00
J. EckertandJustin England 085191d18d Update stale-issue.yml
bro do you even indent? (whoops)
2021-10-12 10:25:15 -07:00
J. EckertandJustin England 9d58370ba7 Update stale-issue.yml
reformatted message text to comply with yaml line wrapping
2021-10-12 10:25:15 -07:00
Arvid NorbergandGitHub bbc2f76a21 remove unnecessary index in CoinStore & add additional benchmarks (#8641)
* simplify and extend the coin store benchmark to include lookups by coin ID and get_coin_removed_at_height

* remove coin_spent index from coin store table. It's not necessary and slows down updates (and caused one mistaken query plan)
2021-10-12 09:27:47 -07:00
dustinfaceandGitHub 653a11476c plotting|tests: Test duplicates in test_farmer_harvester_rpc.py (#8769)
* plotting: Introduce `PlotManager.get_duplicates`

* tests: Test duplicates in `test_farmer_harvester_rpc.py`
2021-10-12 09:07:18 -07:00