Skip to content

Commit 4832622

Browse files
base (#1)
1 parent 3216fb7 commit 4832622

31 files changed

+1156
-1
lines changed

.github/CODE_OF_CONDUCT.md

Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
# Contributor Covenant Code of Conduct
2+
3+
## Our Pledge
4+
5+
In the interest of fostering an open and welcoming environment, we as
6+
contributors and maintainers pledge to making participation in our project and
7+
our community a harassment-free experience for everyone, regardless of age, body
8+
size, disability, ethnicity, sex characteristics, gender identity and expression,
9+
level of experience, education, socio-economic status, nationality, personal
10+
appearance, race, religion, or sexual identity and orientation.
11+
12+
## Our Standards
13+
14+
Examples of behavior that contributes to creating a positive environment
15+
include:
16+
17+
* Using welcoming and inclusive language
18+
* Being respectful of differing viewpoints and experiences
19+
* Gracefully accepting constructive criticism
20+
* Focusing on what is best for the community
21+
* Showing empathy towards other community members
22+
23+
Examples of unacceptable behavior by participants include:
24+
25+
* The use of sexualized language or imagery and unwelcome sexual attention or
26+
advances
27+
* Trolling, insulting/derogatory comments, and personal or political attacks
28+
* Public or private harassment
29+
* Publishing others' private information, such as a physical or electronic
30+
address, without explicit permission
31+
* Other conduct which could reasonably be considered inappropriate in a
32+
professional setting
33+
34+
## Our Responsibilities
35+
36+
Project maintainers are responsible for clarifying the standards of acceptable
37+
behavior and are expected to take appropriate and fair corrective action in
38+
response to any instances of unacceptable behavior.
39+
40+
Project maintainers have the right and responsibility to remove, edit, or
41+
reject comments, commits, code, wiki edits, issues, and other contributions
42+
that are not aligned to this Code of Conduct, or to ban temporarily or
43+
permanently any contributor for other behaviors that they deem inappropriate,
44+
threatening, offensive, or harmful.
45+
46+
## Scope
47+
48+
This Code of Conduct applies both within project spaces and in public spaces
49+
when an individual is representing the project or its community. Examples of
50+
representing a project or community include using an official project e-mail
51+
address, posting via an official social media account, or acting as an appointed
52+
representative at an online or offline event. Representation of a project may be
53+
further defined and clarified by project maintainers.
54+
55+
## Enforcement
56+
57+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
58+
reported by contacting the project team at ipspot@openscilab.com. All
59+
complaints will be reviewed and investigated and will result in a response that
60+
is deemed necessary and appropriate to the circumstances. The project team is
61+
obligated to maintain confidentiality with regard to the reporter of an incident.
62+
Further details of specific enforcement policies may be posted separately.
63+
64+
Project maintainers who do not follow or enforce the Code of Conduct in good
65+
faith may face temporary or permanent repercussions as determined by other
66+
members of the project's leadership.
67+
68+
## Attribution
69+
70+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
71+
available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html
72+
73+
[homepage]: https://www.contributor-covenant.org
74+
75+
For answers to common questions about this code of conduct, see
76+
https://www.contributor-covenant.org/faq

.github/CONTRIBUTING.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# Contribution
2+
3+
Changes and improvements are more than welcome! ❤️ Feel free to fork and open a pull request.
4+
5+
6+
Please consider the following :
7+
8+
9+
1. Fork it!
10+
2. Create your feature branch (under `dev` branch)
11+
3. Add your functions/methods to proper files
12+
4. Add standard `docstring` to your functions/methods
13+
5. Pass all CI tests
14+
6. Update `CHANGELOG.md`
15+
- Describe changes under `[Unreleased]` section
16+
7. Submit a pull request into `dev` (please complete the pull request template)

.github/FUNDING.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
custom: https://openscilab.com/#donation
Lines changed: 96 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,96 @@
1+
name: Bug Report
2+
description: File a bug report
3+
title: "[Bug]: "
4+
body:
5+
- type: markdown
6+
attributes:
7+
value: |
8+
Thanks for your time to fill out this bug report!
9+
- type: input
10+
id: contact
11+
attributes:
12+
label: Contact details
13+
description: How can we get in touch with you if we need more info?
14+
placeholder: ex. email@example.com
15+
validations:
16+
required: false
17+
- type: textarea
18+
id: what-happened
19+
attributes:
20+
label: What happened?
21+
description: Provide a clear and concise description of what the bug is.
22+
placeholder: >
23+
Tell us a description of the bug.
24+
validations:
25+
required: true
26+
- type: textarea
27+
id: step-to-reproduce
28+
attributes:
29+
label: Steps to reproduce
30+
description: Provide details of how to reproduce the bug.
31+
placeholder: >
32+
ex. 1. Go to '...'
33+
validations:
34+
required: true
35+
- type: textarea
36+
id: expected-behavior
37+
attributes:
38+
label: Expected behavior
39+
description: What did you expect to happen?
40+
placeholder: >
41+
ex. I expected '...' to happen
42+
validations:
43+
required: true
44+
- type: textarea
45+
id: actual-behavior
46+
attributes:
47+
label: Actual behavior
48+
description: What did actually happen?
49+
placeholder: >
50+
ex. Instead '...' happened
51+
validations:
52+
required: true
53+
- type: dropdown
54+
id: operating-system
55+
attributes:
56+
label: Operating system
57+
description: Which operating system are you using?
58+
options:
59+
- Windows
60+
- macOS
61+
- Linux
62+
default: 0
63+
validations:
64+
required: true
65+
- type: dropdown
66+
id: python-version
67+
attributes:
68+
label: Python version
69+
description: Which version of Python are you using?
70+
options:
71+
- Python 3.13
72+
- Python 3.12
73+
- Python 3.11
74+
- Python 3.10
75+
- Python 3.9
76+
- Python 3.8
77+
- Python 3.7
78+
default: 1
79+
validations:
80+
required: true
81+
- type: dropdown
82+
id: ipspot-version
83+
attributes:
84+
label: IPSpot version
85+
description: Which version of IPSpot are you using?
86+
options:
87+
- IPSpot 0.1
88+
default: 0
89+
validations:
90+
required: true
91+
- type: textarea
92+
id: logs
93+
attributes:
94+
label: Relevant log output
95+
description: Please copy and paste any relevant log output. This will be automatically formatted into code, so no need for backticks.
96+
render: shell

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
blank_issues_enabled: false
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: Feature Request
2+
description: Suggest a feature for this project
3+
title: "[Feature]: "
4+
body:
5+
- type: textarea
6+
id: description
7+
attributes:
8+
label: Describe the feature you want to add
9+
placeholder: >
10+
I'd like to be able to [...]
11+
validations:
12+
required: true
13+
- type: textarea
14+
id: possible-solution
15+
attributes:
16+
label: Describe your proposed solution
17+
placeholder: >
18+
I think this could be done by [...]
19+
validations:
20+
required: false
21+
- type: textarea
22+
id: alternatives
23+
attributes:
24+
label: Describe alternatives you've considered, if relevant
25+
placeholder: >
26+
Another way to do this would be [...]
27+
validations:
28+
required: false
29+
- type: textarea
30+
id: additional-context
31+
attributes:
32+
label: Additional context
33+
placeholder: >
34+
Add any other context or screenshots about the feature request here.
35+
validations:
36+
required: false

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
#### Reference Issues/PRs
2+
3+
#### What does this implement/fix? Explain your changes.
4+
5+
#### Any other comments?
6+

.github/dependabot.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: pip
4+
directory: "/"
5+
schedule:
6+
interval: weekly
7+
time: "01:30"
8+
open-pull-requests-limit: 10
9+
target-branch: dev
10+
assignees:
11+
- "sepandhaghighi"

.github/workflows/publish_pypi.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# This workflows will upload a Python Package using Twine when a release is created
2+
# For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries
3+
4+
name: Upload Python Package
5+
6+
on:
7+
push:
8+
# Sequence of patterns matched against refs/tags
9+
tags:
10+
- '*' # Push events to matching v*, i.e. v1.0, v20.15.10
11+
12+
jobs:
13+
deploy:
14+
15+
runs-on: ubuntu-22.04
16+
17+
steps:
18+
- uses: actions/checkout@v2
19+
- name: Set up Python
20+
uses: actions/setup-python@v1
21+
with:
22+
python-version: '3.x'
23+
- name: Install dependencies
24+
run: |
25+
python -m pip install --upgrade pip
26+
pip install setuptools wheel twine
27+
- name: Build and publish
28+
env:
29+
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
30+
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
31+
run: |
32+
python setup.py sdist bdist_wheel
33+
twine upload dist/*.tar.gz
34+
twine upload dist/*.whl

.github/workflows/test.yml

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
# This workflow will install Python dependencies, run tests and lint with a variety of Python versions
2+
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
3+
4+
name: CI
5+
6+
on:
7+
push:
8+
branches:
9+
- main
10+
- dev
11+
12+
pull_request:
13+
branches:
14+
- main
15+
- dev
16+
17+
env:
18+
TERM: xterm
19+
20+
jobs:
21+
build:
22+
23+
runs-on: ${{ matrix.os }}
24+
strategy:
25+
fail-fast: false
26+
matrix:
27+
os: [ubuntu-22.04, windows-2022, macOS-13]
28+
python-version: [3.7, 3.8, 3.9, 3.10.5, 3.11.0, 3.12.0, 3.13.0]
29+
steps:
30+
- uses: actions/checkout@v2
31+
- name: Set up Python ${{ matrix.python-version }}
32+
uses: actions/setup-python@v2
33+
with:
34+
python-version: ${{ matrix.python-version }}
35+
- name: Installation
36+
run: |
37+
python -m pip install --upgrade pip
38+
pip install .
39+
- name: Run1
40+
run: |
41+
ipspot --version
42+
- name: Run2
43+
run: |
44+
ipspot --info
45+
- name: Run3
46+
run: |
47+
ipspot
48+
- name: Run4
49+
run: |
50+
ipspot --no-geo
51+
- name: Install dev-requirements
52+
run: |
53+
python otherfiles/requirements-splitter.py
54+
pip install --upgrade --upgrade-strategy=only-if-needed -r test-requirements.txt
55+
- name: Version check
56+
run: |
57+
python otherfiles/version_check.py
58+
if: matrix.python-version == 3.9
59+
- name: Other tests
60+
run: |
61+
python -m vulture ipspot/ setup.py --min-confidence 65 --exclude=__init__.py --sort-by-size
62+
python -m bandit -r ipspot -s B404,B603,B605,B607,B311
63+
python -m pydocstyle --match-dir=ipspot -v
64+
if: matrix.python-version == 3.9

0 commit comments

Comments
 (0)