Chunked uploads missing body data.

Summary
In basic Flask applications, the body data of chunked uploads appears to go missing: that is, they do not appear in request.data. I have reproduced this with two different WSGI servers (gunicorn and twisted), both of which handle chunked data appropriately. Non-chunked data does not suffer this problem. I've reproduced this problem on both Python 2.7 and Python 3.6.
Reproduction
The following Flask application demonstrates the problem:
from flask import Flask, request
app = Flask(__name__)

@app.route('/', methods=['GET', 'POST'])
def hello_world():
    return request.data

when run like this: gunicorn -w 4 example:app.
The following test script can be run:
import requests

def gen():
    yield b"hello"
    yield b"world"

print("Making first request")
r = requests.post('http://localhost:8000/', data=b'helloworld')
print("Got: %s" % r.content.decode('utf-8'))
print("Making second request")
r = requests.post('http://localhost:8000/', data=gen())
print("Got: %s" % r.content.decode('utf-8'))

Expected Output
Making first request
Got: helloworld
Making second request
Got: helloworld

Actual Output
Making first request
Got: helloworld
Making second request
Got:

Environment
% python -VV
Python 3.6.0 (default, Jan 18 2017, 18:08:34)
[GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-8<IP_ADDRESS>)]

% pip freeze
appdirs==1.4.3
click==6.7
Flask==0.12.1
gunicorn==19.7.1
itsdangerous==0.24
Jinja2==2.9.6
MarkupSafe==1.0
packaging==16.8
pyparsing==2.2.0
six==1.10.0
Werkzeug==0.12.1

References
This was spotted at httpbin. See kennethreitz/httpbin#340 for more.

✨🍰✨

Further digging shows that wsgi.input in the environ dictionary is valid in the call to flask.app.Flask.wsgi_app: that is, if I call read on it I get the data out in both the chunked and non-chunked case. So somewhere in the Flask/werkzeug stack that data is getting lost.

@Lukasa it appears that weukzeug is intentionally returning an empty stream when there's no content length: https://github.com/pallets/werkzeug/blob/109dad4ac9e0a1690666b2d4f29d07d98a3701d9/werkzeug/wsgi.py#L210

Yup, that looks like a correct analysis of that code.
So, I'd argue that that behaviour is wrong. There's no reason to require the Content-Length field. PEP 3333 makes it pretty clear that the WSGI server should simulate EOF if the client reads past content-length, so I'm not really sure what werkzeug is trying to protect against here.

More generally it makes it basically impossible for werkzeug-using applications to sensibly handle chunked transfer encoding without having their WSGI server buffer the entire inbound data stream, which seems like a pretty unreasonable requirement.

The server is not required to read past the client's specified Content-Length , and should simulate an end-of-file condition if the application attempts to read past that point. The application should not attempt to read more data than is specified by the CONTENT_LENGTH variable.
A server should allow read() to be called without an argument, and return the remainder of the client's input stream.
A server should return empty bytestrings from any attempt to read from an empty or exhausted input stream.

@Lukasa I get a BrokenPipeError from requests when trying your example. Is that because of this bug? How did you get the output?
Traceback (most recent call last):
  File "/home/david/.virtualenvs/flask/lib/python3.6/site-packages/requests/adapters.py", line 444, in send
    low_conn.send(hex(len(i))[2:].encode('utf-8'))
  File "/usr/lib64/python3.6/http/client.py", line 986, in send
    self.sock.sendall(data)
BrokenPipeError: [Errno 32] Broken pipe

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/david/Projects/flask/example2.py", line 11, in <module>
    requests.post('http://<IP_ADDRESS>:5000/', data=gen())
  File "/home/david/.virtualenvs/flask/lib/python3.6/site-packages/requests/api.py", line 110, in post
    return request('post', url, data=data, json=json, **kwargs)
  File "/home/david/.virtualenvs/flask/lib/python3.6/site-packages/requests/api.py", line 56, in request
    return session.request(method=method, url=url, **kwargs)
  File "/home/david/.virtualenvs/flask/lib/python3.6/site-packages/requests/sessions.py", line 488, in request
    resp = self.send(prep, **send_kwargs)
  File "/home/david/.virtualenvs/flask/lib/python3.6/site-packages/requests/sessions.py", line 609, in send
    r = adapter.send(request, **kwargs)
  File "/home/david/.virtualenvs/flask/lib/python3.6/site-packages/requests/adapters.py", line 473, in send
    raise ConnectionError(err, request=request)
requests.exceptions.ConnectionError: [Errno 32] Broken pipe

It's certainly possible, yes. What WSGI server are you using?

Just the built-in dev server. Actually, I forgot I changed gen to
def gen():
    while True:
        yield b"hello, world"

With the original non-infinite generator, I get the empty output.

Yeah, so the infinite generator is a problem because werkzeug things the request has no length, so it immediately sends a response and then, with the builtin server, probably closes the connection. That'll cause the broken pipe error.

We probably don't want to allow infinite streams in all cases? Otherwise it would be trivial to tie up a server.

I have no particular objection to disallowing infinite streams, though I don't know that it's really Flask/werkzeug's problem to deal with: I'd say that in the WSGI abstraction the server is responsible for being sensible here.
The bigger issue, ultimately, is that werkzeug seems to require the non-standard wsgi.input_terminated extension to behave correctly in the presence of chunked transfer encoding.

If we change safe_fallback to False:

Werkzeug's dev server will spin forever and keep using more memory.
Gunicorn times out, but still reads in a ton of data to memory first. It does not appear to have an option to limit the request body size.
uWSGI, the stream is empty by the time it gets to get_input_stream, not sure why. @Lukasa maybe you have some insight here, since I can't imagine uWSGI doesn't support chunked requests. uwsgi --http-socket localhost:5000 -w example:app

I'm not too concerned with the dev server since it's not expected to be used in production.
Flask provides a MAX_CONTENT_LENGTH config, but Werkzeug only uses that when parsing a request's form data, and only if the Content-Length header is set. That should be fixed (but doesn't block this).
I'd like to hear from other maintainers too.

@davism Is the uWSGI stream object empty, or is werkzeug saying it's empty? As noted above, those are two very different cases.

It's an instance of uwsgi._Input. The patch is applied, so it is getting passed to get_data.

Opened pallets/werkzeug#1096 about obeying max_content_length.

Hrm. I don't really know what's going on with uWSGI tbh.

Re https://github.com/pallets/flask/issues/2229#issuecomment-291515867

I'd say that in the WSGI abstraction the server is responsible for being sensible here.

There will be one server developer that argues the other way around, which clearly shows in the different behavior across WSGI servers. In the end, if nobody feels responsible for security improvements beyond the spec, none practically exist.
I agree that the current behavior is not optimal, so I'm not really sure what to do there.

Also generally I'm a fan of having as little logic like this in the WSGI server as possible, since it makes app behavior dependent on deployment.

@untitaker Sure, that's reasonable, but that means that Flask/werkzeug needs to find a way to cope with this that isn't "assume there is no body". If the answer is "servers must support the relevant werkzeug extension" then that's fine, but that needs to be documented really clearly somewhere to make it clear to server authors that if they don't implement it then Flask won't see any chunked bodies. Alternatively, Flask/werkzeug could implement some heuristics regarding headers and the first few bytes of the body to try to work out what the server is doing.
I don't mind at all what direction you choose to go. 😁

@untitaker I think between pallets/werkzeug#1095 and pallets/werkzeug#1096, we should be good. Allows streams without content length, lets Werkzeug handle security if configured in case the WSGI server doesn't handle it. We could still document that servers can implement wsgi.input_terminated.

any solution yet?

pallets/werkzeug#1126 will fix this

Werkzeug has been fixed, not sure when a 0.13 release will happen though. You can install the latest GitHub archive if you want the fix now, it's only a couple commits off 0.12.2 right now.

You will need to set MAX_CONTENT_LENGTH in your Flask config for the change to be apparent. If no content length or max is set, the fallback to an empty stream is still enforced.

I'm trying this with the cloned versions of Flask and Werkzeug, but I'm still seeing the problem with empty request body. Should I have to configure anything else besides this?
app = Flask(__name__, static_folder=static_files_path)
app.config['MAX_CONTENT_LENGTH'] = 9999999

See pallets/werkzeug#1149, fix needs to be fixed.

I'm still having issues with this in Flask 1.0.2 and both gunicorn 19.7.1 & uwsgi 2.0.17
Can't seem to get the request body no matter what I try. Any known workarounds?

@cetanu are you sure Flask 1.0.2 (or newer) with gunicorn 19.7.1 (or newer) didn't work?
I can believe Flask + uwsgi didn't/doesn't work, but Flask + gunicorn shall be a different story.

I appear to be having a similar issue in Flask 1.0.2 with mod_wsgi where the request body is going missing only when it is mod_wsgi that launches flask.  i have attached the debug output from my .wsgi app.  Can anyone confirm that this is the same issue?
[Tue May 14 17:17:12.639947 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] ('REQUEST',
[Tue May 14 17:17:12.639981 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640474 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] {'CONTENT_LENGTH': '2686',
[Tue May 14 17:17:12.640483 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640495 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'CONTENT_TYPE': 'application/json; charset=utf-8',
[Tue May 14 17:17:12.640500 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640511 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'CONTEXT_DOCUMENT_ROOT': '/opt/lampstack-7.1.26-0/apache2/htdocs',
[Tue May 14 17:17:12.640516 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640526 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'CONTEXT_PREFIX': '',
[Tue May 14 17:17:12.640530 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640540 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'DOCUMENT_ROOT': '/opt/lampstack-7.1.26-0/apache2/htdocs',
[Tue May 14 17:17:12.640545 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640555 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'GATEWAY_INTERFACE': 'CGI/1.1',
[Tue May 14 17:17:12.640559 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640569 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'HTTP_ACCEPT': 'application/json',
[Tue May 14 17:17:12.640574 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640583 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'HTTP_ACCEPT_CHARSET': 'utf-8',
[Tue May 14 17:17:12.640588 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640597 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'HTTP_CONNECTION': 'Keep-Alive',
[Tue May 14 17:17:12.640602 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640611 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'HTTP_HOST': 'www.altbrains.com',
[Tue May 14 17:17:12.640616 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640657 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'HTTP_SIGNATURE': 'SuKzPjhCLGR2wEBMuqS4gCEl2YSfnGZlCAXl1ABZmJA6/wL1ckVWk9Wo5ihijXMk1MyrRCmALTbruhsECSIa/rg3WSsrX5MeNVbhz6uj1IXlF+JjnRDZ7YOe/Yrri6BS4fdURDX6RRDzOKqTvg7D0MnnRHq/2JrpBQQSs0Ruue/M/WbrMkQTu7qBx/gVpol5ejcz00VPZA9ycXTJwdgRJQ00egu9dWCtEKKGMiw7zjyRHCANLZjX75q79PG97A6d//YUdurPN+pjjot2xEeFVOTzjAH2Mua2bdwLgULCThxKF94pgjcxY7+ciXgAqcrok1Liv/4A2MzprzEhBe3NXg==',
[Tue May 14 17:17:12.640666 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640689 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'HTTP_SIGNATURECERTCHAINURL': 'https://s3.amazonaws.com/echo.api/echo-api-cert-6-ats.pem',
[Tue May 14 17:17:12.640695 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640706 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'HTTP_USER_AGENT': 'Apache-HttpClient/4.5.x (Java/1.8.0_202)',
[Tue May 14 17:17:12.640711 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640737 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'LD_LIBRARY_PATH': '/opt/lampstack-7.1.26-0/sqlite/lib:/opt/lampstack-7.1.26-0/mysql/lib:/opt/lampstack-7.1.26-0/apache2/lib:/opt/lampstack-7.1.26-0/common/lib:/opt/lampstack-7.1.26-0/sqlite/lib:/opt/lampstack-7.1.26-0/mysql/lib:/opt/lampstack-7.1.26-0/apache2/lib:/opt/lampstack-7.1.26-0/common/lib:/opt/lampstack-7.1.26-0/git/lib:/opt/lampstack-7.1.26-0/sqlite/lib:/opt/lampstack-7.1.26-0/mysql/lib:/opt/lampstack-7.1.26-0/apache2/lib:/opt/lampstack-7.1.26-0/common/lib',
[Tue May 14 17:17:12.640762 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640774 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'PATH_INFO': '',
[Tue May 14 17:17:12.640778 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640788 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'QUERY_STRING': '',
[Tue May 14 17:17:12.640793 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640802 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'REMOTE_ADDR': '<IP_ADDRESS>',
[Tue May 14 17:17:12.640807 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640817 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'REMOTE_PORT': '5927',
[Tue May 14 17:17:12.640821 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640831 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'REQUEST_METHOD': 'POST',
[Tue May 14 17:17:12.640835 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640844 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'REQUEST_SCHEME': 'https',
[Tue May 14 17:17:12.640849 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640859 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'REQUEST_URI': '/basketball',
[Tue May 14 17:17:12.640863 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640873 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'SCRIPT_FILENAME': '/home/ubuntu/voice/AltBrains_Basketball/basketball.wsgi',
[Tue May 14 17:17:12.640878 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640887 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'SCRIPT_NAME': '/basketball',
[Tue May 14 17:17:12.640892 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640901 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'SERVER_ADDR': '<IP_ADDRESS>',
[Tue May 14 17:17:12.640905 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640915 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'SERVER_ADMIN'<EMAIL_ADDRESS>[Tue May 14 17:17:12.640919 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640929 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'SERVER_NAME': 'www.altbrains.com',
[Tue May 14 17:17:12.640933 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640943 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'SERVER_PORT': '443',
[Tue May 14 17:17:12.640947 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640957 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'SERVER_PROTOCOL': 'HTTP/1.1',
[Tue May 14 17:17:12.640961 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640971 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'SERVER_SIGNATURE': '',
[Tue May 14 17:17:12.640975 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640984 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'SERVER_SOFTWARE': 'Apache',
[Tue May 14 17:17:12.640989 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.640998 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'SSL_TLS_SNI': 'www.altbrains.com',
[Tue May 14 17:17:12.641003 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641020 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'apache.version': (2, 4, 29),
[Tue May 14 17:17:12.641025 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641039 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.application_group': 'localhost|/basketball',
[Tue May 14 17:17:12.641044 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641054 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.callable_object': 'application',
[Tue May 14 17:17:12.641058 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641068 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.connection_id': 'ws0lNLzQwAE',
[Tue May 14 17:17:12.641072 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641082 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.daemon_connects': '1',
[Tue May 14 17:17:12.641086 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641096 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.daemon_restarts': '0',
[Tue May 14 17:17:12.641100 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641110 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.daemon_start': '1557854232639360',
[Tue May 14 17:17:12.641114 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641124 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.enable_sendfile': '0',
[Tue May 14 17:17:12.641128 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641137 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.handler_script': '',
[Tue May 14 17:17:12.641142 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641151 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.ignore_activity': '0',
[Tue May 14 17:17:12.641155 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641165 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.listener_host': '',
[Tue May 14 17:17:12.641169 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641178 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.listener_port': '443',
[Tue May 14 17:17:12.641183 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641192 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.path_info': '',
[Tue May 14 17:17:12.641197 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641206 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.process_group': 'basketball',
[Tue May 14 17:17:12.641211 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641220 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.queue_start': '1557854232639206',
[Tue May 14 17:17:12.641225 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641234 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.request_handler': 'wsgi-script',
[Tue May 14 17:17:12.641239 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641248 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.request_id': 'bPYlNLzQwAE',
[Tue May 14 17:17:12.641253 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641262 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.request_start': '1557854232639084',
[Tue May 14 17:17:12.641266 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641276 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.script_name': '/basketball',
[Tue May 14 17:17:12.641284 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641294 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.script_reloading': '1',
[Tue May 14 17:17:12.641299 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641308 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.script_start': '1557854232639445',
[Tue May 14 17:17:12.641316 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641326 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.thread_id': 2,
[Tue May 14 17:17:12.641331 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641341 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.thread_requests': 0,
[Tue May 14 17:17:12.641345 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641355 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.total_requests': 3,
[Tue May 14 17:17:12.641359 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641374 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'mod_wsgi.version': (4, 6, 5),
[Tue May 14 17:17:12.641379 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641396 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'wsgi.errors': <_io.TextIOWrapper name='<wsgi.errors>' encoding='utf-8'>,
[Tue May 14 17:17:12.641405 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641418 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'wsgi.file_wrapper': <class 'mod_wsgi.FileWrapper'>,
[Tue May 14 17:17:12.641423 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641437 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'wsgi.input': <mod_wsgi.Input object at 0x7fc1742c1c70>,
[Tue May 14 17:17:12.641442 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641452 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'wsgi.input_terminated': True,
[Tue May 14 17:17:12.641456 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641466 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'wsgi.multiprocess': False,
[Tue May 14 17:17:12.641470 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641480 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'wsgi.multithread': True,
[Tue May 14 17:17:12.641484 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641494 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'wsgi.run_once': False,
[Tue May 14 17:17:12.641498 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641508 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'wsgi.url_scheme': 'https',
[Tue May 14 17:17:12.641512 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.641532 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] 'wsgi.version': (1, 0)})
[Tue May 14 17:17:12.642418 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] ('RESPONSE',
[Tue May 14 17:17:12.642432 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.642445 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] '308 PERMANENT REDIRECT',
[Tue May 14 17:17:12.642450 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.642486 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] [('Content-Type', 'text/html; charset=utf-8'),
[Tue May 14 17:17:12.642492 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.642505 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] ('Content-Length', '281'),
[Tue May 14 17:17:12.642510 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927]
[Tue May 14 17:17:12.642525 2019] [wsgi:error] [pid 2325] [remote <IP_ADDRESS>:5927] ('Location', 'https://www.altbrains.com/basketball/')])
[Tue May 14 17:17:29.096614 2019] [ssl:info] [pid 31818] [client <IP_ADDRESS>:49805] AH01964: Connection to child 8 established (server localhost:443)
[Tue May 14 17:17:29.354443 2019] [core:info] [pid 31818] [client <IP_ADDRESS>:49805] AH00128: File does not exist: /opt/lampstack-7.1.26-0/apache2/htdocs/robots.txt
[Tue May 14 17:17:32.923909 2019] [ssl:info] [pid 31307] [client <IP_ADDRESS>:42833] AH01964: Connection to child 0 established (server localhost:443)
[Tue May 14 17:18:19.832119 2019] [ssl:info] [pid 31327] [client <IP_ADDRESS>:49892] AH01964: Connection to child 5 established (server localhost:443)
[Tue May 14 17:18:33.960589 2019] [ssl:info] [pid 32606] [client <IP_ADDRESS>:44328] AH01964: Connection to child 9 established (server localhost:443)
[Tue May 14 17:18:34.031851 2019] [ssl:info] [pid 32606] (70014)End of file found: [client <IP_ADDRESS>:44328] AH01991: SSL input filter read failed.


Error: ***[error]VPN connection failed.

Hi again,
when I use client.ovpn with inline <key> and <tls-crypt> and

config_file: .github/workflows/client.ovpn

it works.
But when I use Actions secrets with OVPN_CLIENT_KEY and OVPN_TLS_AUTH_KEY and

config_file: .github/workflows/client.ovpn
client_key: ${{ secrets.OVPN_CLIENT_KEY }}
tls_auth_key: ${{ secrets.OVPN_TLS_AUTH_KEY }}

it doesn't work:

running command: sudo openvpn --config .github/workflows/github.ovpn --daemon --log openvpn.log --writepid openvpn.pid
2023-09-08 18:38:32 OpenVPN 2.5.5 x86_64-pc-linux-gnu [SSL (OpenSSL)] [LZO] [LZ4] [EPOLL] [PKCS11] [MH/PKTINFO] [AEAD] built on Jul 14 2022
2023-09-08 18:38:32 library versions: OpenSSL 3.0.2 15 Mar 2022, LZO 2.10
2023-09-08 18:38:32 Outgoing Control Channel Authentication: Using 256 bit message hash 'SHA256' for HMAC authentication
2023-09-08 18:38:32 Incoming Control Channel Authentication: Using 256 bit message hash 'SHA256' for HMAC authentication
2023-09-08 18:38:32 TCP/UDP: Preserving recently used remote address: [AF_INET]xx.xx.xx.xx:xx
2023-09-08 18:38:32 Socket Buffers: R=[212992->212992] S=[212992->212992]
2023-09-08 18:38:32 UDP link local: (not bound)
2023-09-08 18:38:32 UDP link remote: [AF_INET]xx.xx.xx.xx:xx
2023-09-08 18:38:32 NOTE: UID/GID downgrade will be delayed because of --client, --pull, or --up-delay
Error: ***[error]VPN connection failed.

In OVPN_CLIENT_KEY and OVPN_TLS_AUTH_KEY I added properly different versions:

<key>
-----BEGIN PRIVATE KEY-----
xxx
-----END PRIVATE KEY-----
</key>

or

-----BEGIN PRIVATE KEY-----
xxx
-----END PRIVATE KEY-----

or only key without header

xxx

but nothing helped.
VPN server is working, I can connect from laptop or phone.

In OVPN_TLS_AUTH_KEY  I used tls-crypt and that was a mistake.
Please add https://github.com/kota65535/github-openvpn-connect-action/pull/45
and also support for tls-crypt (ver 1).


How to run the code example for ussd program

It's really difficul too me to run the ussd program base in joy_ussd_engine.
I created a controller with index to render something but when i need to execute my ussd program you don't mansionate in documentation how to execute the ussd program

Hello @AdamMusa the ussd program is executed from the controller and the menu that has been set up as the start point will be executed once the request comes from the user. I can share a sample example code with you so it can guide you

@Caleb-Mantey  please give just hello world app example with this library. Or just in more just an application with two menu . Because I want to build something with this library but I don't know to use it


Use offset instead of tzdb id

What this PR does / why we need it:
Using tzdb ID may requires tzdb. It cause problem when tzDB does not esits (such as alpine linux).
So use offset instead of tzdb ID.
Which issue(s) this PR fixes:
Fixes #3465
Does this PR introduce a user-facing change?:

NONE

/lgtm

NIce
/approve


Endgame Turret Shadebinder

GM-ready shadebinder build
Focus is crowd-control/freezing, not dps
Exotic armor: EoAW

verity for low-end content if using stasis weapons
Stat priority:
~90 recovery
100 disc

Weapons:

demolitionist or wellspring perk if possible

Working on this. I'd appreciate some feedback on the build itself once I submit the PR

https://github.com/PhantomsChosen/build-profiles/pull/21

for reference from discussion - CWL Version is easiest:
T10 disc
T9-10 Rec

Exotic: EoAW (for GMs), Verity's brow (for normal PvE using stasis weapons)
weapons: anything with demo/wellspring is ideal
Armor mods: something to give you CWL + firepower mods, double bomber mods on class item, 1 grenade kickstart mod
aspects: Iceflare bolts + bleakwatcher
fragments: refraction, durance, fissures, rending
super use:  In GMs, it's for areal control or last resort, don't use the pulse, just shoot the bolts to freeze more things (useful when you need to grab a res or hold majors/champs off from swarming. If you get your super often and won't need it for any crucial moments or if its normal PvE, you can use it whenever

To clarify that discussion, the CWL and Shard versions should be two separate builds


1st Project_GSIMPLEE

<!---   *** BEFORE SUBMITTING: PASTE CLIPBOARD HERE TO COMPLETE YOUR REPORT ***   ---!>

Hey @Yaducode, thanks for reporting. Unfortunately, this issue is empty.
Could you describe your problem?

Closing due to lack of response.


Scrolling behaviour together with the webchat/join - event: The Chatbot doesn't scroll correctly.

Screenshots

Version
latest (current version: 4.13.0)
Describe the bug
When using the welcome - event in combination with the autoScrollSnapOnActivity - option, the welcome message will not be seen completly.
Steps to reproduce

create a backend which answers to the webchat/join event with a long message
use this frontend - example (with your token):

<!DOCTYPE html>

open the chatbot in a small window

Expected behavior
The welcome - message should be seen completly. But the chatbot scrolls to the bottom of the message.
Additional context
Not 100% sure if this behaviour is intended or a bug. But I feel like this would be an intuitive addition to the scrolling - behaviour feature.
I have read the following information:

Due to the limitation of chat adapter, we recommend content author not to send initial activities (a.k.a. welcome messages) longer than a page.

But for us it's just not feasible to follow this recommendation.

Thanks for the very detailed report! For 100% clarity, would you mind recording a video clip of the (incorrect) behavior and sharing here?
Were you able to experiment with the styleOption features available in #3653? Under the 'Description' section, you can see a video that pauses partially down the scrollbar.

Could you fiddle with these options and see if you are able to get behavior closer to what you're looking for?
P.S. Just in case you find it helpful, please use the following link for more information on welcome messages: https://github.com/microsoft/BotFramework-WebChat/blob/master/docs/WELCOME_MESSAGE.md

would you mind recording a video clip of the (incorrect) behavior

I've edited the question and added a gif

Were you able to experiment with the styleOption features available in #3653?

Yes I tried some options. But none of them fixed this problem.

@MatthiasGwiozda Great, thanks for this info. My next step is to try recreating the bug you're experiencing. If I'm having problems I may ask for some more info from you. I'll report back soon!
One more question - is this behavior that recently broke for you? Or is this a newly created bot with no previous behavior available for comparison?

is this behavior that recently broke for you? Or is this a newly created bot with no previous behavior available for comparison?

It always behaved like this. The reason why I consider this to be a "bug" is because it feels like the scroll - behaviour should integrate the welcome - message aswell as all the other messages from the bot.

we have the same problem

@Gusi88 Thanks! Additional chime-ins help us with prioritization. :)

@corinagum This is still an issue for us.
@MatthiasGwiozda Do you have a good workaround?

@nodueck I don't have a workaround - currently our chatbot users need to scroll up to see the whole message.


parseString callback doesn't always return an object

Shouldn't the 2nd argument to cb() always return an object?
https://github.com/Leonidas-from-XIV/node-xml2js/blob/master/lib/parser.js#L303
It's a problem if you check for errors by validating a one layer deep field in the 2nd argument to cb() and there is no reason the callback cannot set this to {}.

xml.parseString(''), function(err, result) {

  // no result object
  // should be result = {}

});

@Leonidas-from-XIV

I think setting it to {} (a potentially valid value) makes it too easy to ignore that an error happened.

How isn't it. If you expect an object, you'll get an object and think everything is ok, when in fact the parsing failed.

Because there are layers and known expectations.
For example, TLS ensures by HTTP content length that all of the data was sent.
What you are saying could be caused by sending an object with missing fields, and the reality there is that you should be validating each field that's required but you aren't yet.

I'm a big fan of defense in depth, where every place tries to help the programmer not to make mistakes (where possible, in this case something like a result type would've been better but the damage is already done). So if you don't catch the error, don't pretend everything went fine by returning a potentially valid value.
If the fact that the value is undefined is creating problems, you can for sure create a wrapper around parseString that replaces undefined with {} but I don't thing that adding more footguns to this library is a good idea.

The fact is that the data structures are data structures and the remaining work is in each program.  This is proven by modules and the count of function arguments eventually removing the validity of modules when complexity is enough to grant value.
What you are doing creates struggle and causes failure to all those who haven't been programming for decades and would already know to create a new language if these failures were normal.
I'm trying to help you with your parser.
It's a format conversion tool and the input type and output type should be the same (if the constructs allow as true in this situation) to allow debugging to be done at the correct level.

The correct level is: if the parsing failed, don't produce invalid data. It is as easy as that.

That's not true, the function returns two values.
The first value is an error value and it indicates if there was a problem parsing the data.
You are asking for people using your module to add extra code other than the error handling.
The expected use is:
xml.parseString('aaaa'), function(err, result) {

  if (err) {
    console.log(err);
    return;
  }

  // parse result
  console.log(result.field);

});

But you allow this to crash, while error handling is written:
xml.parseString(''), function(err, result) {

  if (err) {
    console.log(err);
    return;
  }

  // parse result
  console.log(result.field);

});

You are expecting people to write error handling twice, in the same place.  That is not reasonable:
xml.parseString(''), function(err, result) {

  if (err) {
    console.log(err);
    return;
  }

  if (typeof(result) !== 'object') {
    console.log('result not object');
    return;
  }

  // parse result
  console.log(result.field);

});

In your code, you check that an error has occured and if not then you return. So if there is no error past that point, you can assume that the result is a valid object, no need to check that is is an object.
Unless you're reporting a case where there is no parsing error reported yet the result is not an object. In that case there should obviously be an error reported, and this is indeed an issue, but the fix is to report an error and not return {} as a result.

@Leonidas-from-XIV that's not true, an empty string is parsed to an empty object.

That's probably not right, as an empty string is not valid XML so shouldn't parse to an empty object.

You're not thinking, you are thinking one or the other not actually thinking.
It's not invalid XML, there's no error.
Think about it, they need to increment a counter because parsing was attempted now they must add logic to error handling and the non error handling.


DDOS detection/mitigation support

As I mentioned in #156, I don't think people will want a whole DDOS detection or a throttler built-in, but it would be nice to have hooks helping an external system that does it.
There are two fronts to tackle this.
Detection:

[ ]  Report "Top N" metrics, by user IP or some other kind of header specified by the admin
[ ]  Expose the stats in the UI (users will run more than one instance of Traefik, so they'll still need to run something else that aggregates data from all the instances)
[ ]  Some kind of masking or hashing might be requested for certain fields by the admin for privacy reasons: not the IP address, but probably headers like Authorization:

Mitigation:

[ ]  Allow new rules to drop/redirect/tarpit certain requests
[ ]  Keep track of how many requests were affected by each rule
[ ]  Allow such rules to have an expiration
[ ]  Allow manual additions for e.g. IP addresses that are not in the top N, but the admin knows to be problematic
[ ]  Expose the previous features through the API
[ ]  Show active rules and the requests they blocked in the UI

Does it sound like a good idea?

This would be really cool but I think this might be a bit complex to implement, and it could also break performance. The priority for me is to implement better metrics ;) But in the futur, I'm not against the idea.

I think heaving some sort of a plugin or extension feature here would really help. Traefik could pass request data to external evaluation and then external system could provide back traefik if request should be blocked or not.

Maybe you could already done the same results by parsing access / error logs with a tools like Hadoop or something like that to map reduce data and determine if you are under attack or not... Why not using Fail2Ban ?
In my opinion, is not to Traefik to detect this kind of attack. Nowadays, DDOS attacks are rarely realized with HTTP request but with IP packets, ICMP packets, or whatever. The goal is not to block the HTTP server but the network stack of the operating system

Now that ModSecurity has hit v3.0, it has a more pluggable architecture, ripe for integration with other products. The thought of combining the chocolatey goodness of Traefik with the peanut butter of libModSecurity sounds tantalizing... Is anyone working on a connector at all? It seems like such an integration would allow easier-to-configure WAF protection for a set of services than by introducing nginx or apache with mod_security either upstream or downstream of Traefik. Thoughts?

Please overthink your priority/P3 given to this proposal.

I really think that this should not be done. As for the reasons:

Proper DDoS protection is very hard to implement, requiring quite a lot of effort.
"Do one thing and do it good." Reinventing the wheel over and over again does more harm than good for open source projects. I just say X server.
There are easy to use and cheap DDoS protection options available. Combining the use of Traefik and external-dns on kubernetes is simple enough and even when you do it manually, we are talking of a simple DNS entry giving you one of the best DDoS protections you can have for free, even as a company.

Maybe My comment was misleading. My intention was as the writer before to have support for owasp modsecurity crs implemented in the middleware. It makes few sense to implement this in each Service or have another nginx or apache in front of traefik for this. Integrating modsecurity is not reinventing the wheel, I think.
But maybe I‘m wrong.

It absolutely makes sense to use a WAF on a border firewall. Most compliance standards actually demand a border firewall anyway.
Furthermore, if you implement the WA firewall inside your cluster, it would still be prone to DDoS attacks - the very problem that is to be solved. Only that it would no longer be the service that would be affected, but the ingress controller. Imho, it would create a false sense of security if you implemented a WAF into the ingress controller.
The comparatively naive approach of mod_security on DoS and DDoS protection, namely throttling by number of requests per IP is but one layer of defense against a DoS attack.
However, there is a simple approach to mitigate a DDoS to pretty much the same extend as mod_security does, only with a lot less work involved: netutil.LimitListener
connectionCount := 20

// Create the default listener
l, err := net.Listen("tcp", ":8000")

if err != nil {
    log.Fatalf("Listen: %v", err)
}

defer l.Close()

// Wrap the default listener
l = netutil.LimitListener(l, connectionCount)

// Use the default listener wrapped with a limit Listener to actually process the requests.
log.Fatal(http.Serve(l, nil))

(Source: https://stackoverflow.com/a/37372174/1296707)
@volschin What do you think?

Hello @therc,
This proposal was opened for a while with almost no traction.
We won't add it to the Roadmap yet and we prefer to close it.
We'll re-open it later if necessary.


Compile time static Queries, GroupDescriptions and more ?

Theres still a lot of mapping under the hood, often used with Dictionarys... and we all know that Dictionarys are kinda slow. You may ask why ?
Since we often need to find the certain archetype, query or bitset for a Type[]. So we need to map it, which is hella expensive.
world.TryGetArchetype();
world.Query();
world.Move();
entity.Add/Remove

Make heavily use of that mapping.
An alternative to this approach is to somehow use compile time static magic to prevent additional dictionary lookups. Which also increases the performance a lot.
public static class Archetype{

	public static int Id;
}

public static class Archetype<T>{

	public static readonly int Id;
	public static readonly Type[] BitSet; // BitSet würde sich durch ComponentMeta von T erstellen lassen durch code generierung.
	static Archetype(){
		Id = ++Archetype.Id;
		BitSet = new Type[]{ typeof(T) };
	}

	public static class Add<A>{

		public static readonly int InnerId;
		public static readonly Type[] AddedBitSet;

		static Add(){
			InnerId = Archetype<T,A>.Id;
			AddedBitSet = Archetype<T,A>.BitSet;
		}
	}
}

public static class Archetype<T,TT>{

	public static readonly int Id;
	public static readonly Type[] BitSet;
	static Archetype(){
		Id = ++Archetype.Id;
		BitSet = new Type[]{ typeof(T), typeof(TT)};
	}

	public static class Add<A>{

		public static readonly int InnerId;
		public static readonly Type[] AddedBitSet;
		static Add(){
			InnerId = Id;
			AddedBitSet = new Type[]{ typeof(T), typeof(TT), typeof(A) };
		}
	}

	public static class Remove<T>{

		public static readonly int InnerId;
		public static readonly Type[] RemovedBitSet;

		static Remove(){
			InnerId = Archetype<TT>.Id;
			RemovedBitSet = Archetype<TT>.BitSet;
		}
	}
}

This is compile time static and could be used to receive bitsets quickly. The queryDesc could additional receive those ids or the bitset directly to avoid that query dictionary lookup. The old queryDesc would stay since its more readable.
var bitSet = Archetype<Health, Transform>.BitSet; // Compile time static, instant, no lookups required.
var queryDesc = new QueryDescription{
  All = Archetype<Health, Transform>.Bitset,
  None = Archetype<AI>.Bitset
};

// Or
var queryDesc = new QueryDescription().All<Health, Transform>().None<AI>();  // Acesses Archetype<T,...> under the hood

// No lookups needed since BitSets are compiletime static generated and our query would know instantly everything it needs.
world.Query(in queryDesc,....);

Would also be great for structural changes... since we can easily calculate the archetype an entity would be moved to.


Server selection displays secondary, unsynchronised dropdown

We've been using RapiDoc for a while now, and we're quite happy with it (thanks for maintaining it!) - this appears to be a recent change, we only noticed this yesterday, but it might have been there for a few weeks, I am not sure.
Testing with https://rapidocweb.com/examples/example1.html
If I use this OpenAPI 3.1.0 schema with multiple servers (admittedly not the local schema I was testing with, which is an internal API, but it shows the same issue), then each endpoint has its own dropdown for the server selection, which is not linked to the main server section at the top.
There appears to be 3 problems with this new dropdown:

It's not synced (to the main section, or even other dropdowns), so you can have a different server selected for each endpoint - this is confusing and causes requests to go to unintended servers
It lists each server twice
It doesn't seem to work with parameterised server URLs like {protocol}://localhost

It seems like it might only show up in OpenAPI 3.1.0 specs? Is there a way to disable this new dropdown? I couldn't find anything in the docs about it.

can you provide me with a sample doc for me to produce the issue ?
for server variable use this as the example

In your linked example, the OpenAPI version is 3.0.2. If I change it to 3.1.0 as mentioned, the issue occurs without any other changes (using the same HTML as well).
As you can see in my screenshot, I have selected a (non-default) server, but this new dropdown still shows the old server. Since I want to be able to select/change my API server, I don't think the default-api-server can help here?


Handle properly the LinesMesh intersectionThreshold

This PR is an attempt to handle properly the intersectionThreshold of LinesMesh. This "extra-width" cannot be added to the BoundingInfo using the boundingBiasas it is currently, because the threshold is then scaled according to the world matrix compute the world BoundingInfo. This can lead to missleading worldBoundingBox` (if the scale is 1000 and the threshold is 0.1, the world bbox would get an extra extend of 100 in each direction).
To fix this issue, I removed the code that put this intersectionThreshold as boundingBias into the BoundingInfo. Instead, I integrate this intersectionThreshold in the Ray.intersectsBox and Ray.intersectsSphere with an extra parameter.

@deltakosh Ok I reverted my changes to keep the API unchanged (even if some API change for a major release should be ok...)
Still, there is an inconherence between how the BoundingSphere and the BoundingBox behaves, although there are used exactly the same way and the API and the comments are the same. This is, at least, counter-intuitive. As I had did there, I would recommend to align BoundingBox on BoundingSphere, meaning that a call to reConstruct produces exactly same results as the constructor, and that there is no way to change the world matrix of the Bbox byt by calling reConstruct or update
I added a small change in the Matrix API so that the cached value _isIdentity can be properly set when the Identity matrix is constructed. I did not enable it by default because of the following 👍 The result of isIdentity might depend on a considerAsTextureMatrix parameter, which is pretty bad. It prevents a lot of optimisation when dealing with Identity matrix, as the identity-ness depends on external context which is not stored into the Matrix. So, if a Matrix has its _isIdentity to true, there is no way to figure whether it was computed with considerAsTextureMatrix to true or false. I would higly recomment to remove that and find another way to deal with 3x2 matrix. Moreover, the code seems to be just wrong :
        public isIdentity(considerAsTextureMatrix = false): boolean {
            if (this._isIdentityDirty) {
                this._isIdentityDirty = false;
                if (this.m[0] !== 1.0 || this.m[5] !== 1.0 || this.m[15] !== 1.0) {
                    this._isIdentity = false;
                } else if (this.m[1] !== 0.0 || this.m[2] !== 0.0 || this.m[3] !== 0.0 ||
                    this.m[4] !== 0.0 || this.m[6] !== 0.0 || this.m[7] !== 0.0 ||
                    this.m[8] !== 0.0 || this.m[9] !== 0.0 || this.m[11] !== 0.0 ||
                    this.m[12] !== 0.0 || this.m[13] !== 0.0 || this.m[14] !== 0.0) {
                    this._isIdentity = false;
                } else {
                    this._isIdentity = true;
                }

                if (!considerAsTextureMatrix && this.m[10] !== 1.0) {
                    this._isIdentity = false;
                }
            }

            return this._isIdentity;
        }

the flag can be set to false even if value that are not in the 3x2 matrix are non-zero

A tiny conflict and we can merge


DynamoDB - Improve error handling for put_item without keys

Fixes #1054

Coverage increased (+0.0003%) to 94.134% when pulling 315ac32f0906c36ebf0525c7a9f83ceb8d8cf7ac on bblommers:feature/1054 into 55a150082743ac11f50a4675a33d07e613fd392b on spulec:master.

👍


Expo 52 support

What does this PR do?
Add support for Expo 52.
Review checklist (to be filled by reviewers)

[ ] Feature or bugfix MUST have appropriate tests
[ ] Make sure you discussed the feature or bugfix with the maintaining team in an Issue
[ ] Make sure each commit and the PR mention the Issue number (cf the CONTRIBUTING doc)
[ ] If this PR is auto-generated, please make sure also to manually update the code related to the change

Thank you for your contribution, I have created a separate PR for this :)


Added new() restriction to GetLogger / GetCurrentClassLogger

Fixes #3989

Waiting for https://github.com/NLog/NLog/pull/3986


Fix multiple compiling errors on win10x64+vs2022-amd4

Change ThemeEditor.cpp PrimitiveUtils.cpp SanboxWindow.cpp file encoding method to utf8-with-bom.
Remove duplicated QlementineStyle::groupBoxBackgroundColor/QlementineStyle::groupBoxBorderColor.
explicitly convert size_t to int since vc++ treats C4267 as an error under warning_level_4.

issues with my local git...


Unexpected results in MAD when predicting

In the _mad function, the decision score is computed with:
https://github.com/yzhao062/pyod/blob/master/pyod/models/mad.py#L129-L130
diff = np.abs(obs - self.median)
return np.nan_to_num(np.ravel(0.6745 * diff / np.median(diff)))

This function is used for both fit and predict.
Here, the denominator is the median of the difference between the given observations and the median.
The problem is that in the case of a prediction np.median(diff) uses the current observations and not the ones used for fitting and this can leads to wrong score.
For example, if you use decision_function with one observation, the output score will always be 0.6745 because in this case diff == np.median(diff).
from pyod.models.mad import MAD
import numpy as np

mod = MAD(threshold=3)
x = np.random.normal(size=100).reshape(-1, 1)
mod.fit(x)
mod.median
y = np.array([[1000]])  # obviously an anomaly
mod.decision_function(y)  # array([0.6745])
mod.predict(y)  # array([0])

Idea to solve the problem:
Saving the fitted median diff in the sae way the median is saved:
diff = np.abs(obs - self.median)
self.mediandiff = np.median(diff) if self.mediandiff  is None else self.mediandiff
return np.nan_to_num(np.ravel(0.6745 * diff / self.mediandiff))

Which PyOD version are you using?
Because this bug has been fixed in the latest version.

I use PyOD 0.9.5

Okay. I double-read your query and I understand it now.
Yes, you are right. Please feel free to open a PR.
Thanks.

Thanks for doing this! It is in the latest version!


Can you add an example on how to use this?

Can you add an example on how to use this?
Most other CSP reference pages have at least one example.
Nothing on the internet about how to use this.

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: 53820d20-c512-286d-d5ce-c2f208d3eedd
Version Independent ID: 19d56d9d-4ddf-b4ff-3f0a-f57766b42bc7
Content: Registry CSP - Windows Client Management
Content Source: windows/client-management/mdm/registry-csp.md
Product: w10
Technology: windows
GitHub Login: @ManikaDhiman
Microsoft Alias: dansimp

Hello @mtwelve - Thank you for posting your query. Please note that Registry CSP is only for Windows 10 Mobile OEM configuration. There are other pre-requisite that needs should be used as before using this CSP. Please see the note

Because of this reason, no associated example can be added for this CSP.  If there is anything specific you are looking for, please contact Microsoft Support.
Thanks.
Imran.


c:/Ruby200/include/ruby-2.0.0/ruby/ruby.h:125:14: error: size of array 'ruby_check_sizeof_voidp'  is negative

Follow installation instructions

Install rubyinstaller-2.0.0-p195.exe
Extract DevKit to C:\DevKit; cmd; cd into dir; ruby dk.rb init; and ruby dk.rb install
no errors

Attempt to gem install json --platform=ruby

Utter painful catastrophic failure

Win7 64 Pro
DevKit-mingw64-64-4.7.2-20130224-1432-sfx.exe
rubyinstaller-2.0.0-p195.exe

$ gem install json --platform=ruby
Temporarily enhancing PATH to include DevKit...
Building native extensions.  This could take a while...
ERROR:  Error installing json:
        ERROR: Failed to build gem native extension.

    c:/Ruby200/bin/ruby.exe extconf.rb
creating Makefile

make
generating generator-i386-mingw32.def
compiling generator.c
In file included from c:/Ruby200/include/ruby-2.0.0/ruby.h:33:0,
                 from ../fbuffer/fbuffer.h:5,
                 from generator.c:1:
c:/Ruby200/include/ruby-2.0.0/ruby/ruby.h:125:14: error: size of array 'ruby_check_sizeof_voidp'
 is negative
In file included from c:/Ruby200/include/ruby-2.0.0/ruby.h:33:0,
                 from ../fbuffer/fbuffer.h:5,
                 from generator.c:1:
c:/Ruby200/include/ruby-2.0.0/ruby/ruby.h: In function 'rb_float_value':
c:/Ruby200/include/ruby-2.0.0/ruby/ruby.h:826:13: warning: cast to pointer from integer of diffe
rent size [-Wint-to-pointer-cast]
c:/Ruby200/include/ruby-2.0.0/ruby/ruby.h: In function 'rb_num2char_inline':
c:/Ruby200/include/ruby-2.0.0/ruby/ruby.h:1214:35: warning: cast to pointer from integer of diff
erent size [-Wint-to-pointer-cast]
c:/Ruby200/include/ruby-2.0.0/ruby/ruby.h:1214:35: warning: cast to pointer from integer of diff
erent size [-Wint-to-pointer-cast]
c:/Ruby200/include/ruby-2.0.0/ruby/ruby.h:1214:35: warning: cast to pointer from integer of diff
erent size [-Wint-to-pointer-cast]
c:/Ruby200/include/ruby-2.0.0/ruby/ruby.h:1215:9: warning: cast to pointer from integer of diffe
rent size [-Wint-to-pointer-cast]
c:/Ruby200/include/ruby-2.0.0/ruby/ruby.h:1215:9: warning: cast to pointer from integer of diffe
rent size [-Wint-to-pointer-cast]
c:/Ruby200/include/ruby-2.0.0/ruby/ruby.h:1215:9: warning: cast to pointer from integer of diffe
rent size [-Wint-to-pointer-cast]
c:/Ruby200/include/ruby-2.0.0/ruby/ruby.h: In function 'rb_class_of':
c:/Ruby200/include/ruby-2.0.0/ruby/ruby.h:1514:12: warning: cast to pointer from integer of diff
erent size [-Wint-to-pointer-cast]
c:/Ruby200/include/ruby-2.0.0/ruby/ruby.h: In function 'rb_type':
c:/Ruby200/include/ruby-2.0.0/ruby/ruby.h:1531:12: warning: cast to pointer from integer of diff
erent size [-Wint-to-pointer-cast]
In file included from generator.c:1:0:
../fbuffer/fbuffer.h: In function 'fbuffer_append_str':

ruby 2.0.0p648 (2015-12-16) [i386-mingw32]
DevKit-mingw64-32-4.7.2-20130224-1151-sfx.exe
And still the same.
In file included from c:/row/Ruby200/include/ruby-2.0.0/ruby.h:33:0,
from ../../../../ext/calc_sun/calc_sun.c:1:
c:/row/Ruby200/include/ruby-2.0.0/ruby/ruby.h:125:14: error: size of array 'ruby_check_sizeof_voidp' is negative
In file included from c:/row/Ruby200/include/ruby-2.0.0/ruby.h:33:0,
from ../../../../ext/calc_sun/calc_sun.c:1:
c:/row/Ruby200/include/ruby-2.0.0/ruby/ruby.h: In function 'rb_float_value':
c:/row/Ruby200/include/ruby-2.0.0/ruby/ruby.h:826:13: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
c:/row/Ruby200/include/ruby-2.0.0/ruby/ruby.h: In function 'rb_num2char_inline':
c:/row/Ruby200/include/ruby-2.0.0/ruby/ruby.h:1214:35: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
c:/row/Ruby200/include/ruby-2.0.0/ruby/ruby.h:1214:35: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
c:/row/Ruby200/include/ruby-2.0.0/ruby/ruby.h:1214:35: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
c:/row/Ruby200/include/ruby-2.0.0/ruby/ruby.h:1215:9: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
c:/row/Ruby200/include/ruby-2.0.0/ruby/ruby.h:1215:9: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
c:/row/Ruby200/include/ruby-2.0.0/ruby/ruby.h:1215:9: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
c:/row/Ruby200/include/ruby-2.0.0/ruby/ruby.h: In function 'rb_class_of':
c:/row/Ruby200/include/ruby-2.0.0/ruby/ruby.h:1515:12: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
c:/row/Ruby200/include/ruby-2.0.0/ruby/ruby.h: In function 'rb_type':
c:/row/Ruby200/include/ruby-2.0.0/ruby/ruby.h:1532:12: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
make: *** [calc_sun.o] Error 1
rake aborted!
Command failed with status (2): [C:\devkit\bin/make.exe...]


improve cmake with dynamic build to have more debug symbols

I think FORCE keyword can also be dropped from https://github.com/EBIvariation/vcf-validator/blob/6e68167bcba5a15d64208aa8ddfee7b9c1d3508d/CMakeLists.txt#L82
as stated in cmake documentataion

Normally, set(…CACHE…) creates cache variables, but does not modify them. If FORCE is specified, the value of the cache variable is set, even if the variable is already in the cache. This should normally be avoided, as it will remove any changes to the cache variable’s value by the user.

so only set(...CACHE...) would be enough as per our requirement.

https://github.com/EBIvariation/vcf-validator/blob/a0ed5fbb98a9f96476c27f3cee244008c44eac0a/CMakeLists.txt#L90-L93
these lines could be converted into a single line.

set (CMAKE_BUILD_TYPE  "RelWithDebInfo" CACHE STRING "Choose the type of build, options are: None(CMAKE_CXX_FLAGS or CMAKE_C_FLAGS used) Debug Release RelWithDebInfo MinSizeRel.")

It will serve the same purpose.

Not needed: closing


First Wave will sometimes freeze when selecting a new turret during a tank kill

 Fix first wave freezing.


Can't successfully convert low-value UUIDs without blowing up.

The Problem
When I tried to use this with my phpexpertsinc/ConciseUUID project, the tests all failed on low value UUIDs.
InvalidArgumentException: $bytes string should contain 16 characters.

Here is a test case:
use Ramsey\Uuid\Uuid;
use Tuupola\Base62Proxy as Base62;

$uuid = Uuid::fromBytes(Base62::decode($conciseUuid));

Here's the test data:
    $badUuids = [
            '0023a441-a3a3-4d9e-bd65-de3381c3a226' => '00GHs6XflJ51yCvZ4TwH4g',
            '1ee9a026-48ef-4592-9d87-88ceea7bc35e' => '0wKXIE87UgfjIvSPLkAHao',
            '0e0aa2a8-1a10-45e4-a67a-c97b9c5a7d19' => '0QUkgNC86JAY1A8JhVZ7iT',
            '1ad0d525-97c9-4c08-ad56-59acd47e3f7c' => '0obEi3noEliUnbTQbhMrLo',
   ];

The Solution
I solved this using ext-gmp via:
    // 3. We pad zeros to the beginning, as the result returned by gmp_strval after base conversion
    // is not always 22 characters long.
    $uuid = str_pad($uuid, 22, '0', STR_PAD_LEFT);

I took the first example 00GHs6XflJ51yCvZ4TwH4g. Ran it through the code:
$gmp = new GmpEncoder();
$original = "00GHs6XflJ51yCvZ4TwH4g";
var_dump($original);
$bytes = $gmp->decode("00GHs6XflJ51yCvZ4TwH4g");
var_dump(bin2hex($bytes));
$decoded = $gmp->encode(hex2bin("000023a441a3a34d9ebd65de3381c3a226"));
var_dump($decoded);
$bytes2 = $gmp->decode($decoded);
var_dump(bin2hex($bytes2));

Which yields:
string(22) "00GHs6XflJ51yCvZ4TwH4g"
string(34) "000023a441a3a34d9ebd65de3381c3a226"
string(22) "00GHs6XflJ51yCvZ4TwH4g"
string(34) "000023a441a3a34d9ebd65de3381c3a226"

So to me it seems the null bytes are lost somewhere else.  Which class throws the following exception?
InvalidArgumentException: $bytes string should contain 16 characters.

Taking the first example again and Ramsey\Uuid\Uuid package.
$uuid = Uuid::fromString("0023a441-a3a3-4d9e-bd65-de3381c3a226");
$bytes = $uuid->getBytes();
var_dump(bin2hex($bytes));
$encoded = $gmp->encode($bytes);
var_dump($encoded);
$decoded = $gmp->decode($encoded);
var_dump(bin2hex($decoded));
$uuid2 = Uuid::fromBytes($bytes);
var_dump((string) $uuid2);

yields
string(32) "0023a441a3a34d9ebd65de3381c3a226"
string(21) "0GHs6XflJ51yCvZ4TwH4g"
string(32) "0023a441a3a34d9ebd65de3381c3a226"
string(36) "0023a441-a3a3-4d9e-bd65-de3381c3a226"

So if I am reading this correct the problem is that 00GHs6XflJ51yCvZ4TwH4g is 17 bytes when UUID expects 16. I do not know where the one extra leading 0 comes from because originally it is not there.
$uuid = Uuid::fromString("0023a441-a3a3-4d9e-bd65-de3381c3a226");
$gmp = new GmpEncoder();
$bytes = $uuid->getBytes();
$encoded = $gmp->encode($bytes);
var_dump($encoded);

string(21) "0GHs6XflJ51yCvZ4TwH4g"

I would say the problem is this line. I can see your old code relying on gmp behaviour of dropping out leading null bytes. This class does not lose leading nulls when decoding.
$hex = gmp_strval(gmp_init("00GHs6XflJ51yCvZ4TwH4g", 62), 16);
var_dump($hex);
$hex = gmp_strval(gmp_init("0GHs6XflJ51yCvZ4TwH4g", 62), 16);
var_dump($hex);
$hex = gmp_strval(gmp_init("GHs6XflJ51yCvZ4TwH4g", 62), 16);
var_dump($hex);

$gmp = new GmpEncoder();
$bin = $gmp->decode("00GHs6XflJ51yCvZ4TwH4g");
var_dump(bin2hex($bin));
$bin = $gmp->decode("0GHs6XflJ51yCvZ4TwH4g");
var_dump(bin2hex($bin));
$bin = $gmp->decode("GHs6XflJ51yCvZ4TwH4g");
var_dump(bin2hex($bin));

string(30) "23a441a3a34d9ebd65de3381c3a226"
string(30) "23a441a3a34d9ebd65de3381c3a226"
string(30) "23a441a3a34d9ebd65de3381c3a226"

string(34) "000023a441a3a34d9ebd65de3381c3a226"
string(32) "0023a441a3a34d9ebd65de3381c3a226"
string(30) "23a441a3a34d9ebd65de3381c3a226"

No feedback. Assuming problem was solved. Reopen if needed.


Need a search feature

Now, there are many team stations so we need a searchbox to search a station quickly.

Refer to issue #140


ARROW-813: [Python] setup.py sdist must also bundle dependent cmake m…

…odules

This fails on Windows, solutions seems to be to run git config core.symlinks true before the build (see https://github.com/appveyor/ci/issues/650) Not sure if that is a path we should go. cc @MaxRis

@xhochy , usage of git config core.symlinks true looks much better than alternative script based solutions for Windows. It seems that on Windows created symlinks will not work with FAT32 filesystem, only with NTFS ( http://stackoverflow.com/a/11664406/2266412 ). Personally, I haven't seen wide usage of symlinks on Windows.

Apache RAT fails on compressed tarballs with symlinks, will ignore them for now but I raised an issue upstream: https://issues.apache.org/jira/browse/RAT-235

Appveyor still failing it seems, odd

Fixed: https://ci.appveyor.com/project/xhochy/arrow/build/1.0.317


Problem: nanomina conversion to mina uses f64 which has the potential for representation errors

Solution: Convert nanomina Strings to decimal and set the scale to 1_000_000_000u32.
Also I would drop all trailing zeros after period..
E.g 1000 nanomina will be converted to 0.000001000 mina. We should display 0.000001

@trevorbernard perhaps we can log this for when there is an actual bug. Unless you want to convert this issue into just a formatting task with only the following criteria:

Also I would drop all trailing zeros after period..
E.g 1000 nanomina will be converted to 0.000001000 mina. We should display 0.000001

@trevorbernard perhaps we can log this for when there is an actual bug. Unless you want to convert this issue into just a formatting task with only the following criteria:

It is a bug. Unless you explicitly handle pips in floating point numbers there will always be representation errors because not all floats can be represented in base 2. Easiest to just used a fixed point decimal to represent Mina and u64 for nanomina.

@n1tranquilla to rewrite this issue.


Changing NSFileManager API names to match Darwin version

API names of NSFileManager are modified to match with Darwin version. Files modified are NSFileManager.swift and and other files (including TestFoundation) that use NSFileManager APIs

Changing variables of NSFileManager.swift also to lowercamelcase format. I'll commit those as well in this pull request shortly.

Done.

@swift-ci please test


Quick Camera appears to be broken on macOS 12 Monterey (as of Beta 2 build 21A5268h)

I have tried recompiling with Xcode 13 beta but still receive only a black screen. Messages in debug console in Xcode show:

2021-07-14 19:19:19.197046+0100 Quick Camera[1903:1576318] [plugin] AddInstanceForFactory: No factory registered for id <CFUUID 0x600003a84cc0> F8BB1C28-BAE8-11D6-9C31-00039315CD46
2021-07-14 19:19:19.277776+0100 Quick Camera[1903:1576318]  HALC_ShellDriverPlugIn::Open: opening the plug-in failed, Error:<PHONE_NUMBER> (what)
2021-07-14 19:19:19.329079+0100 Quick Camera[1903:1575773] Detecting video devices...
2021-07-14 19:19:19.349709+0100 Quick Camera[1903:1575773] [plugin] AddInstanceForFactory: No factory registered for id <CFUUID 0x600003a9a240> 30010C1C-93BF-11D8-8B5B-000A95AF9C6A
2021-07-14 19:19:19.375641+0100 Quick Camera[1903:1575773] 3 devices found
2021-07-14 19:19:19.375953+0100 Quick Camera[1903:1575773] Starting capture with device index 0
2021-07-14 19:19:19.783997+0100 Quick Camera[1903:1576318] Metal API Validation Enabled
2021-07-14 19:19:19.841581+0100 Quick Camera[1903:1576355] [logging-persist] cannot open file at line 45068 of [d880193994]
2021-07-14 19:19:19.841623+0100 Quick Camera[1903:1576355] [logging-persist] os_unix.c:45068: (0) open(/var/db/DetachedSignatures) - Undefined error: 0

It appears that the use of AVPlayerView is causing the issue. Changing the view to standard NSView resolves the issue.

Figured out the issue (base component needed to be changed to NSView). Fixed in #31


Even when using as_int still gets decimal (.0) added to the total, after subtraction.

Trying to subtract two values, both with the "as_int" suffixed, still still result with a decimal value, which doesn't work with the minecraft scoreboard function.
I am unable to do something like <%finaldamage%.as_int> on the total value, so can't have the decimal stripped off on last value.
What do?
Script to reproduce:
"Health Test":
  type: assignment

  interact scripts:
  - 10 Punch my Face

  actions:
    on assignment:
    - trigger name:damage toggle:true
    - execute as_server "npc sel <npc.id>"
    - execute as_server "npc vulnerable"

"Punch my Face":
  type: interact

  steps:
    1:
      damage trigger:
        script:
        - define phealth "<npc.health.as_int>"
        - wait 1t
        - define finaldamage "<m:%phealth%-<npc.health.as_int>>"
        - chat "npc.health.as_int<&co> <npc.health.as_int>"
        - chat "phealth<&co> %phealth%"
        - chat "finaldamage<&co> %finaldamage%"

Result of script:

@mythan what happened to yoooouuuu D:

I'm alive and well! Just been playing 7 Days to Die, it's awesome! Too bad you can't script NPC's like you can with Denizen. Wait a minute.... are you saying what I think you're saying? Denizen for 7DTD?? You are awesome! Can't wait to see v0.01  ;-)

@mythan we'll make Denizen-for-WhateverYouWant if you come back to us :crying_cat_face:

It's somewhat true, we can. we have the technology

@mythan you should come into denizen-dev and chat with us some time, we miss you man.
Also if 7dtd opens to modding... we can do that >:D

@Morphan1 I never left you guys, I still watch you through the window sometimes.
@mcmonkey4eva Can't mod it as much as MC using Bukkit. They have highly customizable XML files, but you're still confined by what hasn't been exposed as a tag. We are running a modded server at "oz.nz" where we made some custom items, biomes, crafting recipes etc. It's a Steam greenlight game, so still under heavy development.
@Matterom hey man! Good to see you're still around :D

I exist in spurts.. sometimes they don't see me in months. But im not near as bad as some other folks.

@mcmonkey4eva Actually, that's not exactly true. It uses the Unity engine, so you can extract assets files and add completely custom items etc but then the client side needs to download files which we're trying to avoid.

@mythan I'm talking open source code that we can edit and inject a scripting engine into

It /might/ be possible to decompile, but it's questionably legal to redist that

Should message aufdemrand and ask to market denizens.
Denizen Script: Just tack it in..? Just...something.. im bad at slogans

@mcmonkey4eva Yeah, I dunno about that. My knowledge about modding 7DTD stops at the point where custom files are needed. But I'll definitely let you know if they open it further in the future :D

@mythan It's written in C#, and I happen to have a C# script engine very similar to Denizen that needs a proper home available.
Some differences, though. The syntax is different in a few ways... and it runs roughly 12x faster I believe.

@mythan now seriously get in denizen-dev http://mcmonkey.org/ircchat_denizen


feat: add description for Client interface

Please do not merge requests until we have discussed the issue clearly.

Our open API should allow users to quickly understand how to use it, but at present, I still have misunderstandings about the definitions of ShowTagKeys and ShowSeries.I think the definitions of these APIs are very poor, ShowTagKeys, ShowTagValues, ShowFieldKeys, ShowSeries

The purpose are unclear
Input parameters command are unclear
The return value type is unclear

Can we add it to design doc first?

impl by: #165 , close it.


Leftclick on drop-down menu icon sends You to My Activity Feed, rightclick to Training/My Activities

Hi Thomas!
This pull request is really small (now that's something new :), but useful.
In most of my Strava sessions I want to quickly jump to my activities feed, but have to first click "Strava" picture to get to friends activity feed and then select "My activities" in pull-down selection. Similary "Training/My Activities" is often my target, but again have to search for it in Training menu.
This change "activates" StravistiX pull-down menu icon so that clicking on it with left mouse button takes you to My Activity Feed and clicking on it with right mouse button takes you directly to Training/My Activities! Quick and easy!
Regards,
Dejan
sLOVEnia

Simple and good idea. Merged !


O(1) lookup for reserved keywords

LGTM. Don't forget to squash your commits before merging!

:+1: closing


Gantry: #2662 reappears in v1.7.0-rc.2

The issue with assigning specific pages (issue #2662) in gantry admin layouts seems to have come back in v1.7 RC2. I thought it was fixed in RC1.
Also list boxes don't format correctly in Safari, been a problem for a while, see screenshot.

@psd-uk Can you re-test this issue with latest Gantry 5.4.32 release?

Sorry, I will be away from the desktop for a few days

I have now tested on v1.7.0-rc.3 & Gantry 5.4.32 and it does now show a Pages assignment box.
In Chrome it has the two containers inline vertically and controls function correctly.
In Safari you get both boxes as shown in the following screenshot:

removing from the card :
#g5-container .card {
vertical-align: top;
}
improves the formatting of the control elements but the card height does not expand. I have tried but cannot get this to expand in safari.

Oh, you're talking about Safari. This issue isn't related to the issue you mentioned in the first message -- this is a bug in Safari with no known workaround.
Make sure you're on the latest version of Safari. Older versions of Safari have very buggy flexbox support which causes layout issues like this. FF and Chrome should work just fine.

Thanks Mahagr.
Yes it was a secondary bit to my first message. I will use Chrome until Safari is sorted.

I'm closing this as it is not related to Grav but Gantry.


OpenAPI now takes input and responds in the user interface.

OpenAPI now takes input and responds in the user interface.
OpenAPI communication from client to server established

looks nice. we have a the guy giving response now!


How to upload large data sets added in Readme.

@musk101 good attempt. I see you've simply merged the documentation from the different sources to create the tutorial.
However, this doesn't describe how to actually use transform for purposes other than simple transformations such as cropping. Please take the help of https://github.com/activeloopai/Hub/blob/master/examples/coco/upload_coco2017.py and https://github.com/activeloopai/omdena-aerial/blob/master/store_omdena.py to add information on how to use it for uploading datasets.
Also, this information shouldn't be added to the readme but rather to https://github.com/activeloopai/Hub/blob/master/docs/source/concepts/dataset.md

Cool I will do the needful.


Change signature of IRetainedRepository.retainedOnTopic to reflect the fact it return unordered collection

As per PR #781, the result of retainedOnTopic is unordered, but it's returned as a List with expose the concept of order.
Return as Collection (if admit duplicates) or Set and update consistently all the usages to reflect the fact that it hasn't any ordering.

Closed by #787


Citation autocompletion

Citation autocompletion does not work for me, maybe because I am not using the compilation interface of this package. When I type \cite{}, a search window (text input box) appears with no options. So far, no bug.
I hit  and go on typing, and almost at every letter (depending on how fast I type), that same window steals focus again and again. Any text I type in that window is lost.
Suggested fixes:

workaround: implement the option to disable the autocompletion (seems not to have any effect now; no surprise, given the warning in the package description)
trigger the autocompletion only once (reset it when the cursor exits the \cite{} scope)
copy the text typed in the window into the \cite{} verbatim when it does not match anything

Same goes for me. I am building my document with a Grunt job and use Atom just for editing.
Atom: 1.3.2
Distribution: Ubuntu 14.04

Hi @HamletGhost and @pbrueske .
Hmm... looks like bib files are not found, so completion fails (silently).  First of all, to clarify:

Completion only works with bibliographies in bib files, not for references provided using the \bibitem command.
bib files must be indicated using the usual \bibliography (or \addbibresource) command, specifying the path relative to the tex file (the master tex file, in a multi-file document). So for instance bib files in your texmf tree are not yet supported on Atom (they are on Sublime Text).

Anyway, I have just pushed a couple of commits to master. Ref / cite toggles (Settings) are now honored. Also, if a bib file is not found, the user is informed. These are in master, but not yet in a tagged release. I hope to be able to do a release later today.
In the meantime, can you check your tex file and/or the console to see if bib files are correctly identified? I'm assuming they are not.

@msiniscalchi thanks, adding the .bib file via \addbibresource works for me. :+1:

If all is OK (or at least better) now, can I close?
BTW @pbrueske on a different topic, would the ability to integrate your Grunt job with LaTeXTools be useful to you? What I mean is this: when you hit Ctrl-Alt-B, your grunt job runs, then LaTeXTools picks up the log file and displays the errors. The Sublime Text version of the plugin does have this feature (you can redefine the build command), and I was planning to add it to Atom, too.

@msiniscalchi For me its OK to close.
The feature you are describing sounds interesting, but for my current workflow unnecessary. Thanks, anyway ;)


Plugin System

Inspiration from Pomotroid feature requests: https://github.com/Splode/pomotroid/issues/69

Maybe do wasm extensions using https://extism.org/?

Plugin ideas

Set Slack / Teams / etc status
flash smart lights when a timer is up (like Hue, lifx, nanolights, etc)


Add blog.trueberryless.org showcase

Describe the pull request
Add a new entry to the showcase page for my website: blog.trueberryless.org
Why
I'd love to contribute, I'd love to be part of it, I love your blog extension!

this PR unintentionally includes #75
what the best way to fix this?

I removed last commit of main (reset hard) and force pushed... I think it's okay (LGTM)

Going to do that ASAP

I forgot it ASAP xD

I forgot it ASAP xD

No problem 😄 Do you mind fixing the remaining conflict and we should be able to merge this new addition to the showcase 🎉

no problemo, just fixed it i think 😊


Add an extra option in TimeMapper to set the initial zoom level.

Add an extra option in TimeMapper to set the initial zoom level. I believe that TimelineJS has this feature therefore you could just hook into the start_zoom_adjust config value.
Having just looked at the API, it would also be nice for it to be more configurable in general.  Setting the heading font for example.

I would like to change the config for the map. I have a successful tile server setup but changing the hard coded mapUrl in view.map.js doesn't do anything. Pointers would be greatly appreciated.

I'd also like to be able to alter the config, specifically to:

make the map's default view be Australia
make the timeline's default view be 1990 to the present
Also (preferably!) I want the timeline to be able to zoom in further, because I'm trying to display travelling exhibitions that stay in each venue for two or three months
Pointers, yes please.


Add RepositoryChain to allow repository priority

Add RepositoryChain to allow repository priority and inspection of more than once repository with priority fallback.
Attempt to fix #9.

Removes RepositoryEnv fallback to os.environ;
Add RepositoryChain that accept a list of repositories and iterate over then on getting variables;
Uses RepositoryShell to inspect environment variables before all the others repositories (first on chain);
Repositories discovery now includes all repositories found into path (with fallback chain using closer to the parent path as priority);
README updated.

This means that environment variables are used if defined, with fallback to the configuration files.
Best regards!

Tks for the PR, @fgmacedo!
I've studied your code and one things came to mind: Do you think the RepositoryChain is really needed?
Since RepositoryShell will always be there by default, even when we have .env or .ini files, what do you think about we promote it's behavior to RepositoryBase OR (better?) make RepositoryEnv and RepositoryIni inherit from RepositoryShell?
Subclasses could simply call the parent's method and if the value is not there, then they can do their own stuff.
My perceived advantage of this strategy is that:

We keep AutoConfig "simple" (I think it's already quite cryptic).
We avoid mixing .env and .ini when both are available, which could induce to ambiguity and doubt.
The user could still implement a strict version of a Repository which ignores the default behavior if they need/want to.

What do you think about that?
PS: @osantana any thoughts, you started this. :-P

Hi @henriquebastos, thanks for your review!
I'll break the PR into two pieces: 1) RepositoryChain and  2) Config files discovery.
1) RepositoryChain
The main idea behind RepositoryChain is to keep repositories simple. Avoiding inheritance when simple composition is enough.
The base api remains unchanged, so all "included batteries" of repositories can be used on Config with or without RepositoryChain.
This approach enables all sort of compositions, not limited by hard coded preferences like environment variables over config files. All you need to do is create a list of repositories and create a Config with RepositoryChain. Some examples...
Using config files as primary source and environment as fallback could be done with:
    repositories = [r for r in self._find_repositories(path)]
    repositories.append(RepositoryShell())
    config = Config(RepositoryChain(repositories))

Or to completely ignore environment variables and use only config files:
    repositories = [r for r in self._find_repositories(path)]
    config = Config(RepositoryChain(repositories))

2) Config files discovery
I agree with you that mixing together .env and .ini files could be a bad idea. But who will do this? The loading mechanics can load both, but is up to the user choose one.
What about chained config files? I can think into a basic .env file into a parent folder like ~/.env and project specific configs into ~/projects/project_a/.env. With the AutoConfig._find_repositories this can be done.
While writing this, I think that AutoConfig._find_repositories should be promoted to a basic module function out of AutoConfig. This will turn AutoConfig simpler. Something like this:
def _caller_path():
    # MAGIC! Get the caller's module path.
    frame = sys._getframe()
    path = os.path.dirname(frame.f_back.f_back.f_code.co_filename)
    return path

def find_repositories(path, supported_map):
    # look for all files in the current path
    for configfile, repositoryClass in supported_map:
        # Avoid unintended permission errors
        try:
            filename = os.path.join(path, configfile)
            if os.path.exists(filename):
                yield repositoryClass(filename)
        except Exception:
            pass

    # search the parent
    parent = os.path.dirname(path)
    if parent and parent != os.path.sep:
        for repository in find_repositories(parent, supported_map):
            yield repository

class AutoConfig(object):
    """
    Autodetects the config file and type.
    """
    SUPPORTED = {
        'settings.ini': RepositoryIni,
        '.env': RepositoryEnv,
    }

    def __init__(self):
        self.config = None

    def _load(self, path):
        repositories = [RepositoryShell(), ]
        repositories.extend(find_repositories(path, self.SUPPORTED.items()))

        self.config = Config(RepositoryChain(repositories))

    def __call__(self, *args, **kwargs):
        if not self.config:
            self._load(_caller_path())

        return self.config(*args, **kwargs)

And also will help the explicit creation of Config by users:
from decouple import Config, find_repositories, RepositoryEnv, RepositoryChain
repositories = [r for r in find_repositories(path, {'settings.env': RepositoryEnv})]
config = Config(RepositoryChain(repositories))

But if you like, we can rollback or parametrize find_repositories to stop on the first repository found.
def find_repositories(path, supported_map, find_all=False):
What do you think? Please let me know and I'll update the PR.
[]'s

My 2 cents:

First I'd like to recommend a bunch of small PRs instead of a big one. It make easier to understand and review.
When I opened #9 I was thinking about UNIX arguments/configuration loading order (command line, envvars, project settings, $HOME settings and system settings on /etc). This PR solve this issue and even simplify parts of implementation.
That said, I think that you can implement a simple solution for #9. Try to think in RepositoryChain as a simple python list() attribute in, for example, AutoConfig.

Besides that, I've not so much time to eval your PR and make better recommendations. Sorry.

Tks @osantana!
In fact, RepositoryChain is all about a simple list of repositories. I choose to implement it as kind of Composite instead of using a list inside Config to keep Config compatible with current repositories classes. So you can use it as Config(RepositoryIni(path)) or Config(RepositoryChain(repositories)).
@henriquebastos  I implemented the AutoConfig simplification into another branch... But let me know what do you think.... Should I do another PR?
Best regargs!

Tks a lot @fgmacedo! I've experimented with your patch and with the inheritance strategy. In the end both felt like "too much", so I simply made RepositoryEnv and RepositoryIni use the os.environ explicitly.
This is fixed on 3.0


Replicate functionality of "build system" in Sublime Text

I am looking for something like what Sublime Text does. In Sublime Text, you can define a "build system" which may be associated with a file extension. The build system is a user-defined shell command. You can then build a file with your build system without having to have a project or workspace set up. However when I try to do the same thing in vscode using "build tasks", I get an error saying "Tasks are only available on a workspace folder". I don't want to have to create/open a workspace folder if I want to build a simple script.
Could you possibly imitate the functionality of Sublime Text?

VSCode Version: 1.15
OS Version: Windows 10

Steps to Reproduce:

Create a new file (i.e. index.php)
Go to Tasks > Run Build Tasks or Tasks > Configure Tasks
A error notification pops up saying "Tasks are only available on a workspace folder"

Expected Outcome:
Instead of the error notification, I should be able to run and configure tasks without having a project. This is how Sublime Text works.

Just to update anyone watching this issue. I found out about global launch configurations (mentioned here: https://github.com/Microsoft/vscode/issues/18401#issuecomment-272400316) which solves what I was trying to do. So this ticket could be closed unless anyone else has a good reason to keep it open.

@kodos84 thanks for coming back. Actually global launch configs still don't allow global tasks. So I think the request is still valid even though our specific problem is addressed.

Shared task configurations is tracked by https://github.com/microsoft/vscode/issues/1435


Add plain output option

It might make sense to add something like a --plain option (other name suggestions?) which would provide an easily parseable output (probably just the number of bytes) for other programs that want to run diskus.

Maybe even better: automatically switch to plain format when the output is being piped.

Released in v0.6.0.


[unstable option] file_lines

Tracking issue for file_lines

original issue: https://github.com/rust-lang/rustfmt/issues/1514

Will this option be stabilized anytime soon? We use it for quite some time in RLS for the Range Formatting and it seems to work without any problems.
One thing that sometimes happens IIRC is that it can "grab" remaining parts of the selected expression/AST node outside of the specified range by 1 or 2 lines but it always seemed like it did a reasonable thing, e.g. it was hard to imagine how you could only partially format the specified range.
RLS also uses feature gating for this, so if it were made stable we could offer it to our users out of box, without them having to opt-in into unstable features. cc @nrc

One thing that sometimes happens IIRC is that it can "grab" remaining parts of the selected expression/AST node outside of the specified range by 1 or 2 lines but it always seemed like it did a reasonable thing, e.g. it was hard to imagine how you could only partially format the specified range.

@Xanewok Sounds like that is by design, see https://github.com/rust-lang/rustfmt/issues/1514#issuecomment-301342264 and https://github.com/rust-lang/rustfmt/issues/1514#issuecomment-400959602.
I have combed through the issues mentioning or related to file-lines in order to get a better idea of the current state of that option. Here is an overview and my take on them:

https://github.com/rust-lang/rustfmt/issues/1290: a use case for formatting a selected portion of code. Its priority is low and therefore shouldn't prevent stabilisation I think.
https://github.com/rust-lang/rustfmt/issues/2036: the ability to format rust code inside non-rust files, e.g., markdown. That is an improvement and doesn't prevent stabilisation.
https://github.com/rust-lang/rustfmt/issues/1873: that is bug wrt file path on Windows. I think that's a blocker.
https://github.com/rust-lang/rustfmt/issues/338#issuecomment-344273653: some improvements wrt performance.

Overall, I would say a single issue is needed to complete stabilisation. @topecongiro ?

#3442 is a blocker for us to be able to use --file-lines at all - it produces inconsistent and bimodal results.
There's also another bug I haven't narrowed down yet where rustfmt seems to (sometimes) infinitely indent the internals of macro definitions, which could also be --file-lines related.

Looks like #3442 is fixed now. It is by design that file lines 'rounds up'. We need to round up to the nearest AST node in the best case and we are currently very conservative (I think round up to the nearest item, or maybe even module). So while we could do better, I don't think we need to block stabilisation (although we would need to think about what exactly stability means then). Note that the LSP spec permits rounding up.

@scampi is there any issue that's specifically related to file_lines which blocks this stabilization?

@Xanewok I believe #1873 is the outstanding issue

All of the issues mentioned as blockers seem to have been addressed. Is there any remaining blocker to stabilizing --file-lines?

All of the issues mentioned as blockers seem to have been addressed. Is there any remaining blocker to stabilizing --file-lines?

I believe #4053 may contain some issues that need investigation, but haven't looked to closely.

Can this be used with stdin?

I've been using this via rls and rust-analyzer, and haven't noticed any issues. I'm interested in seeing this stabilized.

As I reported in #5136 file-lines currently changes whitespace outside of the given range. That should be fixed before stabilization.


Dashboard feature: Add Milestone, Add Task

Fixes #29, fixes #30
Changes:

Add new classes to support the new Dashboard feature
Add new command to add a milestone to a Student's Dashboard
Add new command to add a task to a Milestone
Update UI to have a temporary placeholder for Dashboard to demo feature

All good. Continue to develop with other our teammates classes in mind


Add WordPress actions by 10up

At the minute, it looks like there is only one action available in this repository, but based on the description, it is clear that there are going to be more actions added here for WordPress.  As such, I think we can go ahead and merge it in.

@s3rgiosan your changes have been merged, thanks for your contribution 👍


cannot open input file 'BWAPI.lib'

No lib folder in BWAPI version 4.4.0
Visual Studio 2017 10.0.17763.0, Windows 10
Severity	Code	Description	Project	File	Line	Suppression State Error	LNK1181	cannot open input file 'BWAPI.lib' CommandCenter	C:\SCBW\masterBot\vs\LINK	1
1>LINK : fatal error LNK1181: cannot open input file 'BWAPI.lib' 1>Done building project "CommandCenter.vcxproj" -- FAILED.

Yeah, I've just encountered the same issue. However, I resolved it by building BWAPI (say in RELEASE mode) which will produce several *.lib files in the Release folder of BWAPI, namely:

BWAPILIB.lib
BWAPICore.lib
...

And then I set the "Library Directory" setting of "VC++ Directories" to that. In my case the folder is:
c:\Libraries\bwapi_440.src\bwapi\BWAPI\Release
However, I too have downloaded BWAPI 4.4.0 which seems to be incompatible with this version of CommandCenter, because I actually get a compilation error:
Line 437 of "BuildingManager.cpp" [method: CCTilePosition BuildingManager::getBuildingLocation(const Building & b)] cannot build, because "Protoss is not a member of BWAPI::Race".
Any ideas?

I tried to create a BWAPI.lib by changing a property of 'BWAPI' project.
Went to project properties, General -> Configuration Type -> Static library (.lib).
That built fine and produced the BWAPI.lib.
However, the CommandCenter still does not build. This time linker showed 157 errors complaining about mismatches mostly in BWAPIClient.lib:

Any ideas?


cinterop tool for strong mode dart

Kotlin has it, dart should have it as well.  Having such a tool would also be huge for the flutter team in that objective-c and android interop could be generated.

@mit-mit @mravn-google

Forgive the off-topic, thought this was useful too ...
https://github.com/dart-lang/sdk/issues/31493

This is bug https://github.com/flutter/flutter/issues/7053 on the Flutter side. If this is important to you, please consider adding a 'thumbs-up' on the topmost comment in that bug.

Closing this in favor of https://github.com/dart-lang/sdk/issues/34452 which is now also closed as Dart now has FFI and C interop support, as well as experimental support for Objective-C. You can find an overview at https://dart.dev/interop/c-interop.
Thanks all! If you'd like to see further improvements, check out the https://github.com/dart-lang/sdk/labels/library-ffi label for currently tracked work or open a new issue :)


Refactor Scout Objects

Refactor scouts. Possibly make behavior more mix-in-ish? Like ironic drivers.

Scouts will mainly have two main areas of behavior:
* Gathering data from sources like ironic, nova, glance
* Performing the actual work of issuing directives to endpoints

Decided to refactor a bit in this PR: https://github.com/rackerlabs/arsenal/pull/75
Instead of doing mixins, I just distilled Openstack-related scout behavior into its own class. Breaking it into smaller pieces didn't really make sense. Unless someone else comes up with a use case for arsenal that breaks this assumption, calling this done for now.


[MINOR] Cleaning up recently introduced configs

Change Logs
Cleaning up some of the recently introduced configs:

Shortening file-listing mode override for Spark's FileIndex
Fixing Disruptor's write buffer limit config
Scoped CANONICALIZE_NULLABLE config to HoodieSparkSqlWriter

Impact
N/A
Risk level (write none, low medium or high below)
N/A
Documentation Update
Describe any necessary documentation update if there is any new feature, config, or user-facing change

The config description must be updated if new configs are added or the default value of the configs are changed
Any new feature or user-facing change requires updating the Hudi website. Please create a Jira ticket, attach the
ticket number here and follow the instruction to make
changes to the website.

Contributor's checklist

[ ] Read through contributor's guide
[ ] Change Logs and Impact were stated clearly
[ ] Adequate tests were added if applicable
[ ] CI passed

rebased w/ latest master.

CI is failing due to a flaky test (multi-writer DeltaStreamer)


RFC: Add a reproduction-template

Describe the feature
Add a nuxt-auth reproduction template, e.g., via CodeSandbox or StackBlitz.
This could also have dual use: Act as a reproduction template and a playground where users can test out the module.
Additional information
Thanks to @JoaoPedroAS51 for the idea ❤ 💯

closed as part of cleanup (:


Incorrect order of steps in "Install and Use Packages" Section of "Getting Started with Python" Tutorial

Type: Bug

Go to the "Install and Use Packages" section of the "Getting Started with Python" tutorial on the Visual Studio Code website.
Follow the instructions to create standardplot.py.
Follow the instructions to create a virtual environment.
Follow the instructions to select the virtual environment.
Follow the instructions to install the matplotlib package using the pip command.

Issue:
In the current version of the tutorial, the user is instructed to open a new Terminal before creating and selecting the virtual environment. This results in the pip command being executed in the wrong shell, causing errors.
Suggested Solution:
To fix this issue, I suggest moving the instructions for opening a new Terminal to the beginning of step 3 in the tutorial. This way, Visual Studio Code will activate the newly created environment as part of starting a new Terminal, and the user will be able to execute the pip command in the correct shell.
I also suggest instructing the user to close any open Terminals before selecting the newly created environment to eliminate any possible confusion over shells in which the environment isn't activated.
Relevant paragraph to be moved and reworded accordingly:
To install the matplotlib package (which also installs numpy as a dependency), stop the debugger and use the Command Palette to run Terminal: Create New Terminal (Ctrl+Shift+`). This command opens a command prompt for your selected interpreter.
VS Code version: Code - Insiders 1.78.0-insider (e410e7c66e7ce5c6bc31f73150d66857804a0ee9, 2023-04-28T12:24:36.251Z)
OS version: Linux x64 6.2.13-arch1-1
Modes:
Sandboxed: Yes

System Info

Item
Value

CPUs
12th Gen Intel(R) Core(TM) i5-12400F (12 x 3933)

GPU Status
2d_canvas: enabledcanvas_oop_rasterization: disabled_offdirect_rendering_display_compositor: disabled_off_okgpu_compositing: enabledmultiple_raster_threads: enabled_onopengl: enabled_onrasterization: enabledraw_draw: disabled_off_okvideo_decode: enabledvideo_encode: disabled_softwarevulkan: disabled_offwebgl: enabledwebgl2: enabledwebgpu: disabled_off

Load (avg)
0, 0, 0

Memory (System)
15.41GB (12.65GB free)

Process Argv
--unity-launch --crash-reporter-id 6f9ecae6-9cad-4618-b120-b533d5e45c38

Screen Reader
no

VM
0%

DESKTOP_SESSION
i3-with-shmlog

XDG_CURRENT_DESKTOP
undefined

XDG_SESSION_DESKTOP
undefined

XDG_SESSION_TYPE
x11

Thanks for creating this issue. We think this issue is unactionable or unrelated to the goals of this project. Please follow our issue reporting guidelines.
Happy Coding!

/extPython