Skip to main content

Block scoping in python

Just to be clear, I made this as a joke.

import block_scoping as bs

def main():
    x = 7
    with bs():
        y = x + 4
        print(f'y: {y}') # y: 11
        x -= 3

    print('x: {x}') # x: 4
    print('y: {y}') # UnboundLocalError

main()

Release files for 360blockscope 0.1.0

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

Source distribution (sdist)

Source distribution for 360blockscope 0.1.0
File Size Uploaded
360blockscope-0.1.0.tar.gz 1.9 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for 360blockscope 0.1.0
File Interpreter ABI Platform
360blockscope-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 4.6 kB

Release files / 360blockscope-0.1.0.tar.gz

Download URL 360blockscope-0.1.0.tar.gz
Size 1.9 kB
Tags Source
SHA-256 checksum
How to use checksums
568517137ed4d115ee1517de33272b98404a0ff463bd25aa1856846df9547769
BLAKE2b-256 checksum
How to use checksums
fe8359256ed05dddf55be9001678ce94427e59bc93bedd1a3564f05f0797232c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.4.2 CPython/3.10.10 Linux/6.2.13-arch1-1

Release files / 360blockscope-0.1.0-py3-none-any.whl

Download URL 360blockscope-0.1.0-py3-none-any.whl
Size 2.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
aaa07af98eff6cd75dc184102ade6cc749619050c9308a2b32ef6e2ada7891f3
BLAKE2b-256 checksum
How to use checksums
0c9215e78137525c6e9a71b24b4689580cb1cebd11ad3aab632ad0ba5780e165
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.4.2 CPython/3.10.10 Linux/6.2.13-arch1-1

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files

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