forked from pool/python-primp
Accepting request 1196118 from home:yeey:OpenWebUI
- Version v0.6.0 * CI: bugfix after dependencies update by @deedy5 * Use anyhow for error handling by @deedy5 * Improve response code by @deedy5 * [Client]: add ca_cert_file parameter by @deedy5 * [Utils] Recode fn json_dumps, json_loads, url_encode by @deedy5 * [html2text] Response object: 1) add attribute text_rich * [logging]: send Rust log messages to Python * small code improvements OBS-URL: https://build.opensuse.org/request/show/1196118 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-primp?expand=0&rev=1
This commit is contained in:
23
.gitattributes
vendored
Normal file
23
.gitattributes
vendored
Normal file
@@ -0,0 +1,23 @@
|
||||
## Default LFS
|
||||
*.7z filter=lfs diff=lfs merge=lfs -text
|
||||
*.bsp filter=lfs diff=lfs merge=lfs -text
|
||||
*.bz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.gem filter=lfs diff=lfs merge=lfs -text
|
||||
*.gz filter=lfs diff=lfs merge=lfs -text
|
||||
*.jar filter=lfs diff=lfs merge=lfs -text
|
||||
*.lz filter=lfs diff=lfs merge=lfs -text
|
||||
*.lzma filter=lfs diff=lfs merge=lfs -text
|
||||
*.obscpio filter=lfs diff=lfs merge=lfs -text
|
||||
*.oxt filter=lfs diff=lfs merge=lfs -text
|
||||
*.pdf filter=lfs diff=lfs merge=lfs -text
|
||||
*.png filter=lfs diff=lfs merge=lfs -text
|
||||
*.rpm filter=lfs diff=lfs merge=lfs -text
|
||||
*.tbz filter=lfs diff=lfs merge=lfs -text
|
||||
*.tbz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.tgz filter=lfs diff=lfs merge=lfs -text
|
||||
*.ttf filter=lfs diff=lfs merge=lfs -text
|
||||
*.txz filter=lfs diff=lfs merge=lfs -text
|
||||
*.whl filter=lfs diff=lfs merge=lfs -text
|
||||
*.xz filter=lfs diff=lfs merge=lfs -text
|
||||
*.zip filter=lfs diff=lfs merge=lfs -text
|
||||
*.zst filter=lfs diff=lfs merge=lfs -text
|
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@@ -0,0 +1 @@
|
||||
.osc
|
24
_service
Normal file
24
_service
Normal file
@@ -0,0 +1,24 @@
|
||||
<services>
|
||||
<service mode="disabled" name="obs_scm">
|
||||
<param name="url">https://github.com/deedy5/primp</param>
|
||||
<param name="versionformat">@PARENT_TAG@</param>
|
||||
<param name="scm">git</param>
|
||||
<param name="revision">v0.6.0</param>
|
||||
<param name="match-tag">*</param>
|
||||
<param name="versionrewrite-pattern">v(\d+\.\d+\.\d+)</param>
|
||||
<param name="versionrewrite-replacement">\1</param>
|
||||
<param name="changesgenerate">enable</param>
|
||||
<param name="changesauthor">mbelur@suse.com</param>
|
||||
</service>
|
||||
<service mode="disabled" name="tar" />
|
||||
<service mode="disabled" name="recompress">
|
||||
<param name="file">*.tar</param>
|
||||
<param name="compression">xz</param>
|
||||
</service>
|
||||
<service mode="disabled" name="set_version"/>
|
||||
<service name="cargo_vendor" mode="disabled">
|
||||
<param name="src">primp</param>
|
||||
<param name="compression">xz</param>
|
||||
<param name="update">true</param>
|
||||
</service>
|
||||
</services>
|
3
primp-0.6.0.tar.xz
Normal file
3
primp-0.6.0.tar.xz
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:8df5739f6171f3a95d61c508638c210a56c1214dc754f84f232d1900fc49ae74
|
||||
size 70228
|
12
python-primp.changes
Normal file
12
python-primp.changes
Normal file
@@ -0,0 +1,12 @@
|
||||
-------------------------------------------------------------------
|
||||
Fri Aug 23 23:12:23 UTC 2024 - Guang Yee <gyee@suse.com>
|
||||
|
||||
- Version v0.6.0
|
||||
* CI: bugfix after dependencies update by @deedy5
|
||||
* Use anyhow for error handling by @deedy5
|
||||
* Improve response code by @deedy5
|
||||
* [Client]: add ca_cert_file parameter by @deedy5
|
||||
* [Utils] Recode fn json_dumps, json_loads, url_encode by @deedy5
|
||||
* [html2text] Response object: 1) add attribute text_rich
|
||||
* [logging]: send Rust log messages to Python
|
||||
* small code improvements
|
74
python-primp.spec
Normal file
74
python-primp.spec
Normal file
@@ -0,0 +1,74 @@
|
||||
#
|
||||
# spec file for package python-primp
|
||||
#
|
||||
# Copyright (c) 2024 SUSE LLC
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
# upon. The license for this file, and modifications and additions to the
|
||||
# file, is the same license as for the pristine package itself (unless the
|
||||
# license for the pristine package is not an Open Source License, in which
|
||||
# case the license is the MIT License). An "Open Source License" is a
|
||||
# license that conforms to the Open Source Definition (Version 1.9)
|
||||
# published by the Open Source Initiative.
|
||||
|
||||
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
||||
#
|
||||
|
||||
%{?sle15_python_module_pythons}
|
||||
Name: python-primp
|
||||
Version: 0.6.0
|
||||
Release: 0
|
||||
Summary: HTTP client that can impersonate web browsers
|
||||
License: MIT
|
||||
URL: https://github.com/deedy5/primp
|
||||
Source0: https://files.pythonhosted.org/packages/source/p/primp/primp-%{version}.tar.xz
|
||||
Source1: vendor.tar.xz
|
||||
BuildRequires: python-rpm-macros
|
||||
BuildRequires: %{python_module maturin >= 1.5}
|
||||
BuildRequires: %{python_module pip}
|
||||
BuildRequires: cmake
|
||||
BuildRequires: clang-devel
|
||||
BuildRequires: gcc-c++
|
||||
BuildRequires: git
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: cargo-packaging
|
||||
BuildRequires: llvm
|
||||
BuildRequires: openssl
|
||||
|
||||
%python_subpackages
|
||||
|
||||
%description
|
||||
The fastest python HTTP client that can impersonate web browsers, mimicking
|
||||
their headers and 'TLS/JA3/JA4/HTTP2' fingerprints
|
||||
|
||||
%prep
|
||||
%autosetup -p1 -n primp-%{version} -a1
|
||||
|
||||
%build
|
||||
export CARGO_NET_OFFLINE=true
|
||||
export CARGO_PROFILE_RELEASE_DEBUG=full
|
||||
export CARGO_PROFILE_RELEASE_SPLIT_DEBUGINFO=off
|
||||
export CARGO_PROFILE_RELEASE_STRIP=false
|
||||
export C_INCLUDE_PATH=/usr/lib64/gcc/%_arch-suse-linux/%gcc_version/include
|
||||
%pyproject_wheel
|
||||
|
||||
%install
|
||||
export CARGO_NET_OFFLINE=true
|
||||
export CARGO_PROFILE_RELEASE_DEBUG=full
|
||||
export CARGO_PROFILE_RELEASE_SPLIT_DEBUGINFO=off
|
||||
export CARGO_PROFILE_RELEASE_STRIP=false
|
||||
%pyproject_install
|
||||
%python_expand %fdupes %{buildroot}%{$python_sitearch}
|
||||
|
||||
%check
|
||||
# NOTE: don't run the tests as they required access to internet by trying to
|
||||
# connect to "https://httpbin.org/anything".
|
||||
|
||||
%files %{python_files}
|
||||
%doc README.md
|
||||
%license LICENSE
|
||||
%{python_sitearch}/primp
|
||||
%{python_sitearch}/primp-%{version}*-info
|
||||
|
||||
%changelog
|
3
vendor.tar.xz
Normal file
3
vendor.tar.xz
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:dc063aebec0d3e46e8de5cc3f0534faae7897491dacdd78949949f4f3edd4ed3
|
||||
size 21739420
|
Reference in New Issue
Block a user