Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Python3 type suggestion in generated code for error checking #934

Open
ghost opened this issue Jun 21, 2019 · 2 comments
Open

Use Python3 type suggestion in generated code for error checking #934

ghost opened this issue Jun 21, 2019 · 2 comments

Comments

@ghost
Copy link

ghost commented Jun 21, 2019

Refer to "type annotations" in python3

@arshanh
Copy link

arshanh commented Jun 22, 2019

Refer to this link for details:
https://docs.python.org/3/library/typing.html

@hyberdk
Copy link

hyberdk commented Jun 19, 2023

I think an issue here might be that the native model is more than 100MB big

(venv) eslau@N503476:~/repos-wsl/ydk_poc/venv/lib64/python3.10/site-packages/ydk/models/cisco_ios_xe$ ls -lhS
total 120M
-rw-r--r-- 1 eslau eslau 103M Jun 14 15:39 Cisco_IOS_XE_native.py
-rw-r--r-- 1 eslau eslau 817K Jun 14 15:39 Cisco_IOS_XE_ospf_oper.py
-rw-r--r-- 1 eslau eslau 488K Jun 14 15:39 CISCO_RTTMON_MIB.py

that causes vscode to stop linting and auto completing. As far as I can tell, there is no way currently to up the max size (see this: microsoft/pylance-release#1520)..

So it would make sense to try and split it into smaller files (if possible) as type hints most likely will not work on the native model which I guess is the most used one..

just my 2cents.

Esben

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants