Package: nodepy-runtime
Node.pyNode.py is a Python runtime compatible with CPython 2.7 and 3.3 – 3.6.
It provides a separate but superior import mechanism for modules, bringing
dependency management and ease of deployment for Python applications up to par
with other languages,without virtualenvs.Node.py is inspired byNode.js.nppmis Node.py's package manager that allows you to install and manage
standard Python packages (using Pip under the hood)as wellas Node.py
packages without the hazzle of virtual environments.nppmis a powerful
tool for deploying Node.py applications and command-line tools. You can find
the nppm repositoryhere.Usage ExampleNode.py allows you to write very modular Python applications with module
import semantics that are more easily trackable. It also does not have the
concept of a separate__main__module as standard Python does. Any valid
Python script is a valid Node.py script.$ ls
app.py models.py nodepy.json
$ head app.py
import flask
import * from './models'  # Node.py special syntax
require('werkzeug-reloader-patch').install()  # Node.py require() function
app = flask.Flask('myapp')
# ...
$ cat nodepy.json
{
  "name": "myapp",
  "pip_dependencies": {
    "Flask": ">=1.0.2",
    "pony": ">=0.7.3"
  },
  "dependencies": {
    "werkzeug-reloader-patch": "^0.0.7"
  }
}
$ nppm install
$ nodepy app
... Starting Flask server at localhost:8000InstallationNode.py is available from PyPI asnodepy-runtime. The Python version that
you install it into will also be the Python version that you will use in your
Node.py code.Tip: Add the--userflag if you don't want to install Node.py system-wide.$ pip install nodepy-runtimeThere are multiple ways of installingnppm. The suggested method is to
use the remote install script. If you want to install a specific version,
pass the Git ref as an argument (eg.developorv2.0.2). If you don't
specify a tag, the highest tagged version will be installed.$ nodepy https://nodepy.org/get-nppm.pyAlternatively, you can clone the repository and use the local install script.$ git clone https://github.com/nodepy/nppm.git
$ nodepy nppm/scripts/install.pyImportant: The installer isnotable to automatically detect whether
Node.py was installed system-wide or with the--useroption. If you
installed Node.py with the--useroption, pass the--globaloption to
the install-script (global meaning user-location). The default is to install
with--root(system-wide).Changesv2.1.5 (2018-08-18)AddRequest.copy()methodv2.1.4 (2018-08-13)Handle relative package links (actually already in 2.1.3)v2.1.3 (2018-08-13)FixPythonLoader.suggest_files(), no longer replaces an existing suffix
when trying to add.pysuffixv2.1.2 (2018-06-15)FixMANIFEST.inwhich now includesrequirements.txt(required bysetup.py)v2.1.1 (2018-06-14)Release date fix for v2.1.0v2.1.0 (2018-06-14)Renamenodepy-pmtonppminREADME.mdAdd MIT license to the header of all source filesv2.0.3 (2018-06-03)Thenodepy.base.Module()constructor now accepts absolute filenames onlyUpdatesetup.pyto include Markdownlong_descriptionand read install
requirements fromrequirements.txtv2.0.2 (2018-03-30)The local.nodepy/pipdirectory is now always added tosys.pathby using
theEntryModule.run_with_exec_handler()method instead of loading
and executing the module directlyPythonLoader.load()no longer adds tosys.pathif the path already is
in the listv2.0.1 (2017-12-19)PythonLoader._load_code()now uses utf8 encoding by default, however we
should try to peek into the file to see if it contains a coding: commentAlways add localmodules_directoryto Context resolve path, this helps
projects that use package linksNode.py repl can now also import from.nodepy/pipdirectoryFixresolve_rootoutside of package rootDon't importpathlibfromnodepy.utils.path, but instead importpathlib2directly. We decided on not using stdpathlibif it is
available, as there can be minor differencesAdd missingstrict=FalsetoUrlPath.resolve()andZipPath.resolve()Add info tonodepy.runtime.scriptsthat it can also holds anargsmemberresolve_rootnow taken into account for defaultPackage.mainif it is
not explicitly defined, addresolve_rootwhen package entry point is requiredStdResolver.package_for_directory()must resolve the path to eliminate
pardir elements, otherwise we can end up with two Packages pointing to the
same directory, but one containssubdir/..elementsUpdateModule.nameproperty to be able to produce a requirable module name
for modules outside a package'sresolve_rootFixed comparing RequestString with actual request str inRequest.try_()to properly raise TryResolveErrorFixFrameDebuggerparent calls for Python 2AddConfig.sections(), remove debug print inContext.__init__()Removenodepy.default_context, but addnodepy.get_default_context()insteadAddnodepy.utils.configmodule and addContext.configmember which is
initialized from theNODEPY_CONFIGfile or~/.nodepy/configv2.0.0 (2018-11-24)Complete rewriteAbstract module resolving interfaceUsing thepathlib2module to abstract the filesystemCopyright © 2018 Niklas Rosenstein