Skip to main content

Beryllium Package

This is beryllium package. You can use beryllium to write your lean.

Installation

pip install beryllium

Beryllium Demo

# -*- coding: utf-8 -*-

from beryllium import Beryllium
import time
from beryllium import FieldList, Field, FieldName, Page, ListCssSelector, Mongodb, NextPageCssSelectorSetup, PageFunc
bery = Beryllium()
bery.driver = bery.get_driver()
bery.fast_get_page("https://www.baidu.com")
time.sleep(1)
bery.until_send_text_by_css_selector(css_selector="#kw", text="杭州")
bery.until_send_enter_by_css_selector(css_selector="#kw")
time.sleep(2)

fieldlist_shop = FieldList(
    Field(field_name=FieldName.SHOP_NAME, css_selector="h3"),
)
page_shop = Page(name="shop_page",
                 field_list=fieldlist_shop,
                 list_css_selector=ListCssSelector(list_css_selector="#content_left > div.result.c-container"))

bery.until_click_no_next_page_by_css_selector(
    next_page_setup=NextPageCssSelectorSetup(
        page=page_shop,
        css_selector="#page > a.n",
        main_page_func=PageFunc(func=bery.from_page_get_data_list, page=page_shop)
    )
)

Demonstration

Outlook

Committed to creating an interactive crawler library. I hope programmers with the same desire to join my development. You can contact me by email: wujunleiwang@gmail.com

Metadata

Release files for beryllium 1.0.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for beryllium 1.0.4
File Size Uploaded Provenance Actions
beryllium-1.0.4.tar.gz 23.9 kB Without provenance Details for beryllium-1.0.4.tar.gz

Release files / beryllium-1.0.4.tar.gz

Download URL beryllium-1.0.4.tar.gz
Size 23.9 kB
Tags Source
SHA-256 checksum
How to use checksums
d8560a46048167d7f7ef3d49d7b0edcd3c2e961aa7fcfa57dedb86b2b18af649
BLAKE2b-256 checksum
How to use checksums
a2dfb96cba8247f9dce9c763d622a15b8bfcb2bce40726f878ae84963b26cc63
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.11.0 pkginfo/1.4.2 requests/2.21.0 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.7

Security for beryllium 1.0.4

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page