Commit Graph

28 Commits

Author SHA1 Message Date
Hassan Raza
033bcda99d Hraza/add embargo restricted country (#36398)
* feat: add country disabling feature in embargo app

* revert: disabled countries list in env

* fix: resolved linter issues

---------

Co-authored-by: Hassan Raza <h.raza@192.168.1.12>
2025-03-19 12:22:45 +05:00
Ahtisham Shahid
e7100d813f Revert "feat: refactor country disable logic into the Embargo app (#36202)" (#36393)
This reverts commit 72959ad9d5.
2025-03-17 23:55:59 +05:00
Hassan Raza
72959ad9d5 feat: refactor country disable logic into the Embargo app (#36202)
* feat: add country disabling feature in embargo app

* revert: disabled countries list in env

* fix: resolved linter issues

---------

Co-authored-by: Hassan Raza <h.raza@192.168.1.12>
2025-03-17 16:07:18 +05:00
Michael Terry
b8ecfed67d fix: use safer ip-chain logic when checking ip for embargos
Specifically:
- check ALL ip addresses in the client ip chain for blocking
- check RIGHTMOST ip address in the client ip chain for allowing

Before, we always checked the LEFTMOST ip address in both cases.

AA-1234
2022-04-22 11:15:02 -04:00
M. Zulqarnain
834dabb399 feat: New codemods on OpenedX 2 (#28777) 2021-10-28 16:45:53 +05:00
Awais Qureshi
b58832c8a6 chore: Django3 has removed python_2_unicode_compatible.
Execute the codemodes.
2021-07-26 23:43:54 +05:00
Usama Sadiq
46993bff00 refactor: pyupgrade second iteration (#27461) 2021-05-11 11:24:07 +05:00
Usama Sadiq
918c44e499 refactor: Ran pyupgrade on openedx/core/djangoapps/embargo (#26911) 2021-03-18 18:38:09 +05:00
Feanil Patel
6e3fe00fff Fix all E303 pep8 errors. 2019-12-30 12:25:38 -05:00
Feanil Patel
9cf2f9f298 Run 2to3 -f future . -w
This will remove imports from __future__ that are no longer needed.

https://docs.python.org/3.5/library/2to3.html#2to3fixer-future
2019-12-30 10:35:30 -05:00
Awais Qureshi
82fb16b2f7 BOM-981,983,984
Fixing migrations.
2019-10-24 14:53:39 +05:00
Ayub khan
5c47a3b425 BOM Project
Updated __unicode__ to __str__
2019-09-25 18:31:54 +05:00
Awais Qureshi
75b5fffb87 BOM-584
Fixing python3
2019-09-20 16:11:47 +05:00
Awais Qureshi
718fb0f5b8 BOM-585
Fixing python3
2019-09-20 16:03:28 +05:00
aarif
13f9609386 python 3 fixes 2019-09-17 19:13:16 +05:00
Peter Pinch
4f807dd702 INCR-155 Modernize openedx/core/djangoapps/video_config (#20408)
* run modernizer on openedx/core/djangoapps/embargo/

* sorting imports

* sort imports

* docstring

* try removing pylint disable
2019-05-06 16:43:42 -04:00
Julia Eskew
368f221f0a Initial start on annotations. 2019-02-19 11:24:21 -05:00
Matthew Piatetsky
f294b1a374 fix unicode strings in openedx/ part 1 2019-02-13 10:47:35 -05:00
singuliere
d00cb9bda8 INCR-40 use ipaddress instead of ipaddr 2019-02-09 13:10:06 +01:00
Jeremy Bowman
d90afa4cde TE-2689 Remove useless pylint suppressions part 5 2018-08-21 11:07:52 -04:00
Tyler Hallada
1f42d1b384 Merge pull request #18316 from edx/thallada/PLAT-1524-on-delete
PLAT-1524: Add on_delete kwarg to ForeignKey & OneToOneFields
2018-06-06 10:38:15 -04:00
Tyler Hallada
1540f9ec72 Add on_delete kwarg to ForeignKey & OneToOneFields
Django 2.0 will make this field required for `ForeignKey` and `OneToOneFields`.
In previous versions the option defaulted to `models.CASCADE` when not
specified. This change should make the deprecation warnings in the current
Django version go away.

The migrations where also modified, but the changes should not cause a change in
the database schema since `models.CASCADE` was already the old default.
2018-06-05 17:05:12 -04:00
Eric Fischer
247bb50ed2 s/django.core.urlresolvers/django.urls/g
Django 1.10 deprecation fix for Hackathon XIX
Addresses PLAT-1397
2018-06-05 13:59:09 -04:00
Jeremy Bowman
bf86b3da98 PLAT-1942 Handle xmodule_django field deprecations 2018-02-05 15:05:54 -05:00
Jeremy Bowman
669aa13ad6 PLAT-1873 to_deprecated_string() cleanup part 2 2018-01-08 17:26:55 -05:00
Ivan Ivic
6e45f00041 Created new embargo check api
LEARNER-1523
LEARNER-1524
2017-06-26 15:02:04 -04:00
Andy Armstrong
93235d118d Reorder imports using isort (except lms and cms) 2017-05-30 16:04:54 -04:00
John Eskew
e3cb462d18 Move embargo from common to openedx/core/djangoapps. 2016-11-07 08:47:36 -05:00