thảo luận [Python] Thread dành cho anh em Python

Ở đây có bác nào có bộ sách nào nên đọc nhất về python không các bác, trình độ python của em chỉ mới tới mức là nhập xuất dữ liệu ra file thôi các bác ạ
level intermediate: +1 vote cho "Python Tricks: A Buffet of Awesome Python Features"
high: có cuốn Fluent Python của Oreilly
 
bác nào có tài liệu về cái Selenium k cho em xin nghiên cứu với ạ đag tính làm 1 con bot book vé hoặc đăng kí tín chỉ mà bt làm từ đâu :)
 
from selenium import webdriver
from selenium.webdriver.chrome.options import Options
from webdriver_manager.chrome import ChromeDriverManager

# Set Chrome options for running in headless mode
options = Options()
options.headless = True

# Initialize Chrome WebDriver
driver = webdriver.Chrome(ChromeDriverManager().install(), options=options)

url = 'https://capaiankinerja.presidenri.go.id/arsip/lima-tahun-maju-bersama'

params = {'behavior': 'allow', 'downloadPath': '[folder path]'}
driver.execute_cdp_cmd('Page.setDownloadBehavior', params)

driver.get(url)

web no điều hướng them cai ten file pdf nữa đó. Muốn nhanh thím tìm cách lấy ten file đó ra rồi chay cmd như dưới là dc

wget https://capaiankinerja.presidenri.g...019_Laporan-5-Tahun-Jokowi-JK_small-1--1-.pdf
Thím ơi em mới mò selenium nó bị lỗi out chrome khi vừa load trang web xong.
Có gg đủ kiểu thêm options detach các kiểu mà vẫn không hết, có cách nào fix lỗi này không vậy :(
 
Vứt code lên đây
import selenium
from selenium import webdriver
from selenium.webdriver.chrome.options import Options
chrome_options = Options()
chrome_options.add_experimental_option("detach", True)
driver = webdriver.Chrome(options=chrome_options)
driver.get("https://www.google.com/")
Code bình thường thôi thím, chỉ là mở url mà lỗi vừa mở ra được mất giây đã tự đóng chrome
 
làm sao để chạy code python trên ubuntu khi tắt chương trình putty mấy bác nhỉ. em kết nối ubuntu bằng putty, xong chạy lên. nhưng tắt putty là nó dừng chương trình luôn.
 
Hiện tại em đã học được C/C++ và Java, đã có kiến thức nền về NNLT kia thì bây giờ em nhảy sang Python nên đọc nguồn tài liệu nào để nắm được các cấu trúc lệnh của Python ạ?
 
SENIOR PYTHON - Min 2000$
Làm ở Viettel Building Q10

  • You have 4+ years of experience in backend development using Python and have worked confidently within teams delivering data driven systems.
  • You have knowledge of scaling practices such as in-memory databases, load balancing, caching, etc.
  • You’re comfortable with both NoSQL and SQL databases.
  • You have 3+ years experience in deploying systems on GCP or AWS and knowledge of containerization (e.g. Docker)
  • You can give and take in discussions and make tactical decisions to reduce risk when delivering functionality, which is the primary measure of progress.
  • You’re a team player who is solutions oriented.
  • Experience in leading a team or mentoring younger developers will be highly regarded
  • You have deep exposure to ETL and ELT.
  • Having wide exposure to multiple technology stacks is an advantage, we love full-stack engineers.
  • You’re proficient in code review, code refactoring, Unit Testing.
  • Backend security knowledge is a plus
  • Good communication in English is a plus.
có hộp hok bác
 
làm sao để chạy code python trên ubuntu khi tắt chương trình putty mấy bác nhỉ. em kết nối ubuntu bằng putty, xong chạy lên. nhưng tắt putty là nó dừng chương trình luôn.
thêm dấu & ở cuối để chạy ngầm
muốn chạy bao nhiu cũng dc
python script_a.py & ;
python script_b.py & ;

Còn muốn chạy theo định kỳ thì google cronjob
cai này linux ,ko lien quan gì python cả
 
Có cái nào học đa luồng dễ hiểu ko các fen, học mãi hem làm đc buồn ghê
Bác dùng đa luồng cho phần gì thế. Em thấy đa luồng chủ yếu nó gọi nhiều worker vào r mình đẩy task lên queue. Nên bác cứ đẩy nhiều task lên queue r cho bao nhiêu worker xử lý trên cái queue đấy.
 
Back
Top