Skip to main content

waypin

A tiny utility to locate a project root by an anchor directory name (default: scripts) and optionally patch sys.path so absolute imports like from scripts... work in script/main execution and notebooks.

Install

pip install waypin

Usage

from waypin import *

print(ROOT_DIR) # the very upper parant directory of "scripts". you can modify source code from "scripts" to other desired src folder name.
print(NOTEBOOK) # True if upper import statement called within .ipynb file else False 

Behavior

  • Searches upward from the executing context (caller __file__, or notebook path if available) to find a directory named anchor_dirname.
  • Returns the parent of that directory as ROOT_DIR.
  • appends ROOT_DIR to sys.path.

License

MIT

Metadata

Release files for waypin 0.1.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for waypin 0.1.3
File Size Uploaded Provenance Actions
waypin-0.1.3.tar.gz 3.2 kB Without provenance Details for waypin-0.1.3.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for waypin 0.1.3
File Interpreter ABI Platform Actions
waypin-0.1.3-py3-none-any.whl Python 3 none any Details for waypin-0.1.3-py3-none-any.whl

Total release size: 6.5 kB

Release files / waypin-0.1.3.tar.gz

Download URL waypin-0.1.3.tar.gz
Size 3.2 kB
Tags Source
SHA-256 checksum
How to use checksums
22a45aebc1245011067803f2e0729c9501cdd82981c2f8b401c5f59455b5c271
BLAKE2b-256 checksum
How to use checksums
70416367881970fcb862ccf0c029e627a5be2632231c95da9b5a93b7698f03e0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.5

Release files / waypin-0.1.3-py3-none-any.whl

Download URL waypin-0.1.3-py3-none-any.whl
Size 3.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
02c09fd8ee1cba9f19d48cb44f0b134536001f341f6733312b15f1f9e1cb8fbe
BLAKE2b-256 checksum
How to use checksums
b8f0a52b02c08cd373b8fb97853270c75dc18c91471642aa3d0febd1c5e3de2a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.5

Security for waypin 0.1.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page