Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

plans for 1.0.0 #4

Open
funny-cat-happy opened this issue Aug 23, 2023 · 12 comments
Open

plans for 1.0.0 #4

funny-cat-happy opened this issue Aug 23, 2023 · 12 comments
Labels
Milestone

Comments

@funny-cat-happy
Copy link
Owner

funny-cat-happy commented Aug 23, 2023

Current Issue

httpx package is very big and has so many dependency.
Not support for tls to send message to apple server.

Future Plan

If so many people use it and have feedback,I will fix it and add some features.

@funny-cat-happy funny-cat-happy pinned this issue Aug 23, 2023
@funny-cat-happy funny-cat-happy added this to the 0.2.0 milestone Aug 23, 2023
@lianlongbagua
Copy link

yes please add support, plus ive ran into problem the app says "incorrect token" now.

@funny-cat-happy
Copy link
Owner Author

yes please add support, plus ive ran into problem the app says "incorrect token" now.

Do you copy from your bark app of iphone right?And can you show your code?

@lianlongbagua
Copy link

yes i copied exactly. the code is your sample code of your hello world.
using aliyun ubuntu 22 in the .venv environment python 3.10
only problem might be that i also installed bark-cli?

@funny-cat-happy
Copy link
Owner Author

yes i copied exactly. the code is your sample code of your hello world. using aliyun ubuntu 22 in the .venv environment python 3.10 only problem might be that i also installed bark-cli?

The device id is a 64-letter string. Is it right? And can you send the detail of the error message?

@lianlongbagua
Copy link

Traceback (most recent call last): File "/root/rqd_arcticdb/barktest.py", line 4, in <module> bark.send(title="welcome", content="hello world") File "/root/rqd_arcticdb/.another_venv/lib/python3.10/site-packages/BarkNotificator/barknotificator.py", line 95, in send raise BarkNotificatorException(response.text) BarkNotificator.exception.BarkNotificatorException: {"reason":"InvalidProviderToken"}

@funny-cat-happy
Copy link
Owner Author

Traceback (most recent call last): File "/root/rqd_arcticdb/barktest.py", line 4, in <module> bark.send(title="welcome", content="hello world") File "/root/rqd_arcticdb/.another_venv/lib/python3.10/site-packages/BarkNotificator/barknotificator.py", line 95, in send raise BarkNotificatorException(response.text) BarkNotificator.exception.BarkNotificatorException: {"reason":"InvalidProviderToken"}

I test in my ubuntu 3.10 python server.It works normally.Maybe you installed another package that caused a conflict. Maybe your device id is wrong.

@lianlongbagua
Copy link

lianlongbagua commented Nov 7, 2023 via email

@lianlongbagua
Copy link

Traceback (most recent call last): File "/root/rqd_arcticdb/barktest.py", line 4, in <module> bark.send(title="welcome", content="hello world") File "/root/rqd_arcticdb/.another_venv/lib/python3.10/site-packages/BarkNotificator/barknotificator.py", line 95, in send raise BarkNotificatorException(response.text) BarkNotificator.exception.BarkNotificatorException: {"reason":"InvalidProviderToken"}

I test in my ubuntu 3.10 python server.It works normally.Maybe you installed another package that caused a conflict. Maybe your device id is wrong.

OK after some testing i found what something very strange. given my coding ability i'm unable to solve that puzzle.

  1. When i ran in my local environment (windows plus python 3.10 with venv) with vpn on, in a jupyter notebook in vscode, the push notification works fine.
  2. when i ran it as a standalone script on cloud server it produces the abovementioned error message.
  3. when i ran in my local without vpn in jupyter notebook, it still works.
  4. when i ran in my local as a script with or without vpn, it fails and produces the following message:
    File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\httpcore_exceptions.py", line 10, in map_exceptions
    yield
    File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\httpcore_backends\sync.py", line 168, in start_tls
    raise exc
    File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\httpcore_backends\sync.py", line 163, in start_tls
    sock = ssl_context.wrap_socket(
    File "e:\veighna_elite_simulation\lib\ssl.py", line 513, in wrap_socket
    return self.sslsocket_class._create(
    File "e:\veighna_elite_simulation\lib\ssl.py", line 1071, in _create
    self.do_handshake()
    File "e:\veighna_elite_simulation\lib\ssl.py", line 1342, in do_handshake
    self._sslobj.do_handshake()
    TimeoutError: _ssl.c:980: The handshake operation timed out

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\httpx_transports\default.py", line 66, in map_httpcore_exceptions
yield
File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\httpx_transports\default.py", line 228, in handle_request
resp = self._pool.handle_request(req)
File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\httpcore_sync\connection_pool.py", line 268, in handle_request
raise exc
File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\httpcore_sync\connection_pool.py", line 251, in handle_request
response = connection.handle_request(request)
File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\httpcore_sync\http_proxy.py", line 317, in handle_request
stream = stream.start_tls(**kwargs)
File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\httpcore_backends\sync.py", line 152, in start_tls
with map_exceptions(exc_map):
File "e:\veighna_elite_simulation\lib\contextlib.py", line 153, in exit
self.gen.throw(typ, value, traceback)
File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\httpcore_exceptions.py", line 14, in map_exceptions
raise to_exc(exc) from exc
httpcore.ConnectTimeout: _ssl.c:980: The handshake operation timed out

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "e:\GitHub\vectorbt_learning\tutorio.py", line 5, in
bark.send(title="welcome", content="hello world")
File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\BarkNotificator\barknotificator.py", line 89, in send
response = client.post(
File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\httpx_client.py", line 1132, in post
return self.request(
File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\httpx_client.py", line 814, in request
return self.send(request, auth=auth, follow_redirects=follow_redirects)
File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\httpx_client.py", line 901, in send
response = self._send_handling_auth(
File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\httpx_client.py", line 929, in _send_handling_auth
response = self._send_handling_redirects(
File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\httpx_client.py", line 966, in _send_handling_redirects
response = self._send_single_request(request)
File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\httpx_client.py", line 1002, in _send_single_request
response = transport.handle_request(request)
File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\httpx_transports\default.py", line 227, in handle_request
with map_httpcore_exceptions():
File "e:\veighna_elite_simulation\lib\contextlib.py", line 153, in exit
self.gen.throw(typ, value, traceback)
File "E:\GitHub\vectorbt_learning.venv\lib\site-packages\httpx_transports\default.py", line 83, in map_httpcore_exceptions
raise mapped_exc(message) from exc
httpx.ConnectTimeout: _ssl.c:980: The handshake operation timed out
This is indeed very strange. would appreciate if you could tell me what went wrong.

@lianlongbagua
Copy link

specifically the only variable here seems to be whether its running inside a jupyter kernel or not.
but the kernel and the interpreter i used to run the script are identical: i.e. the python.exe from .venv/bin

@lianlongbagua
Copy link

OK i got it.
命名空间的问题

@allinu
Copy link
Contributor

allinu commented Jun 25, 2024

@funny-cat-happy Hello, you have update code with new options but not publish it pipy, when use pip to install it, there no new options

@funny-cat-happy funny-cat-happy changed the title plans for 0.2.0 plans for 1.0.0 Jun 27, 2024
@funny-cat-happy
Copy link
Owner Author

@funny-cat-happy Hello, you have update code with new options but not publish it pipy, when use pip to install it, there no new options

It has updated now

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

No branches or pull requests

3 participants