Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding initial project stucture #1

Merged
merged 1 commit into from
Jun 20, 2021
Merged

Adding initial project stucture #1

merged 1 commit into from
Jun 20, 2021

Conversation

ssbarnea
Copy link
Member

No description provided.

@ssbarnea ssbarnea force-pushed the devel branch 3 times, most recently from ec754a3 to 9d5e93c Compare June 19, 2021 13:28
@ssbarnea ssbarnea changed the title Adding the boilerplate Adding initial project stucture Jun 20, 2021
@ssbarnea ssbarnea added the enhancement New feature or request label Jun 20, 2021
@ssbarnea ssbarnea merged commit 661c845 into main Jun 20, 2021
@ssbarnea ssbarnea deleted the devel branch June 20, 2021 10:00
@webknjaz
Copy link
Member

Sorry, I haven't found time to post comments, I'll do so post-merge. I've seen a number of occurences of hardcoded mentions of other projects and unnecessary stuff.

tox.ini Show resolved Hide resolved
tox.ini Show resolved Hide resolved
tox.ini Show resolved Hide resolved
Run the tests under {basepython} and
devel: ansible devel branch
ansible29: ansible 2.9
core: ansible-base 2.10
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

core!=base

test
deps =
ansible29: ansible>=2.9,<2.10
py: ansible-core>=2.11
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no "base"?

tox.ini Show resolved Hide resolved
@@ -0,0 +1,13 @@
#! /usr/bin/env python3
"""Ansible-lint distribution package setuptools installer.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not lint

Comment on lines +1 to +3
[aliases]
dists = clean --all sdist bdist_wheel

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nothing uses this

setup.cfg Show resolved Hide resolved
Programming Language :: Python :: 3
Programming Language :: Python :: 3.6
Programming Language :: Python :: 3.7
Programming Language :: Python :: 3.8
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

3.9?

Topic :: Utilities
keywords =
ansible
lint
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not lint

setup.cfg Show resolved Hide resolved
Comment on lines +81 to +82
[codespell]
skip = .tox,.mypy_cache,build,.git,.eggs,pip-wheel-metadata
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does it have its own config?

profile = "black"

[tool.setuptools_scm]
local_scheme = "no-local-version"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd add this in the CI only.

; warn_unused_configs = True
exclude = test/local-content

[mypy-pytest]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the recent pytest has typing embedded.

@@ -0,0 +1,30 @@
#
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think I'd prefer this in a separate requirements/ dir.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would like to hide many of the files from root under a subfolder but picking requirements/ would not be a generic enough approach. Lets delay this until we can make a more generic solution, maybe under .config/?

.yamllint Show resolved Hide resolved
Comment on lines +3 to +20
- repo: local
hooks:
- id: immutable-setup-py
name: Verify that setup.py stays immutable
description: >-
This is a sanity check that makes sure that
the `setup.py` file isn't changed.
# Using Python here because using
# shell test does not seem to work in CIs:
entry: >-
sh -c 'git hash-object setup.py
|
python -c raise\ SystemExit\(input\(\)\ !=\ \"f6d1010b609cbe816d3ef652eee452d09d52979f\"\)
'
pass_filenames: false
language: system
files: >-
^setup\.py$
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm hearing pip now special-cases setuptools to support editable installs w/o setup.py. Somebody needs to evaluate how well that works and maybe just wipe this file.

disable =
# On purpose disabled as we rely on black
line-too-long,
# TODO(ssbarnea): remove temporary skips adding during initial adoption:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like most of this should be dropped since it's a new project and it's best not to allow weird stuff from the very beginning.

Comment on lines +26 to +30
exclude: >
(?x)^(
examples/playbooks/(with-skip-tag-id|unicode).yml|
examples/playbooks/example.yml
)$
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

irrelevant

# - windows-latest
# - windows-2016
include:
- tox_env: py36
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the point of having the toxenv for each interpreter if tox -e py picks up the current one already?

matrix:
python-version:
# keep list sorted as it determines UI order too
- 3.6
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I usually sort by "importance". That is the latest, the lowest, maybe PyPy, and then the rest.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Alphabetical for the moment

- name: Build dists
run: python -m tox
- name: Publish to test.pypi.org
if: >- # "create" workflows run separately from "push" & "pull_request"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the comment doesn't match the content

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants