1. 08 Apr, 2020 4 commits
  2. 31 Mar, 2020 2 commits
  3. 30 Mar, 2020 6 commits
  4. 05 Dec, 2019 5 commits
  5. 26 Jun, 2019 1 commit
  6. 05 Apr, 2019 1 commit
    • Denis Laxalde's avatar
      Drop python2 support · 26744ad37953
      Denis Laxalde authored
      This mostly consists in removing the dependency on "six" and updating
      the code to use only Python3 idioms.
      Notice that we previously used TemporaryDirectory from
      cubicweb.devtools.testlib for compatibility with Python2. We now
      directly import it from tempfile.
  7. 22 Mar, 2019 1 commit
    • Denis Laxalde's avatar
      Drop more deprecated code · 85194bd49119
      Denis Laxalde authored
      This follows up on changeset a8c1ea390400, in which code deprecated
      using logilab.common.deprecation got dropped. Now we also drop code
      deprecated using stdlib's warn(<msg>, DeprecationWarning).
      Notice that, as a consequence of dropping old/new etypes aliases in
      cubicweb/schema.py, we drop the import ETYPE_NAME_MAP (no longer
      needed); but since other modules imported that name from
      cubicweb.schema, we need to update the import statement to use
      "cubicweb" directly.
  8. 14 Mar, 2019 1 commit
    • Denis Laxalde's avatar
      Drop most of deprecated code · a8c1ea390400
      Denis Laxalde authored
      As in previous changesets, most code has been deprecated since a very
      long time. This changeset concerns "core" cubicweb modules
      (e.g. "server", "appobjects") for which it's not easy to handle change
      In cubicweb/server/querier.py, we adjust empty_rset() function as a
      result of "rqlst" argument of ResultSet being dropped. (There was no use
      of the keyword argument anyways.)
  9. 30 Nov, 2017 1 commit
  10. 12 Apr, 2017 2 commits
  11. 05 Apr, 2017 1 commit
    • Denis Laxalde's avatar
      [server] Add source_by_eid and source_by_uri methods to repository · d540defa0591
      Denis Laxalde authored
      Most of the times we only need to retrieve one source (either by uri or eid)
      and querying sources_by_eid and sources_by_uri properties on repository just
      for one item is costly. So these methods query what's needed. We issue a
      ValueError (instead of KeyError for sources_by_{eid,uri} dict) in case the key
      is not found.
      branch : 3.25
  12. 04 Apr, 2017 1 commit
    • Denis Laxalde's avatar
      [server] Make "sources_by_uri" and "sources_by_eid" properties of repository · db2fc87348ab
      Denis Laxalde authored
      I.e. do not populate these dict as repo initialization (bootstrap step) but
      always use information from database. This is needed because when multiple
      instances of the same application run, if one instance adds a CWSource the
      other ones will not see it. In particular, when using a scheduler instance,
      new CWSource will be added by the web instance and not seen by the scheduler
      which is supposed to update them.
      We thus define properties for sources_by_eid and sources_by_uri instead
      attributes on repository instance. CWSource entities are thus retrieved from
      database every time these properties are accessed. We factor out
      initialization of the "source" instance (subclass of
      cubicweb.server.source.AbstractSource) in a _sources() method. Note that this
      method takes care of calling "init" method on the source as well as
      "set_schema" (previously done in repo.set_schema(), which now only touches
      system_source). Accordingly the "init_sources_from_database" method is dropped
      along with "add_source"/"remove_source" methods.
      In syncsources hook, we thus drop:
      * SourceAddedOp operation which called repo.add_source() so that the
        SourceAddedHook only cares about checking source configuration now;
      * SourceRemovedOp and SourceRenamedOp operations for the same reason;
      * SourceConfigUpdatedOp as updating the live config of source is
        meaningless once we rely on them being retrieved from the database;
      * SourceHostConfigUpdatedHook hook which is now useless without call to
      In 3.10 migration script, remove usage of sources_by_uri repo attribute which,
      unless I'm missing something, appears useless (at least now).
      In tests:
      * unittest_datafeed: remove test_update_url method since we dropped respective
      * unittest_ldapsource: LDAPFeedUserDeletionTC.test_a_filter_inactivate()
        currently fails because it still relies on live config being updated, this
        will be fixed in the next changeset once all "live source" logic will be
      branch : 3.25
  13. 17 Mar, 2017 1 commit
  14. 15 Mar, 2017 1 commit
  15. 03 Mar, 2017 1 commit
  16. 15 Mar, 2017 2 commits
  17. 03 Mar, 2017 1 commit
  18. 10 Mar, 2017 1 commit
  19. 14 Mar, 2017 1 commit
    • Sylvain Thénault's avatar
      Stop using Session on the repository side · b8d2e6b9f548
      Sylvain Thénault authored
      Only expect session on web request, and let the web session/authentication
      managers provide them.
      Access to cnx.data, which used to return session data, is deprecated: there is
      no more access to session data from the repository side, and they should be
      access from req.session.data from the web side.
  20. 10 Mar, 2017 6 commits