Questions tagged [nox]

nox is a command-line tool that automates testing in multiple Python environments, similar to tox. Unlike tox, Nox uses a standard Python file for configuration

nox a command line tool that automates testing in multiple python environments, similar to tox. It is considered by his creator like the descendant of tox.

Its main advantage over toxfor me is that you can take advantage of all the power of the python language in your automation process, but it has others cool features. Also it is used by some great projects like google-cloud-python or urllib3.

Nox works with the notion of sessions. A session is a callable decorated with nox.session taking a session argument that we use to perform various actions. The two main actions you will usually performed are install and run but there are others.

Projects that use Nox

  • Bézier
  • gapic-generator-python
  • gdbgui
  • Google
  • Assistant
  • SDK
  • google-cloud-python
  • google-resumable-media-python
  • Hydra
  • OmegaConf
  • OpenCensus
  • Python
  • packaging.python.org
  • pipx
  • Salt
  • Subpar
  • Urllib3
  • Zazo

Other useful projects

Nox is not the only tool of its kind. If Nox doesn’t quite fit your needs or you want to do more research, we recommend looking at these tools:

  • tox is the de-facto standard for managing multiple Python test environments, and is the direct spiritual ancestor to Nox.

  • Invoke is a general-purpose task execution library, similar to Make. Nox can be thought of as if Invoke were tailored specifically to Python testing, so Invoke is a great choice for scripts that need to encompass far more than Nox’s specialization.

Nox also exists due to the various patches and work contributed by the community

https://nox.thea.codes/en/stable/

25 questions
2
votes
0 answers

nox: Install different versions of dependency using poetry according to Python version

I am using nox in order to test my code against different Python versions. I have a dependent package that is stored on my local hard drive. I add this package via poetry with the following command: poetry add…
Andi
  • 3,196
  • 2
  • 24
  • 44
1
vote
0 answers

when i select debug app option in Android Studio this error comes: Error running 'app': Error retrieving capabilities from the device 127.0.0.1:62001

When I select the debug app option in Android Studio, this error comes: Error running 'app': Error retrieving capabilities from the device 127.0.0.1:62001 Has anyone encountered such a case so far?
1
vote
0 answers

Using default tool values for reusable noxfile

I am implementing a reusable noxfile, my goal is that the different Python components of my project can have the same workflow for testing, linting, etc. To do this, I created a nox_plugin module containing this generic noxfile.py (this is a…
Kins
  • 547
  • 1
  • 5
  • 22
1
vote
0 answers

how to use environment variable in a nox session?

I want to use nox to run my test suit in a controlled environment. To perfectly work I need to pass an environment variable from my normal env to the virtual one is it possible and if yes how ? @nox.session(name="test", python="3.8") def…
Pierrick Rambaud
  • 1,726
  • 1
  • 20
  • 47
1
vote
1 answer

How to mention file name in nox + pytest?

My nox function looks something like this @nox.session(python=["3.7", "3.8", "3.9"]) def test(session: nox.Session) -> None: """Run unit tests.""" session.install("-e", ".[all]") session.install("-e", ".[tests]") print…
Bhavani Ravi
  • 2,130
  • 3
  • 18
  • 41
1
vote
1 answer

nox does not find my pyenv versions in my Python Poetry project

I have a python project and I have tried to follow the Hypermodern Python Project guidelines for testing with Poetry and nox and pyenv. This is on Debian 10 running on WLS2. > lsb_release -a Distributor ID: Debian Description: Debian GNU/Linux 10…
Tom Willis
  • 306
  • 4
  • 10
1
vote
0 answers

android gdb fails with "Remote target doesn't support qGetTIBAddr packet" error

My app runs fine but gdb fails to debug it with the following error (gdb) target remote 127.0.0.1:8888 `target:/system/bin/app_process32' has disappeared; keeping its symbols. Remote debugging using 127.0.0.1:8888 Remote target doesn't support…
yjs
  • 11
  • 1
0
votes
0 answers

Nox Emulator I cannot change my location. How can I fix?

[It stays this way. The map does not open.]https://i.stack.imgur.com/Ee9IP.png I deleted and reinstalled. I need to change my location. It was working a few days ago. But now I am facing such a problem. I tried a lot of things but couldn't find the…
Mrs
  • 1
  • 1
0
votes
0 answers

python packaging with flit: specifying dependencies: nox, flit, pyproject.toml,

I am using nox to automate various python packaging tasks. I am using flit to build dist package and pyproject.toml is the metadata file. My pyproject.toml looks as follows: [build-system] requires = ["flit_core >=3,<4",…
Kabira K
  • 1,916
  • 2
  • 22
  • 38
0
votes
0 answers

Why am I gettin a RuntimeError when running tests with nox?

I'm working on a Python module that should work for versions 3.7 to 3.11 of Python. I'm using nox to run the tests in multiple versions. My noxfile.py looks like this: import nox @nox.session(python=["3.7", "3.8", "3.9", "3.10", "3.11"]) def…
0
votes
1 answer

Why am I seeing ZombieProcess exceptions when running Python tests with nox on MacOS?

I'm running Python tests with nox for the first time, and although the tests appear to be passing I'm consistently seeing the following (this has nothing to do with boto3, it's happening on all my tests with a wide variety of…
therightstuff
  • 833
  • 1
  • 16
  • 21
0
votes
1 answer

Record a Mobile application to create a JMeter script

We have a mobile application and recently deployed a new version with updated features. We are creating new JMeter scripts by recording the login, add credit card etc., features using nox recorder. We find a strange issue that a field 'State' which…
0
votes
2 answers

Running a piped command in Nox

Nox runs commands via nox.Session.run. For example, this is a typical nox command: import nox @nox.session(venv_backend="none") def black(session: nox.Session): session.run("black", "--check", ".") Some tools are not amenable to running as a…
drhagen
  • 8,331
  • 8
  • 53
  • 82
0
votes
0 answers

Cannot Debug Project in Android Studio

enter image description here i use Android Studio Dolphin | 2021.3.1 and NoxPlayer 7.0.3.6 Of course, I also tested with my phone but its not working too According to the photo: Debug does not run enter image description here Can anyone help me??
0
votes
0 answers

'No module named pytest' on Gitlab CI nox session despite installing it and using 'external'

When I launch my code to gitlab it goes through the CI, but the pytest session fails while on local machine doesn't. On my gitlab-ci.yaml I tried installing pytest inside and outside the requirements.txt file, this is how it looks now: .test: …
zakilman
  • 3
  • 1
1
2