Comments (6)
Thanks for the quick response. The issue already occurs for me on a project where I'm globbing around 2,000 files. However, it's simple to work around as users can normally raise the ulimit value to anything they like (eg ulimit -n 4096
), so it's more a matter of convenience and tidy resource management than a critical issue.
from check-jsonschema.
I checked and click does have a lazy mode for file objects, but it rigs them up to close as part of the command exiting. I don't think that using it naively will solve this.
I'll have this near the front of my queue when I'm next able to devote some time to this project (likely in a little over a week).
from check-jsonschema.
Thanks for the report/request!
It's certainly possible to do -- it is how earlier versions worked. I switched to the built-in click behavior when adding support for stdin, as it seemed like a nice simplification.
Before I pursue this, a quick question: are you running into this issue today, do you foresee running into it (soon), or is the issue purely theoretical?
This may be relevant for prioritization, and I may be pressed on it if I look to make any upstream contributions to click in support of it.
I'll want to look into click's capabilities to see if it can open the files lazily before pursuing a change here.
from check-jsonschema.
Minor update:
I've been tinkering on this but it's not working quite as smoothly as I wanted. The click lazy file object does an eager open/close to catch some errors (e.g. permissions) early, which messes with some of the fifos in the testsuite.
It works in a live context, when I use a shell to write a fifo, so I must be doing something slightly wrong in the tests. I might also file a click bug report, since I think the open/close behavior is slightly unsafe for special file types.
I'm going to try to figure out how to fix the fifo tests, but I do have some options for handling this all in the worst case.
from check-jsonschema.
Tested and working perfectly. Thanks very much!
from check-jsonschema.
Wow, thanks for testing before I even cut the release! I was meaning to push this out yesterday but got a bit delayed.
It's great to hear that it's working for you as intended.
I've just dropped v0.27.3 with this included -- it's the primary update in there. Let me know if you see any issues with the released version. 😄
from check-jsonschema.
Related Issues (20)
- Update vendored bitbucket schema HOT 1
- Feature request: add file names to the ouptut even if validation is OK HOT 3
- "unexpected keyword argument 'registry'" when validating specific GitHub workflow HOT 4
- Bug: Globs work in my machine but fails on CI HOT 3
- AttributeError not parsing schema correctly. HOT 2
- Cannot validate date-time via the CLI tool HOT 4
- Distribute the check-jsonschema tool in a manner which does not assume a Python environment
- Validation passes for misspelled optional child properties in Google Cloud Build schema HOT 7
- check-gitlab-ci: coverage is not a regex HOT 9
- Check yaml with check-metaschema option HOT 3
- Non-JSON files ignored despite --default-type being set HOT 4
- check-azure-pipelines: doesn't handle default value for boolean parameter properly HOT 2
- --schemafile from $schema HOT 1
- Cannot download schema using check-jsonschema HOT 3
- `src/check_jsonschema/builtin_schemas/vendor` file organization HOT 2
- Addition of CircleCI hook? HOT 1
- Release schemas update? HOT 2
- [BUG] RegEx not recognised HOT 5
- GitLab CI .artifacts.reports.annotations is not supported
- bitbucket schema weirdness HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from check-jsonschema.