mirror of
https://github.com/thecyberlearn/chat-backend.git
synced 2026-08-18 22:32:53 +00:00
Features: - Django REST API backend - Multi-strategy web scraping system (Beautiful Soup, Playwright, Firecrawl) - Anti-detection features (proxy rotation, user-agent rotation) - Data export functionality (JSON, CSV, TXT) - Business and CrawledPage models - Enhanced crawling service with fallback mechanisms 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
11 lines
435 B
Python
11 lines
435 B
Python
from django.db.migrations.serializer import BaseSerializer
|
|
|
|
|
|
class RangeSerializer(BaseSerializer):
|
|
def serialize(self):
|
|
module = self.value.__class__.__module__
|
|
# Ranges are implemented in psycopg2._range but the public import
|
|
# location is psycopg2.extras.
|
|
module = "psycopg2.extras" if module == "psycopg2._range" else module
|
|
return "%s.%r" % (module, self.value), {"import %s" % module}
|