Comments (9)
No work yet but many thoughts. Python 3 support would be very cool and probably not too much work. It will also easily allow concurrent operations that aren't easily done in Python 2. I've written an asyncio function to consume the HTTP stream from salt-api and something like that would be a great addition to Pepper. It would allow us to display live minion returns on the Pepper CLI as they come in to Salt in addition to all the programmatic utility of watching the event stream via libpepper.
from pepper.
@whiteinge I'm gonna be poking around the libpepper.py
file as i currently have a dependency on it right now. I briefly tried but setup.py flipped out about the version not being compliant.
the asyncio stuff sounds fantastic.
You should see some hack/attempt in the next day or so from me.
from pepper.
I'm still having some issues with setup.py, as the version isn't pep-0440 compliant (I probably have to do something with git tag/describe).
I'll probably submit another PR or two as i work through this.
from pepper.
from pepper.
The exception here https://github.com/saltstack/pepper/blob/master/pepper/__init__.py seems to gather version details post-install. It's just looking for the version.json file.
The simplest thing I can think of is manually adding the version to the json fie, including the project metadata you want added.
Moving the git hash would definitely help.
from pepper.
The idea is:
- If you're running Pepper out of the Git repo directly (for development) that file calls out to
git describe
on request by calling into thesetup.py
file. - If you run
setup.py sdist
for PyPI or to make an installer it runsgit describe
and stores the result inversion.json
.
We could keep that same workflow with the following changes:
-
Look to see if
-g
exists in thegit describe
output. If so, -
Break the output of
git describe
into it's constituent parts:>>> re.search('(?P<version>.*)-(?P<num_commits>[0-9]+)-g(?P<sha>[0-9a-fA-F]+)', '0.3.0-22-g867a264').groupdict() {'num_commits': '22', 'sha': '867a264', 'version': '0.3.0'}
-
Modify the
setup.py
file to only putsha
into thesetup_kwargs
metadata maybe asgit_hash
and assemble the actual version number with the pep-recommended "dev" text and use the number of commits as the incrementer. E.g.,0.3.0-dev22
.
Do you think that would work?
from pepper.
I think its a solid idea.
from pepper.
Added!
from pepper.
Per fbe6886 and #64 let's declare Python 3 support a thing and any problems from here on out will be considered bugs.
from pepper.
Related Issues (20)
- --json flag results in errors
- [BUG] Can't send pillar data in kwarg HOT 2
- using pepper with tokens does not honor profiles HOT 1
- Add changelog HOT 1
- Release 0.7.6 breaks --fail-any-none flag HOT 1
- Server error on jobs.lookup_jid with runner client HOT 3
- saving the response to file on MacOS add random characters HOT 4
- pepper.cmd wrapper not included in pip package
- No way to pass tgt_type to API HOT 1
- Should provide a logout function
- Unable to use --state-output=mixed --state-verbose=false with pepper HOT 2
- TLS issues are always ignored HOT 1
- Migrate Travis CI jobs to GitHub Actions HOT 1
- Installing salt-pepper 0.5.5-1 on ubuntu 20.04 failing: cli.py:474: SyntaxWarning: "is not" with a literal. Did you mean "!="?
- Makefile not working on ubuntu 18.04 dev machine
- ~/.pepperc not referred on latest 0.7.6 HOT 1
- Using pepper to get list of registered salt-minions ? HOT 2
- Fix failing test suite HOT 1
- Pepper no longer respecting --out flag HOT 5
- [CI] Remove Python 3.7 in favor of 3.11
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pepper.