forked from psychopy/psychopy
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'dev' of https://github.com/psychopy/psychopy into tests…
…-codeQL
- Loading branch information
Showing
646 changed files
with
42,430 additions
and
15,325 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
name: Bug Report | ||
description: File a bug report | ||
labels: 🐞 bug | ||
title: "[Bug]: " | ||
body: | ||
- type: input | ||
id: psychopy-version | ||
attributes: | ||
label: PsychoPy Version | ||
description: What version of PsychoPy are you using? | ||
placeholder: "e.g. 2023.1.3" | ||
validations: | ||
required: true | ||
- type: dropdown | ||
id: os | ||
attributes: | ||
label: What OS are your PsychoPy running on? | ||
description: Please mention the name and version of the Operation System that you are using? | ||
multiple: true | ||
options: | ||
- Windows 10 | ||
- Windows 11 | ||
- macOS Intel | ||
- macOS Silicon | ||
- Linux-based systems | ||
- Other | ||
validations: | ||
required: true | ||
- type: textarea | ||
id: bug-description | ||
attributes: | ||
label: Bug Description | ||
description: | | ||
Please tell us what happened. | ||
Note: You can attach images or log info by dragging files in this input field. | ||
placeholder: "Describe the issue in detail" | ||
validations: | ||
required: true | ||
- type: textarea | ||
id: expected-behaviour | ||
attributes: | ||
label: Expected Behaviour | ||
description: Please tell us what should have happened instead of the bug. | ||
placeholder: "The correct behavior I expected is..." | ||
validations: | ||
required: true | ||
- type: textarea | ||
id: steps-to-reproduce | ||
attributes: | ||
label: Steps to Reproduce | ||
description: Can you reproduce the bug? If so, please let us know what steps you take to reproduce this bug. | ||
value: | | ||
1. | ||
2. | ||
3. | ||
... | ||
validations: | ||
required: true | ||
- type: textarea | ||
id: bug-additional-context | ||
attributes: | ||
label: Additional context | ||
description: Add any other context about the bug here. | ||
validations: | ||
required: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
name: Feature Request | ||
description: Request a new feature, or an enhancement to an existing functionality | ||
labels: 🌟 enhancement | ||
title: "[Feature Request]: " | ||
body: | ||
- type: markdown | ||
attributes: | ||
value: | | ||
Please try to describe your request or enhancement as detailed as possible. | ||
- type: textarea | ||
id: feature-short-description | ||
attributes: | ||
label: Description | ||
description: Please describe this feature or enhancement here. | ||
validations: | ||
required: false | ||
- type: textarea | ||
id: feature-purpose | ||
attributes: | ||
label: Purpose | ||
description: What is the purpose of this feature or enhancement, or give some use cases? | ||
validations: | ||
required: false | ||
- type: textarea | ||
id: feature-is-related-to-a-problem | ||
attributes: | ||
label: Is your feature request related to a problem? | ||
description: A clear and concise description of what the problem is, note if it's a bug please report it in [Bug] template. | ||
validations: | ||
required: false | ||
- type: textarea | ||
id: feature-solution-description | ||
attributes: | ||
label: Describe the solution you would like | ||
description: A clear and concise description of what you want to happen. | ||
validations: | ||
required: false | ||
- type: textarea | ||
id: feature-alternative | ||
attributes: | ||
label: Describe alternatives that you have considered | ||
description: A clear and concise description of any alternative solutions or features you've considered. | ||
validations: | ||
required: false | ||
- type: textarea | ||
id: feature-additional-context | ||
attributes: | ||
label: Additional context | ||
description: Add any other context or screenshots about the feature request here. | ||
validations: | ||
required: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
#! python3 | ||
|
||
"""Using Python to create a cross-platform function to | ||
compare sha checksums (mostly because windows pwsh annoying) """ | ||
|
||
import hashlib | ||
|
||
def checksum(filename, sha_file, alg='sha256'): | ||
"""Verify a hash and raise error if fails""" | ||
computed_hash = getattr(hashlib, alg) | ||
computed_hash = hashlib.sha256() | ||
with open(filename, 'rb') as f: | ||
computed_hash.update(f.read()) | ||
computed_hash = computed_hash.hexdigest() | ||
with open(sha_file) as f: | ||
hash_value = f.read().split()[0] | ||
if computed_hash != hash_value: | ||
raise ValueError(f"The hash did not match:\n" | ||
f" - {filename}: {repr(computed_hash)}\n" | ||
f" - {sha_file}: {repr(hash_value)}") | ||
print(f"Confirmed checksum OK for: {filename}") | ||
|
||
|
||
if __name__ == "__main__": | ||
import argparse | ||
parser = argparse.ArgumentParser( | ||
prog = 'checksum.py', | ||
description = 'Checks a hash against a known sha ' | ||
'value and raises error if not equal') | ||
parser.add_argument('filename') | ||
parser.add_argument('sha_file') | ||
parser.add_argument('alg', default='sha256') | ||
args = parser.parse_args() | ||
checksum(args.filename, args.sha_file, args.alg) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.