text:
Stack using Queues | C

Stack using Queues
what will change -
I’d like to add a stack implementation using queues in C language under data structures.
Type of Issue -

[x] Adding New Code

Programming Language

[x] C

Self Check

Ask for issue assignment before making Pull Request.
Add your file in the proper folder
Clean Code and Documentation for better readability
Add Title and Description of the program in the file

:star2: Star it :fork_and_knife:Fork it :handshake: Contribute to it!
Happy Coding!

@Aron-R can you please assign it to me ?

@Aron-R can you please assign it to me ?

I don’t think I can assign this to anyone, The CONTRIBUTIONS.md file said that if I thought something is missing, I can create an issue and so I’ve created an issue and if they happen to assign it to me I would work on it


text:
优化语言表述

“特别地”应该用“特别的”
使用“，”断句
优化语言表述

非常感谢你对《动手学深度学习》一书的贡献。等明年初纸质书出版时，出版社将为贡献者制作并赠送本书的专享版。我们也希望在本书致谢（http://zh.diveintodeeplearning.org/chapter_introduction/preface.html ）中列出你的姓名（出版社希望这周五12月14号前将这部分内容定稿。）能将你的姓名、Github ID 和邮寄地址发送至 gluonbook [AT] gmail [dot] com吗？谢谢。

已经发送邮件，祝社区越来越好！

您好，我只是mxnet和gluon的支持者，暂时还没有做出什么贡献，希望以后能够为社区做出一些贡献。谢谢。发自我的华为手机-------- 原始邮件 --------主题：Re: [diveintodeeplearning/d2l-zh] 优化语言表述 (#447)发件人：Aston Zhang 收件人：diveintodeeplearning/d2l-zh 抄送：Subscribed 非常感谢你对《动手学深度学习》一书的贡献。等明年初纸质书出版时，出版社将为贡献者制作并赠送本书的专享版。我们也希望在本书致谢（http://zh.diveintodeeplearning.org/chapter_introduction/preface.html ）中列出你的姓名（出版社希望这周五12月14号前将这部分内容定稿。）能将你的姓名、Github ID 和邮寄地址发送至 gluonbook [AT] gmail [dot] com吗？谢谢。
—You are receiving this because you are subscribed to this thread.Reply to this email directly, view it on GitHub, or mute the thread.

source: gharchive/pull-request

authors: astonzhang baiziru elliotxx

license_type: permissive

license_source: github-api


text:
フロントエンドへの反映方法に差異がある

【不具合内容】
フロントエンドへのコンテンツ反映方法に差異があります。
例えばニュース一覧画面は即時反映ですが、詳細画面への反映はビルドが必要です。
【修正方法】
https://github.com/diverta/front_nuxt_corporate/blob/main/nuxt.config.ts#L4
// ssr: true,
の部分を
ssr: false,
に変更いただくとCSRになります。
手元で一通り動作確認しておりますが、確認の上修正いただけると嬉しいです。

@HisashiHasebe アーカイブを作るのにマスター使ってると思うのですが、マスター使うのはちょっとテンプレート的にはイマイチかなと。。何かリンクを付与したのであれば、カテゴリで自動でやれると思うのでそっちの方がいい気がする。

@VortexExpansion
Could you change SSG -> CSR
ssr: false,

and please check call API every case
After that make PR with mention to @yabe-diverta
アーカイブの件はCSR後に別Issueで検討・対応 @HisashiHasebe

source: gharchive/issue

authors: KentaKatoh erinanire takel-shiba

license: MIT


text:
Column does not exist in tests with multiple databases

I use multiple databases in my project: master and log_db. When i updated to django-cms==3.1.4 and started the tests, i've got error in 0005_auto_20140924_1039.py migration, when creating test log database:
Creating test database for alias 'default'...
Creating test database for alias 'log_db'...
Traceback (most recent call last):
  File "/home/user/Downloads/pycharm-5.0/helpers/pycharm/django_test_manage.py", line 129, in <module>
    utility.execute()
  File "/home/user/Downloads/pycharm-5.0/helpers/pycharm/django_test_manage.py", line 104, in execute
    PycharmTestCommand().run_from_argv(self.argv)
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/core/management/commands/test.py", line 50, in run_from_argv
    super(Command, self).run_from_argv(argv)
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/core/management/base.py", line 288, in run_from_argv
    self.execute(*args, **options.__dict__)
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/core/management/commands/test.py", line 71, in execute
    super(Command, self).execute(*args, **options)
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/core/management/base.py", line 338, in execute
    output = self.handle(*args, **options)
  File "/home/user/Downloads/pycharm-5.0/helpers/pycharm/django_test_manage.py", line 91, in handle
    failures = TestRunner(test_labels, verbosity=verbosity, interactive=interactive, failfast=failfast, keepdb='--keepdb' in sys.argv)
  File "/home/user/Downloads/pycharm-5.0/helpers/pycharm/django_test_runner.py", line 256, in run_tests
    extra_tests=extra_tests, **options)
  File "/home/user/Downloads/pycharm-5.0/helpers/pycharm/django_test_runner.py", line 156, in run_tests
    return super(DjangoTeamcityTestRunner, self).run_tests(test_labels, extra_tests, **kwargs)
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/test/runner.py", line 147, in run_tests
    old_config = self.setup_databases()
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/test/runner.py", line 109, in setup_databases
    return setup_databases(self.verbosity, self.interactive, **kwargs)
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/test/runner.py", line 299, in setup_databases
    serialize=connection.settings_dict.get("TEST", {}).get("SERIALIZE", True),
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/db/backends/creation.py", line 377, in create_test_db
    test_flush=True,
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/core/management/__init__.py", line 115, in call_command
    return klass.execute(*args, **defaults)
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/core/management/base.py", line 338, in execute
    output = self.handle(*args, **options)
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/core/management/commands/migrate.py", line 161, in handle
    executor.migrate(targets, plan, fake=options.get("fake", False))
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/db/migrations/executor.py", line 68, in migrate
    self.apply_migration(migration, fake=fake)
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/db/migrations/executor.py", line 102, in apply_migration
    migration.apply(project_state, schema_editor)
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/db/migrations/migration.py", line 108, in apply
    operation.database_forwards(self.app_label, schema_editor, project_state, new_state)
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/db/migrations/operations/special.py", line 117, in database_forwards
    self.code(from_state.render(), schema_editor)
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/cms/migrations/0005_auto_20140924_1039.py", line 135, in move_to_mp
    for page in pages:
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/db/models/query.py", line 141, in __iter__
    self._fetch_all()
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/db/models/query.py", line 966, in _fetch_all
    self._result_cache = list(self.iterator())
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/db/models/query.py", line 265, in iterator
    for row in compiler.results_iter():
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/db/models/sql/compiler.py", line 701, in results_iter
    for rows in self.execute_sql(MULTI):
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/db/models/sql/compiler.py", line 787, in execute_sql
    cursor.execute(sql, params)
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/db/backends/utils.py", line 65, in execute
    return self.cursor.execute(sql, params)
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/db/utils.py", line 94, in __exit__
    six.reraise(dj_exc_type, dj_exc_value, traceback)
  File "/home/user/project-env/project/local/lib/python2.7/site-packages/django/db/backends/utils.py", line 65, in execute
    return self.cursor.execute(sql, params)
django.db.utils.ProgrammingError: column cms_page.level does not exist
LINE 1: ...cation_urls", "cms_page"."application_namespace", "cms_page"...
                                                             ^

router:
class UserLoggerRouter(object):

    def db_for_read(self, model, **hints):
        if model._meta.app_label == 'user_logger':
            return 'log_db'
        return None

    def db_for_write(self, model, **hints):
        if model._meta.app_label == 'user_logger':
            return 'log_db'
        return None

    def allow_relation(self, obj1, obj2, **hints):
        if obj1._meta.app_label == 'user_logger' or \
           obj2._meta.app_label == 'user_logger':
           return True
        return None

    def allow_migrate(self, db, model):
        if db == 'log_db':
            return model._meta.app_label == 'user_logger'
        elif model._meta.app_label == 'user_logger':
            return False
        return None

I have this problem too

Thanks for the report @igorkud90 (and @viatoriche). Would you be able to dig into this a little deeper to be more specific about how the CMS is doing something wrong?

I have this problem too.

I had this issue as well. @igorkud90, you are likely using the old style of the allow_migrate method. You should use the new style defined here:
https://docs.djangoproject.com/en/1.9/topics/db/multi-db/

@mvid How did you fix it?
I have the same issue using multiple databases, only difference being I'm not using routers.

@diegoponciano My solution was to update the routers to use the new syntax for allow_migrate. If you aren't using routers, I don't know what to do if you aren't using routers. How is it even possible to use multiple databases without routers?

@divio/django-cms-core @mkoistinen anything we still can do here?

See: https://github.com/divio/django-cms/issues/4798
Could be the same problem. Not sure if the bug affects router as well.

Closing as confirmed duplicate of https://github.com/divio/django-cms/issues/5093

authors: FinalAngel czpython diegoponciano igorkud90 mkoistinen mvid naush viatoriche

repo: divio/django-cms


text:
Missing Toggle toolbar arrow for CMS Toolbar

Summary
Missing Toggle toolbar arrow for CMS Toolbar
Expected behaviour
In case of front-end edit and edit mode enabled, Toggle toolbar arrow should be available in order to toggle the CMS toolbar. That's very useful if there is a header menu as the CMS Toolbar overlaps it.
Actual behaviour
CMS Toolbar overlaps the header menu and there is no easy way to toggle it.
Environment

Python version: 2.7.10
Django version: 1.11.9
django CMS version: 3.5.0RC1

what a stupid fucking design decision.

Hence the users are obligated to adapt any third-party libraries that don't except a global overlapping global header? Could somebody share the the reasoning behind this decision?

@victor-yunenko a workaround I use is to adopt the CSS as:
html.cms-toolbar-expanded {
	.navbar-fixed-top, .fixed-top {
		top: 46px;
	}
	.modal-dialog {
		margin-top: 3.5rem;
	}
}

Then, if Django-CMS toolbar is expanded, move everything, even with position: fixed, such as a navbar, by 46px downwards.

Thank you for the snippet, it works!
Naturally I still wish we didn't need to remember to add plugins class names to this snippet 😅

authors: Mezgrman jrief plamen-nikolov victor-yunenko


text:
Move plugin reordering code to a function

Refactoring code to move plugin reordering to indipendent function

Coverage increased (+0.28%) to 90.98% when pulling aec6687ff584faf8507bc4751dcad16062185d7d on yakky:feature/reorder_plugins into c8f06b5e5feeed1ac14098944396842d72ba5bba on divio:develop.

Coverage increased (+0.28%) to 90.98% when pulling aec6687ff584faf8507bc4751dcad16062185d7d on yakky:feature/reorder_plugins into c8f06b5e5feeed1ac14098944396842d72ba5bba on divio:develop.

Coverage increased (+0.28%) to 90.98% when pulling aec6687ff584faf8507bc4751dcad16062185d7d on yakky:feature/reorder_plugins into c8f06b5e5feeed1ac14098944396842d72ba5bba on divio:develop.

Coverage increased (+0.28%) to 90.98% when pulling aec6687ff584faf8507bc4751dcad16062185d7d on yakky:feature/reorder_plugins into c8f06b5e5feeed1ac14098944396842d72ba5bba on divio:develop.

authors: coveralls yakky


text:
Image alignment with cmsplugin_filer_image

I'm using the integration with the cmsplugin_filer_image plugin, and what I can't find the way around is how to float the selected image inside CKEditor itself. What happens is, on the filer plugin, I can select align, and choose left, right, or center. However inside the editor the image is inserted as a normal image, without any specific classes, so I can't display as floating. On the final rendered template, it is floated because it gets a " filer_image left/right/center" class. Is there a way around this?
Here's an example of how choosing left looks on the editor:

I'm posting this here instead of Filer because I figured it has to do with the integration and not with Filer itself. Thank you!!

closed in favour of #285

authors: FinalAngel rafadev

repo: divio/djangocms-text-ckeditor

license_source: bigquery


text:
🛑 Arcadja is down

In a6ee169, Arcadja (https://www.arcadja.com/auctions/en/) was down:

HTTP code: 404
Response time: 11212 ms

Resolved: Arcadja is back up in fb26eaf after 6 minutes.

repo: divtiply/artupptime


text:
🛑 Heritage Auctions is down

In f0cd55d, Heritage Auctions (https://www.ha.com/) was down:

HTTP code: 403
Response time: 109 ms

Resolved: Heritage Auctions is back up in ddbbec4 after 1 hour, 2 minutes.


text:
compile error linking with cc

fran@ipek:~/source/giellatekno/giella-core/kbdgen$ python3 -m kbdgen -t android examples/project-cux.yaml
[I android:582] Getting source files from divvun/giella-ime master branch…
[I android:464] Adding 'cux' to './deps/giella-ime/app/src/main/res/values/donottranslate.xml'…
[I android:109] Updating XML strings…
[I android:538] Updating method definitions…
[I android:565] Embedding generated keyboard XML files…
[W android:276] No ZHFST files found.
[I android:331] Updating localisation values…
[W android:345] no icon supplied!
[I android:396] Building native components…
[I android:398] Building armv7-linux-androideabi architecture…
    Updating git repository `https://github.com/bbqsrc/serde-xml-rs`
  Downloaded serde_json v1.0.39
  Downloaded parking_lot v0.7.1
  Downloaded serde_derive v1.0.89
  Downloaded zip v0.5.0
  Downloaded libc v0.2.47
  Downloaded tempdir v0.3.7
  Downloaded serde v1.0.89
  Downloaded hashbrown v0.1.5
  Downloaded lazy_static v1.3.0
  Downloaded log v0.4.6
  Downloaded env_logger v0.6.1
  Downloaded fxhash v0.2.1
  Downloaded unic-ucd-common v0.9.0
  Downloaded unic-segment v0.9.0
  Downloaded byteorder v1.3.1
  Downloaded memmap v0.7.0
  Downloaded error-chain v0.12.0
  Downloaded proc-macro2 v0.4.20
  Downloaded ryu v0.2.7
  Downloaded xml-rs v0.8.0
  Downloaded quote v0.6.9
  Downloaded itoa v0.4.3
  Downloaded parking_lot_core v0.4.0
  Downloaded syn v0.15.25
  Downloaded lock_api v0.1.4
  Downloaded podio v0.1.5
  Downloaded rand v0.4.6
  Downloaded crc32fast v1.1.2
  Downloaded remove_dir_all v0.5.1
  Downloaded scopeguard v0.3.3
  Downloaded humantime v1.1.1
  Downloaded termcolor v1.0.4
  Downloaded cfg-if v0.1.6
  Downloaded unic-char-property v0.9.0
  Downloaded regex v1.0.5
  Downloaded unic-char-range v0.9.0
  Downloaded unic-ucd-segment v0.9.0
  Downloaded unic-ucd-version v0.9.0
  Downloaded unicode-xid v0.1.0
  Downloaded smallvec v0.6.5
  Downloaded rustc_version v0.2.3
  Downloaded quick-error v1.2.2
  Downloaded rand v0.6.4
  Downloaded owning_ref v0.3.3
  Downloaded unreachable v1.0.0
  Downloaded aho-corasick v0.6.9
  Downloaded utf8-ranges v1.0.2
  Downloaded thread_local v0.3.6
  Downloaded memchr v2.1.1
  Downloaded void v1.0.2
  Downloaded regex-syntax v0.6.2
  Downloaded unic-common v0.9.0
  Downloaded rand_xorshift v0.1.1
  Downloaded rand_pcg v0.1.1
  Downloaded rand_isaac v0.1.1
  Downloaded rand_core v0.3.0
  Downloaded rand_hc v0.1.0
  Downloaded rand_os v0.1.1
  Downloaded rand_chacha v0.1.1
  Downloaded semver v0.9.0
  Downloaded autocfg v0.1.1
  Downloaded stable_deref_trait v1.1.1
  Downloaded version_check v0.1.5
  Downloaded ucd-util v0.1.2
  Downloaded semver-parser v0.7.0
   Compiling semver-parser v0.7.0
   Compiling libc v0.2.47
   Compiling autocfg v0.1.1
   Compiling version_check v0.1.5
error: linking with `cc` failed: exit code: 1
  |
  = note: "cc" "-Wl,--as-needed" "-Wl,-z,noexecstack" "-m64" "-L" "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib" "/home/fran/source/giellatekno/giella-core/kbdgen/deps/hfst-ospell-rs/target/release/build/libc-ccd5fb3890d7398e/build_script_build-ccd5fb3890d7398e.build_script_build.bx6mthju-cgu.0.rcgu.o" "/home/fran/source/giellatekno/giella-core/kbdgen/deps/hfst-ospell-rs/target/release/build/libc-ccd5fb3890d7398e/build_script_build-ccd5fb3890d7398e.build_script_build.bx6mthju-cgu.1.rcgu.o" "/home/fran/source/giellatekno/giella-core/kbdgen/deps/hfst-ospell-rs/target/release/build/libc-ccd5fb3890d7398e/build_script_build-ccd5fb3890d7398e.build_script_build.bx6mthju-cgu.10.rcgu.o" "/home/fran/source/giellatekno/giella-core/kbdgen/deps/hfst-ospell-rs/target/release/build/libc-ccd5fb3890d7398e/build_script_build-ccd5fb3890d7398e.build_script_build.bx6mthju-cgu.11.rcgu.o" "/home/fran/source/giellatekno/giella-core/kbdgen/deps/hfst-ospell-rs/target/release/build/libc-ccd5fb3890d7398e/build_script_build-ccd5fb3890d7398e.build_script_build.bx6mthju-cgu.12.rcgu.o" "/home/fran/source/giellatekno/giella-core/kbdgen/deps/hfst-ospell-rs/target/release/build/libc-ccd5fb3890d7398e/build_script_build-ccd5fb3890d7398e.build_script_build.bx6mthju-cgu.13.rcgu.o" "/home/fran/source/giellatekno/giella-core/kbdgen/deps/hfst-ospell-rs/target/release/build/libc-ccd5fb3890d7398e/build_script_build-ccd5fb3890d7398e.build_script_build.bx6mthju-cgu.2.rcgu.o" "/home/fran/source/giellatekno/giella-core/kbdgen/deps/hfst-ospell-rs/target/release/build/libc-ccd5fb3890d7398e/build_script_build-ccd5fb3890d7398e.build_script_build.bx6mthju-cgu.3.rcgu.o" "/home/fran/source/giellatekno/giella-core/kbdgen/deps/hfst-ospell-rs/target/release/build/libc-ccd5fb3890d7398e/build_script_build-ccd5fb3890d7398e.build_script_build.bx6mthju-cgu.4.rcgu.o" "/home/fran/source/giellatekno/giella-core/kbdgen/deps/hfst-ospell-rs/target/release/build/libc-ccd5fb3890d7398e/build_script_build-ccd5fb3890d7398e.build_script_build.bx6mthju-cgu.5.rcgu.o" "/home/fran/source/giellatekno/giella-core/kbdgen/deps/hfst-ospell-rs/target/release/build/libc-ccd5fb3890d7398e/build_script_build-ccd5fb3890d7398e.build_script_build.bx6mthju-cgu.6.rcgu.o" "/home/fran/source/giellatekno/giella-core/kbdgen/deps/hfst-ospell-rs/target/release/build/libc-ccd5fb3890d7398e/build_script_build-ccd5fb3890d7398e.build_script_build.bx6mthju-cgu.7.rcgu.o" "/home/fran/source/giellatekno/giella-core/kbdgen/deps/hfst-ospell-rs/target/release/build/libc-ccd5fb3890d7398e/build_script_build-ccd5fb3890d7398e.build_script_build.bx6mthju-cgu.8.rcgu.o" "/home/fran/source/giellatekno/giella-core/kbdgen/deps/hfst-ospell-rs/target/release/build/libc-ccd5fb3890d7398e/build_script_build-ccd5fb3890d7398e.build_script_build.bx6mthju-cgu.9.rcgu.o" "-o" "/home/fran/source/giellatekno/giella-core/kbdgen/deps/hfst-ospell-rs/target/release/build/libc-ccd5fb3890d7398e/build_script_build-ccd5fb3890d7398e" "/home/fran/source/giellatekno/giella-core/kbdgen/deps/hfst-ospell-rs/target/release/build/libc-ccd5fb3890d7398e/build_script_build-ccd5fb3890d7398e.2vzib6xddo4z7vgy.rcgu.o" "-Wl,--gc-sections" "-pie" "-Wl,-zrelro" "-Wl,-znow" "-Wl,-O1" "-nodefaultlibs" "-L" "/home/fran/source/giellatekno/giella-core/kbdgen/deps/hfst-ospell-rs/target/release/deps" "-L" "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib" "-Wl,--start-group" "-Wl,-Bstatic" "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/libstd-79f126b09196cdf2.rlib" "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/libpanic_unwind-376a22c973b921f9.rlib" "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/libbacktrace_sys-90dc619dced03db1.rlib" "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/libunwind-b17a16bb50dcf6e7.rlib" "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/librustc_demangle-80afe56a7ca6b327.rlib" "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/liblibc-5e5f3cc5ac04f2f3.rlib" "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/liballoc-62795edc93df4274.rlib" "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/librustc_std_workspace_core-2490d0c739fb5363.rlib" "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcore-c00b11ce47d19e63.rlib" "-Wl,--end-group" "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcompiler_builtins-a9797aba406537c8.rlib" "-Wl,-Bdynamic" "-ldl" "-lrt" "-lpthread" "-lgcc_s" "-lc" "-lm" "-lrt" "-lpthread" "-lutil" "-lutil"
  = note: /usr/lib/android-ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/arm-linux-androideabi/bin/ld: error: /usr/lib/gcc/x86_64-linux-gnu/8/../../../x86_64-linux-gnu/Scrt1.o: unsupported reloc 42 against global symbol __libc_csu_fini
          /usr/lib/android-ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/arm-linux-androideabi/bin/ld: error: /usr/lib/gcc/x86_64-linux-gnu/8/../../../x86_64-linux-gnu/Scrt1.o: unsupported reloc 42 against global symbol __libc_csu_init
          /usr/lib/android-ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/arm-linux-androideabi/bin/ld: error: /usr/lib/gcc/x86_64-linux-gnu/8/../../../x86_64-linux-gnu/Scrt1.o: unsupported reloc 42 against global symbol main
          /usr/lib/android-ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/arm-linux-androideabi/bin/ld: error: /usr/lib/gcc/x86_64-linux-gnu/8/../../../x86_64-linux-gnu/Scrt1.o: unsupported reloc 41 against global symbol __libc_start_main
          /usr/lib/android-ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/arm-linux-androideabi/bin/ld: error: /usr/lib/gcc/x86_64-linux-gnu/8/../../../x86_64-linux-gnu/crti.o: unsupported reloc 42 against global symbol __gmon_start__
          /usr/lib/android-ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/arm-linux-androideabi/bin/ld: error: /usr/lib/gcc/x86_64-linux-gnu/8/crtbeginS.o: unsupported reloc 42 against global symbol _ITM_deregisterTMCloneTable
          /usr/lib/android-ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/arm-linux-androideabi/bin/ld: error: /usr/lib/gcc/x86_64-linux-gnu/8/crtbeginS.o: unsupported reloc 42 against global symbol _ITM_registerTMCloneTable
          /usr/lib/gcc/x86_64-linux-gnu/8/../../../x86_64-linux-gnu/crti.o(.init+0x7): error: unsupported reloc 42
          /usr/lib/gcc/x86_64-linux-gnu/8/crtbeginS.o(.text+0x16): error: unsupported reloc 42
          /usr/lib/gcc/x86_64-linux-gnu/8/crtbeginS.o(.text+0x57): error: unsupported reloc 42
          /usr/lib/gcc/x86_64-linux-gnu/8/../../../x86_64-linux-gnu/Scrt1.o:function _start: error: unsupported reloc 42
          /usr/lib/gcc/x86_64-linux-gnu/8/../../../x86_64-linux-gnu/Scrt1.o:function _start: error: unsupported reloc 42
          /usr/lib/gcc/x86_64-linux-gnu/8/../../../x86_64-linux-gnu/Scrt1.o:function _start: error: unsupported reloc 42
          /usr/lib/gcc/x86_64-linux-gnu/8/../../../x86_64-linux-gnu/Scrt1.o:function _start: error: unsupported reloc 41
          collect2: error: ld returned 1 exit status

error: aborting due to previous error

error: Could not compile `libc`.
warning: build failed, waiting for other jobs to finish...
error: build failed
Traceback (most recent call last):
  File "/usr/lib/python3.7/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/usr/lib/python3.7/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/home/fran/source/giellatekno/giella-core/kbdgen/kbdgen/__main__.py", line 17, in <module>
    main()
  File "/home/fran/source/giellatekno/giella-core/kbdgen/kbdgen/__main__.py", line 11, in main
    sys.exit(run_cli())
  File "/home/fran/source/giellatekno/giella-core/kbdgen/kbdgen/cli.py", line 132, in run_cli
    x.generate(x.output_dir)
  File "/home/fran/source/giellatekno/giella-core/kbdgen/kbdgen/gen/android.py", line 145, in generate
    self.build(base, tree_id, self.is_release)
  File "/home/fran/source/giellatekno/giella-core/kbdgen/kbdgen/gen/android.py", line 418, in build
    os.path.join(jni_dir, "libdivvunspell.so"),
  File "/usr/lib/python3.7/shutil.py", line 120, in copyfile
    with open(src, 'rb') as fsrc:
FileNotFoundError: [Errno 2] No such file or directory: './deps/giella-ime/../hfst-ospell-rs/target/armv7-linux-androideabi/release/libdivvunspell.so'

For reference, the project file is:
internalName: cuicateco_keyboard

locales:
  en:
    name: "Keyboard for Cuicatec"
    description: "A test keyboard for Cuicatec."
  es:
    name: &bundleName "Un teclado para la lengua cuicateca"
    description: "Esto es un teclado diseñado para las varias propuestas ortográficas de la lengua cuicateca."

author: Francis M. Tyers
email: ftyers@iu.edu

layouts: [cux]

version: "1.0"
build: "1"

targets:
  android:
    packageId: so.ftyers.keyboards.cuicateco
    #icon: cuicateco-icon.pdf
    keyStore: /Users/ftyers/source/giellatekno/giella-core/kbdgen/cuicateco_keyboard.keystore
    keyAlias: cuicateco_keyboard

  osx:
    packageId: so.ftyers.cuicateco
    codeSignId: "OSX"
    provisioningProfileId: Test

And the keyboard is:
internalName: cuicatec

displayNames:
  cux: Cuicatec
  en: Cuicatec
  es: Cuicateco

locale: cux

locales: cux

modes:
  mobile-default: |
    ʼ w e r t y u i o p
    a s d f g h j k l ñ
    z x v b n m
  mobile-shift: |
    ʼ W E R T Y U I O P
    A S D F G H J K L Ñ
    Z X V B N M

decimal: ','

deadKeys:
  iso-default: ["`"]
  iso-shift: ["`"]

longpress:
  A: Á À Ä A̱
  E: É À Ë E̱
  I: Í Ì Ï I̱̱
  O: Ó Ò Ö O̱
  U: Ú Ù Ü U̱
  ʼ: q Q
  a: á à ä a̱
  e: é à ë e̱
  i: í ì ï i̱̱
  o: ó ò ö o̱
  u: ú ù ü u̱

styles:
  tablet:
    actions:
      backspace: [1, right, fill]
      enter: [2, right, fill]
      shift: [3, both, fill]
  phone:
    actions:
      shift: [3, left, fill]
      backspace: [3, right, fill]

#targets:
#  android:
#    minimumSdk: 21

strings:
  space: gaske
  return: linnjámolsun

It seems the version of the NDK you're trying to use is too old. The minimum version known to work consistently is r19c, also known as 19.2.
I have updated the document to reflect this now. You may wish to try to install the SDK and NDK locally and see how you go? https://divvun.github.io/kbdgen/#installation_and_environment_configuration
Best of luck!

Thanks! I updated NDK and got another error, but I'll make a new issue for that.

authors: bbqsrc ftyers

repo: divvun/kbdgen


text:
Travis CIi fixes

I didn't notice last time that Travis runs on every PR, it just doesn't update the PR itself.
There are 3 errors with 2 different errors:
  File "/home/travis/build/dj-paddle/dj-paddle/djpaddle/settings.py", line 25
    msg = f"failed to convert 'DJPADDLE_PUBLIC_KEY'; original message: {e}"
                                                                          ^
SyntaxError: invalid syntax
ERROR: InvocationError for command /home/travis/build/dj-paddle/dj-paddle/.tox/py35-django21-postgres/bin/pytest (exited with code 1)

This is due to fstrings not being implimented in python 3.5. I've fixed this.
But the fact it go into this statement means it would have raised the second error anyway:
django.core.exceptions.ImproperlyConfigured: failed to convert 'DJPADDLE_PUBLIC_KEY'; original message: RSA key format is not supported
Makefile:58: recipe for target 'html' failed
make: *** [html] Error 2
ERROR: InvocationError for command /usr/bin/make html (exited with code 2)

I'm not sure how DJPADDLE_PUBLIC_KEY is not valid... it's not an empty string or ImproperlyConfigured would raise the error `'DJPADDLE_PUBLIC_KEY' . So it must be the keys value is bad...
The test settings use:
DJPADDLE_KEY = utils.generate_private_key()
DJPADDLE_PUBLIC_KEY = utils.export_pubkey_as_pem(DJPADDLE_KEY)

But this should then fail on all tests? Unless it's a python version issue?
I'm going to see what Travis returns now. My next bet is to set DJANGO_SETTINGS_MODULE=tests.settings for any django related command in tox

Codecov Report

Merging #21 into master will decrease coverage by 0.09%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master      #21      +/-   ##
==========================================
- Coverage   97.95%   97.86%   -0.10%
==========================================
  Files           8        8
  Lines         196      187       -9
  Branches       17       17
==========================================
- Hits          192      183       -9
  Partials        4        4

Impacted Files
Coverage Δ

djpaddle/models.py
96.29% <100.00%> (-0.29%)
:arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c6dc9ea...f7b2e4f. Read the comment docs.

OK we are actually looking good this time - https://travis-ci.org/github/dj-paddle/dj-paddle/builds/690020942

authors: codecov-commenter pyepye

repo: dj-paddle/dj-paddle


text:
During import, table id will not be auto-incremented

Running on:

Django-1.6
django-import-export-0.1.5
postgresql.x86_64-9.2.5-1
tablib-0.9.11
python-2.7.5-9

I have successfully imported data from a csv file.
When I try to add more data manually, I receive the error:
duplicate key value violates unique constraint "mytable_pkey"
DETAIL:  Key (id)=(1) already exists.

From psql:
select max(id) from mytable;
  75

SELECT nextval('mytable_id_seq');
  2

Does django-import-export support the table's id auto-incrementing?

Hello,  Django is new for me.
I am getting same error. "id" is my auto increment field I am getting above same error.
I used exclude(), import_id_fields but still getting same error. also added "id"  in header  with other header like email,first_name etc
Suggest solution.  I created "UserResource"
Code is as follows :
from import_export.admin import ImportExportMixin, ImportExportModelAdmin
from import_export import resources
from django.contrib import admin
from django.contrib.auth.admin import UserAdmin
from django.contrib.auth.models import Group
from django.contrib.sites.models import Site
from django.utils.translation import ugettext as _
from django.db import models
from django.forms import TextInput, Textarea
from rest_framework.authtoken.models import Token
from fx1_user.forms import UserChangeForm, UserRegistrationForm
from fx1_user.models import CustomUser
def move_to_paid(modeladmin, request, queryset):
for user in queryset:
CustomUser.objects.move_user_to_paid(user)
move_to_paid.short_description = _("Move selected users to paid")
def move_to_free(modeladmin, request, queryset):
for user in queryset:
CustomUser.objects.move_user_to_free(user)
move_to_free.short_description = _("Move selected users to free")
class UserResource(resources.ModelResource):
class Meta:
model = CustomUser
import_id_fields = ['id',]
exclude = ('id', )
fields = ('email','first_name','last_name','contact_number','is_subscribed')
def get_instance(self, instance_loader, row):
return False
def save_instance(self, instance, real_dry_run):
if not real_dry_run:
try:
obj = CustomUser.objects.get(some_val=instance.first_name)
# extra logic if object already exist
except NFCTag.DoesNotExist:
# create new object
obj = CustomUser(some_val=instance.first_name)
obj.save()
def before_import(self, dataset, dry_run):
if dataset.headers:
dataset.headers = [str(header).lower().strip() for header in dataset.headers]
class CustomUserAdmin(ImportExportMixin,UserAdmin):
resource_class = UserResource
# The forms to add and change user instances
form = UserChangeForm
add_form = UserRegistrationForm
actions = [move_to_free, move_to_paid]
# The fields to be used in displaying the User model.
# These override the definitions on the base UserAdmin
# that reference specific fields on auth.User.
list_display = ('email', 'created', 'is_admin', 'is_subscribed','special_user')
list_filter = ('is_admin',)
readonly_fields = (
    'created',
    'last_login',
    'owner',
)
fieldsets = (
    (None, {'fields': ('email', 'password',)}),
    (_('Permissions'), {'fields': ('is_admin', 'is_superuser', 'is_subscribed','special_user')}),
    (_('Important dates'), {'fields': ('last_login', 'created',)}),
    (_('Profile'), {'fields': ('profile_picture',
                               'first_name',
                               'last_name',
                               'contact_number',
                               'referral',
                               'owner',)}),
    (_('Subscription'), {'fields': ('subscription_type',
                                    'subscription_start',
                                    'subscription_end',
                                    'subscription_ongoing',)}),
)
formfield_overrides = {
    models.CharField: {'widget': TextInput(attrs={'size': '20'})},
    models.TextField: {'widget': Textarea(attrs={'rows': 4, 'cols': 40})},
    }
add_fieldsets = (
    (None, {
        'classes': ('wide',),
        'fields': (
            'email', 'password1', 'password2', 'subscription_type'
        )
    }),
)
search_fields = ('email',)
ordering = ('email',)
filter_horizontal = ()

admin.site.unregister(Token)
admin.site.register(CustomUser, CustomUserAdmin)
Thank you.

Here is how to fix the database after this error:
from django.db import connection
# select a relevant line from the output of ./project/manage.py sqlsequencereset [appname]
sql = '''SELECT setval(pg_get_serial_sequence('"appname_modelname"','id'), coalesce(max("id"), 1), max("id") IS NOT null) FROM "appname_modelname";'''
cursor = connection.cursor()
cursor.execute(sql)

Using IDs for new records looks like a reasonable usage for [backward] compatibility with some other database.

@int-ua  thanks for quick reply but where to put above code in admin.py or model ?

It's a one-time solution, you can execute in Django shell (./manage.py shell)

sorry,but i don't understand.  could you elaborate,please ?
and is there any effect on existing records of table ?

Please search Django and SQL database of your choice documentations for pieces you don't understand.
I suggest you start with this link: https://docs.djangoproject.com/en/1.8/ref/django-admin/#shell

Thanks int-ua. I don't need to do above suggested solution. my problem is solved. I was not using 'id' in export filter.

Hi,
I have tried both the approaches mentioned above. But I am getting this error, I believe this is something to do with how my models are designed, but any help will be appreciated.
The error signature here.
Line number: 1 - 'NoneType' object is not iterable
OrderedDict([('ID', ''), ('STRATEGIE_REF_ID', '100'), ('IND_1', 'CLOSE'), ('IND_2', 'SMA200'), ('DESCRIPTION', '1000')])
Traceback (most recent call last):
File "/Users/Suraj/Django/django/bin/Ahes-src/import_export/resources.py", line 356, in import_data
instance, new = self.get_or_init_instance(instance_loader, row)
File "/Users/Suraj/Django/django/bin/Ahes-src/import_export/resources.py", line 186, in get_or_init_instance
instance = self.get_instance(instance_loader, row)
TypeError: 'NoneType' object is not iterable
I have multiple models and data import is to be done on a daily basis. So I would also like to understand why and how this error is there, so I can make sure it doesnt happen in future.
Will be grateful

I am getting the same exact error in other table / model imports as well. I think now that it is more of a configuration / settings issue.
Please help

I am having the same problem and I would like to add that I need to import / export the ids to keep the relationships between the imported / exported data rows.
I found this as a possibility to fix it manually:
select id from table order by id DESC LIMIT 1;
 id
----
 11
alter sequence auth_group_id_seq restart with 12;

This will fix the problem, but I can't do this everytime and for every table I import data into..
The main reason why I import / export the id fields are:

keep relationships between data rows
make updating existing records easier

I have recently been experiencing the same problem as follow :

I bulk import  the old export plus one new row with the new id
now I try to manually add one new value but it tels me the id is duplicate until I save as many times as I added new row in the bulk import
I tried with no id in the column but get the error ValueError: Field 'id' expected a number but got ''.

authors: diptipsawant drayendrff int-ua platzhersh raratiru surajprasad


text:
Fix horizontal scrolling in dashboard

Fixes https://github.com/django-oscar/django-oscar/issues/1875
For some reason, my lessc rounded the percentages to a different precision. Maybe we should document which version of lessc to actually use to prevent these sorts of annoying cases?

@maikhoepfel Could you take a quick look at this, please? I patched around the issue with the diff rounding percentages incorrectly.

Thanks!

authors: john-parton mvantellingen

repo: django-oscar/django-oscar


text:
Fixed #30750 -- Added support for check constraints on MySQL 8.0.16+.

ticket 30750.
The original patch was from @felixxm. I just fixed a small test.

@hramezani Thanks for finding this :+1: , IMO this test should be run only on relevant backends. I also added release notes.

@felixxm Your welcome.

IMO this test should be run only on relevant backends

Yes, it is the right way.

authors: felixxm hramezani

repo: django/django


text:
Fixed #31039 -- Added support __contained_by lookup for AutoFields and BigAutoFields.

Ticket 31039.

Might want to throw support for SmallAutoField in there as well since it was added by #11611.

So probably also for a SmallIntegerField.

Might want to throw support for SmallAutoField in there as well since it was added by #11611.

So probably also for a SmallIntegerField.

And probably also DecimalField, so all of those extras would be:
...
    type_mapping = {
        ...
        'smallserial': 'int4range',
        'smallint': 'int4range',
        'numeric': 'numrange',
        ...
    }
...
models.SmallAutoField.register_lookup(RangeContainedBy)
models.SmallIntegerField.register_lookup(RangeContainedBy)
models.DecimalField.register_lookup(RangeContainedBy)

@felixxm, @charettes, @pope1ni Thanks for the review and suggestions.
Requested fields added.

@charettes Thanks again for the review.
The requested changes are ready now.
Unfortunately, I didn't get you completely about splitting the commits. :thinking:

@felixxm I think this path is complete now. the only remaining thing is splitting the commits as @charettes comment.
Could you please give me more detail about how to split them?

To clarify the commit splitting part, I wrongly assumed that this happened to be fixed for AutoField and BigAutoField by accident when we made them subclass IntegerField 21e559495b8255bba1e8a4429cd083246ab90457 but it's not the case because we were missing the RangedContainedBy.type_mapping for them as well.
I guess we could still remove the superflous BigIntegerField.register_lookup in a first commit if we wanted to.

@charettes Thanks again for the explanation.
I split the commits.

Thanks, I pushed minor edits.

authors: charettes felixxm hramezani pope1ni


text:
[3.1.x] Fixed #32713, Fixed CVE-2021-32052 -- Prevented newlines and tabs from being accepted in URLValidator on Python 3.9.5+.

In Python 3.9.5+ urllib.parse() automatically removes ASCII newlines
and tabs from URLs [1, 2]. Unfortunately it created an issue in
the URLValidator. URLValidator uses urllib.urlsplit() and
urllib.urlunsplit() for creating a URL variant with Punycode which no
longer contains newlines and tabs in Python 3.9.5+. As a consequence,
the regular expression matched the URL (without unsafe characters) and
the source value (with unsafe characters) was considered valid.
[1] https://bugs.python.org/issue43882 and
[2] https://github.com/python/cpython/commit/76cd81d60310d65d01f9d7b48a8985d8ab89c8b4
Backport of cfe6b8bdd63890e4bb6482a806f3a9065045291e from main.

Merged in afb23f5929944a407e4990edef1c7806a94c9879.


text:
Replace multiple == checks with in

Replace multiple == checks with in

@harishsg993010 Thanks for this patch :+1: however we try to avoid trivial code reformatting unless it's a big problem as it creates extra noise in the history. Also, this change is incorrect in some places.


text:
Fixed #34346 -- Order selected expressions by position.

This uses an approach similar to the adopted to address #34176 by to avoid ambiguous aliases in dd68af62b2b27ece50d434f6a351877212e15c3f.

buildbot, test on oracle.

buildbot, test this please.

buildbot, test on oracle.

@henribru Does it work for you?

@felixxm It does indeed! Thanks, @charettes
Out of curiosity: I noticed this fixes both the F("name") case that worked in 4.1 but regressed in 4.2a1 and the "name" case that is broken even in 4.1. Will the fix be backported to 4.1 as well?

Will the fix be backported to 4.1 as well?

This is not a regression in Django 4.1, per our backporting policy this means it doesn't qualify for a backport to 4.1.x. See Django’s release process for more details.

@felixxm It does indeed! Thanks, @charettes

Thanks for checking :+1:

authors: charettes felixxm henribru


text:
Fix #34629 -- Error when using GeoAggregate with Filter

This fix an AttributeError when trying to use a filter argument in django.contrib.gis.db.models.aggregates.Collect and other GeoAggregate
Unit test have been added to check that this is now fixed.
See for description https://code.djangoproject.com/ticket/34629#ticket

@shangxiao Thanks, you are right, I integrated the modification

@olethanh  Do you have time to keep working on this?

yes sorry last week was quite busy but I should have sometime this afternoon and tomorrow

Hello, thanks for you review and advice.  I think I corrected all that was suggested. Can I ask you to review again when the tests pass?

Re based the branch on main
Updated doc and release notes.
removed the test using the Snack Model and the model itself
Added tests for all GIS aggregate functions. I prefer to group different parameter variation but tell me if I should subdivide them in even smaller test functions.
Still had to add a new Model to tests the 3D functions and fields.

I have a crash when testing with MakeLine and there is only one Point, will open a separate ticket for that

buildbot, test on oracle.

I've pushed a fix. Let's see if it resolves the issue. While the solution may not be the most elegant, I hope it helps prevent similar problems in the future. Personally, I find the code related to source expressions and filters quite confusing. The way filters are pushed and popped around can be challenging to follow."

buildbot, test on oracle.

Seems Oracle is failling with the error
>    city = qs.get(name="Aurora")
< django.db.utils.DatabaseError: ORA-13050: unable to construct spatial object

in test_union_filter
https://djangoci.com/job/pull-requests-oracle/database=oragis19,label=oracle,python=python3.11/613/console
Full stacktrace

======================================================================
ERROR [0.053s]: test_union_filter (gis_tests.relatedapp.tests.RelatedGeoModelTest.test_union_filter)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/jenkins/workspace/pull-requests-oracle/database/oragis19/label/oracle/python/python3.11/django/db/utils.py", line 98, in inner
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
cx_Oracle.DatabaseError: ORA-13050: unable to construct spatial object

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/jenkins/workspace/pull-requests-oracle/database/oragis19/label/oracle/python/python3.11/django/test/testcases.py", line 1428, in skip_wrapper
    return test_func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/jenkins/workspace/pull-requests-oracle/database/oragis19/label/oracle/python/python3.11/tests/gis_tests/relatedapp/tests.py", line 404, in test_union_filter
    city = qs.get(name="Aurora")
           ^^^^^^^^^^^^^^^^^^^^^
  File "/home/jenkins/workspace/pull-requests-oracle/database/oragis19/label/oracle/python/python3.11/django/db/models/query.py", line 625, in get
    num = len(clone)
          ^^^^^^^^^^
  File "/home/jenkins/workspace/pull-requests-oracle/database/oragis19/label/oracle/python/python3.11/django/db/models/query.py", line 379, in __len__
    self._fetch_all()
  File "/home/jenkins/workspace/pull-requests-oracle/database/oragis19/label/oracle/python/python3.11/django/db/models/query.py", line 1892, in _fetch_all
    self._result_cache = list(self._iterable_class(self))
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/jenkins/workspace/pull-requests-oracle/database/oragis19/label/oracle/python/python3.11/django/db/models/query.py", line 90, in __iter__
    results = compiler.execute_sql(
              ^^^^^^^^^^^^^^^^^^^^^
  File "/home/jenkins/workspace/pull-requests-oracle/database/oragis19/label/oracle/python/python3.11/django/db/models/sql/compiler.py", line 1595, in execute_sql
    return list(result)
           ^^^^^^^^^^^^
  File "/home/jenkins/workspace/pull-requests-oracle/database/oragis19/label/oracle/python/python3.11/django/db/models/sql/compiler.py", line 2096, in cursor_iter
    for rows in iter((lambda: cursor.fetchmany(itersize)), sentinel):
  File "/home/jenkins/workspace/pull-requests-oracle/database/oragis19/label/oracle/python/python3.11/django/db/models/sql/compiler.py", line 2096, in <lambda>
    for rows in iter((lambda: cursor.fetchmany(itersize)), sentinel):
                              ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/jenkins/workspace/pull-requests-oracle/database/oragis19/label/oracle/python/python3.11/django/db/utils.py", line 97, in inner
    with self:
  File "/home/jenkins/workspace/pull-requests-oracle/database/oragis19/label/oracle/python/python3.11/django/db/utils.py", line 91, in __exit__
    raise dj_exc_value.with_traceback(traceback) from exc_value
  File "/home/jenkins/workspace/pull-requests-oracle/database/oragis19/label/oracle/python/python3.11/django/db/utils.py", line 98, in inner
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
django.db.utils.DatabaseError: ORA-13050: unable to construct spatial object

----------------------------------------------------------------------

I'm lacking  information for debug and I am not familira with Oracle, any idea?
Is it linked to this https://support.oracle.com/knowledge/Oracle Database Products/2564329_1.html ?
There is also an error in spatialite but it's unrelated to my change so I think it's a flaky test.

buildbot, test on oracle.
I'm dividing the test in 3 so we can see if it is one of the annotate in particular that pause problem

buildbot, test on oracle.

I added a test without the filter, but it still fails on Oracle. Therefore, I suspect that the issue is not related to my recent change. It's possible that the problem lies with the test data I used.
I couldn't find any existing tests specifically for the Union Aggregate on Oracle. While there are passing tests for functions.Union in geoapp/test_functions.py, they are not related to the Aggregate functionality. I'm noticing a lot of workaround for Oracle in theses tests.
Is there a way to extract more details from Jenkins, such as the SQL queries executed? I'm feeling a bit lost on what steps to take next, so any guidance would be greatly appreciated.
I will be AFK for the next few days, but please feel free to provide any pointers or suggestions during my absence and i will continue looking into it upon my return.

I will be AFK for the next few days, but please feel free to provide any pointers or suggestions during my absence and i will continue looking into it upon my return.

Don't worry I will try to figure it out.

django.db.utils.DatabaseError: ORA-13050: unable to construct spatial object

Using Union() on provided polygons crashes even without filters, so I will switch test_union_filter to points. It's some kind of Oracle caveat that I wouldn't care about right now. My knowledge of Oracle GIS is quite limited.
I also fixed GeoAggregate on Oracle by pushing SDOAGGRTYPE wrapping to the Func().
@olethanh Thanks again :+1:

buildbot, test on oracle.

@felixxm  Thanks a lot for the help, the fix and the merge !

authors: felixxm olethanh


text:
Fixed #28032 -- Paginator.page_force_into_range

Moved boilerplate from docs to a utility function.

I'd love to have more suggestions for the name, where should I post a question?

Thank you very much for your contribution, @sjlehtin :) Please let me know when you have (more) questions! :+1:

I've addressed everything except the "Returns", I hope.  "effective_page" is a good name, was there prior art for "effective_" in Django somewhere?

I now changed the function name in the commit message as well.

authors: MarkusH sjlehtin


text:
Home Page Banner/logo section buttons not looking nice

On the homepage, just below the Djangocon logo there are 2 buttons for now "Submit your CFP📢" and "Buy Tickets🎫".
But these 2 buttons is not same width and the icon need a space in between text.
This happens the same for mobile when stacked.
I have attached 2 screenshots below.
Desktop:

Mobile:

Hello sir, I would get that fix real quick


text:
🛑 Writeguard is down

In 375d4e4, Writeguard (https://www.writeguard.com) was down:

HTTP code: 0
Response time: 0 ms

Resolved: Writeguard is back up in f248430.


text:
Username and Password Input Field Labels Malformed

After coming across the information for the HACS integration (YAY!! Just in time for the new season!), I've gone ahead and set it up and all worked okay!
I didn't initially see a way to change the pump speed so I figured a clean install would help (I just came across #9 which I'll look into now haha). That being said, as I was setting up the new integration, I noticed that, when asked to enter the credentials, the input labels aren't properly formatted. Just though I'd raise an issue in case it's something that can be adjusted (unless it's out of your hands). I see the following for the username and password fields. A hard refresh of the page to clear the browser cache doesn't correct the issue

Once again, thank you so much for the work on this integration!! The transition and new abilities are amazing, and I can't wait to dig into it!! 😃

Thanks - this appears to be related to translations in Home Assistant. Can anyone else confirm this same behaviour on another implementation.

I got the same thing. I uninstalled the integration and the HACS integration. At the next install, I made sure to restart HA after the HACS install, before doing the HA integration install, and it went away.
Something else puzzles me now. When I go to Settings/Integrations, find the Omnilogic integration, then select Configure, I get this.

I don’t know what the second field is, and I was expecting to see the username and password fields included.

I have to update some translation strings tomorrow for this to pop up.
Username and password aren't available except during setup which is standard for HA integrations. If you need to change username or password you need to remove and reinstall the integration.

Thanks. What’s the second, unlabelled field for?

I believe it is the offset for the ORP sensor in case it doesn't match the app. Will have a label in the next release either way.

Thanks.

Fixed in today's release (for both).

authors: N3rdP1um23 djtimca sddgit

repo: djtimca/haomnilogic


text:
update gpg keys

add @wilzbach
add nightly build bot
update public key signatures (expiration dates and ids)
sign updated keyring

Not sure why this is failing on the server, it's passing locally. Trying a restart.

Done @wilzbach
Not sure about GDC and LDC, let's see if there is interest and who would be the right person to add (@jpf91, @kinke), atm. none of those releases/tags are signed.

Done @wilzbach

Did you forget to push? I don't see @CyberShadow's key in the keyring (nor the updated fingerprint of mine).

Did you forget to push? I don't see @CyberShadow's key in the keyring (nor the updated fingerprint of mine).

Indeed @wilzbach, sorry.

authors: MartinNowak wilzbach


text:
[std.experimental.logger] use NullLogger as the default

singingbush reported this on 2018-05-14T12:29:41Z
Transfered from https://issues.dlang.org/show_bug.cgi?id=18857
CC List

aruncxy
atila.neves (@atilaneves)
robertschadek (@burner)

Description
use NullLogger as the default instead of outputting to stderr

atila.neves (@atilaneves) commented on 2022-07-18T14:25:36Z
I don't think that makes any sense, people who use the logger expect output, this will only lead to confusion.

And, of course, there's a workaround: set the global logger to NullLogger.

repo: dlang/phobos


text:
Adds Typedef.toString()

It is need to avoid silent conversion of Typedef struct itself to string by std.conv.to.
Discussion:
https://forum.dlang.org/post/kjzayldqnixehfprgslc@forum.dlang.org
Previous attempt: #6217

I am should use git squash or this is not necessary?

Yes, please squash.

Yes do squash. Don't worry about the formatting, see https://github.com/dlang/phobos/pull/6220

Don't worry about the formatting, see #6220

FWIW: This is something different. dmd-cxx is the old C++ branch that didn't compile fro years and it slowly brought back to life.
Anyhow, while sticking to the DStyle is a requirement for official code, it's not blocking your PR. Every maintainer can easily fix that for you if there's interest in the PR (i.e. the idea has been approved.)

Now back to the PR in question, is there any reason why you didn't add a writer-based toString?
string toString isn't really nice, because it always allocates which is slow.
@JackStouffer has been working hard on adding writer-based toString overloads, even for the mentioned Nullable.toString: https://github.com/dlang/phobos/pull/6198

Sorry @denizzzka, I've been busy with other work the past few days and did not have time to properly review this. As @wilzbach pointed out, it would be preferably to add a writer-based overload of toString so there will be no allocation at all when possible. Take a look at the aforementioned pull request he linked to see how to do it.

Changed for writer support and squashed

Something strange with CI check

Not too strange though.
Just follow the advice of the message and add @safe to your unittest. Explicit annotation is required because it's too often forgotten.

Oh, thank you, did not noticed by myself.

Thanks @denizzzka!

authors: MetaLang denizzzka thewilsonator wilzbach


text:
Sort and display events within a heat based on extra field

If extra info is different, display that title

closed by pull request #128


text:
master merge for 0.4.9 release

Description
master merge for 0.4.9 release

@rudolfix you need to add the ci-full label when creating the pr, if you add it later, it will only be applied if there is another push unfortunately

authors: rudolfix sh-rp

repo: dlt-hub/dlt


text:
virtual machine with two network interfaces is not addressed properly

System Information
Linux distribution
CentOS Linux release 8.1.1911 (Core)
Terraform version
Terraform version: 0.12.9

Provider and libvirt versions
terraform-provider-libvirt db13b678ab16fe9dca024c3daea6e56fb4cc4ae2
Compiled against library: libvirt 4.5.0
Using library: libvirt 4.5.0
Running hypervisor: QEMU 2.12.0
Running against daemon: 4.5.0

Description of Issue/Question
Setup
I have define two networks. When resource libvirt_domain has defined two network interfaces after boot system no one of defined ip's are assigned to virtual machine. In case when is used only one network interface ip adress is set properly.
provider "libvirt" {
  uri = "qemu:///system"
}

resource "libvirt_network" "network_show_base" {
  name      = "tf_show_base"
  autostart = true
  mode      = "nat"
  bridge    = "brshowbase"
  domain    = "edu.local"
  addresses = ["10.8.220.0/24"]
  dns {
    enabled = true
    forwarders {
      address = "192.168.1.199"
    }
  }
}
resource "libvirt_network" "network_show_data" {
  name      = "tf_show_data"
  autostart = true
  mode      = "nat"
  bridge    = "brshowdata"
  domain    = "edu.local"
  addresses = ["172.20.11.0/24"]
  dns {
    enabled = true
    forwarders {
      address = "192.168.1.199"
    }
  }
}

resource "libvirt_pool" "tf_show" {
  name = "tf_show"
  type = "dir"
  path = "/var/lib/libvirt/images/show"
}

data "template_file" "meta_data_show-web01" {
  template = file("/var/lib/libvirt/project/show/cloud-init/show-web01/meta-data")
}

data "template_file" "user_data_show-web01" {
  template = file("/var/lib/libvirt/project/show/cloud-init/show-web01/user-data")
}

resource "libvirt_cloudinit_disk" "cloudinit_show-web01" {
  name           = "seed_show-web01.iso"
  user_data      = data.template_file.user_data_show-web01.rendered
  meta_data      = data.template_file.meta_data_show-web01.rendered
  pool           = libvirt_pool.tf_show.name
}

data "template_file" "meta_data_show-web02" {
  template = file("/var/lib/libvirt/project/show/cloud-init/show-web02/meta-data")
}

data "template_file" "user_data_show-web02" {
  template = file("/var/lib/libvirt/project/show/cloud-init/show-web02/user-data")
}

resource "libvirt_cloudinit_disk" "cloudinit_show-web02" {
  name           = "seed_show-web02.iso"
  user_data      = data.template_file.user_data_show-web02.rendered
  meta_data      = data.template_file.meta_data_show-web02.rendered
  pool           = libvirt_pool.tf_show.name
}

data "template_file" "meta_data_show-as01" {
  template = file("/var/lib/libvirt/project/show/cloud-init/show-as01/meta-data")
}

data "template_file" "user_data_show-as01" {
  template = file("/var/lib/libvirt/project/show/cloud-init/show-as01/user-data")
}

resource "libvirt_cloudinit_disk" "cloudinit_show-as01" {
  name           = "seed_show-as01.iso"
  user_data      = data.template_file.user_data_show-as01.rendered
  meta_data      = data.template_file.meta_data_show-as01.rendered
  pool           = libvirt_pool.tf_show.name
}

resource "libvirt_volume" "disk_boot_boot_show-web01" {
  name       = "show-web01_boot.qcow2"
  pool       = libvirt_pool.tf_show.name
  source     = "/var/lib/libvirt/template/rhel76.qcow2"
  format     = "qcow2"
}

resource "libvirt_volume" "disk_boot_boot_show-web02" {
  name       = "show-web02_boot.qcow2"
  pool       = libvirt_pool.tf_show.name
  source     = "/var/lib/libvirt/template/rhel76.qcow2"
  format     = "qcow2"
}

resource "libvirt_volume" "disk_boot_boot_show-as01" {
  name       = "show-as01_boot.qcow2"
  pool       = libvirt_pool.tf_show.name
  source     = "/var/lib/libvirt/template/rhel76.qcow2"
  format     = "qcow2"
}

resource "ansible_group" "all" {
  inventory_group_name = "all"
  vars                 = {
                           project = "show"

  }
}
resource "ansible_group" "web" {
  inventory_group_name = "web"
  children             = ["all"]
  vars                 = {
                           project = "show"

  }
}
resource "ansible_group" "backend" {
  inventory_group_name = "backend"
  children             = ["all"]
  vars                 = {
                           project = "show"

  }
}

resource "libvirt_domain" "domain_show-web01" {
  name      = "show-web01"
  memory    = "4096"
  vcpu      = "4"

  cloudinit = libvirt_cloudinit_disk.cloudinit_show-web01.id

  network_interface {
    network_id     = libvirt_network.network_show_base.id
    addresses      = ["10.8.220.5"]
    hostname       = "show-web01"
  }
  network_interface {
    network_id     = libvirt_network.network_show_base.id
    addresses      = ["10.8.220.6"]
    hostname       = "show-web01"
  }

  disk {
    volume_id = libvirt_volume.disk_boot_boot_show-web01.id
    scsi      = "true"
  }

  console {
    type = "pty"
    target_type = "serial"
    target_port = "0"
  }
}

resource "ansible_host" "show-web01" {
    inventory_hostname = "show-web01.edu.local"
    groups             = ["web"]
    vars               = {
                           project = "show"
    }
}

resource "libvirt_domain" "domain_show-web02" {
  name      = "show-web02"
  memory    = "4096"
  vcpu      = "4"

  cloudinit = libvirt_cloudinit_disk.cloudinit_show-web02.id

  network_interface {
    network_id     = libvirt_network.network_show_base.id
    addresses      = ["10.8.220.12"]
    hostname       = "show-web02"
  }
  network_interface {
    network_id     = libvirt_network.network_show_data.id
    addresses      = ["172.20.11.12"]
    hostname       = "show-web02"
  }

  disk {
    volume_id = libvirt_volume.disk_boot_boot_show-web02.id
    scsi      = "true"
  }

  console {
    type = "pty"
    target_type = "serial"
    target_port = "0"
  }
}

resource "ansible_host" "show-web02" {
    inventory_hostname = "show-web02.edu.local"
    groups             = ["web"]
    vars               = {
                           project = "show"
    }
}

resource "libvirt_domain" "domain_show-as01" {
  name      = "show-as01"
  memory    = "4096"
  vcpu      = "4"

  cloudinit = libvirt_cloudinit_disk.cloudinit_show-as01.id

  network_interface {
    network_id     = libvirt_network.network_show_base.id
    addresses      = ["10.8.220.3"]
    hostname       = "show-as01"
  }

  disk {
    volume_id = libvirt_volume.disk_boot_boot_show-as01.id
    scsi      = "true"
  }

  console {
    type = "pty"
    target_type = "serial"
    target_port = "0"
  }
}

resource "ansible_host" "show-as01" {
    inventory_hostname = "show-as01.edu.local"
    groups             = ["web"]
    vars               = {
                           project = "show"
    }
}

terraform {
  required_version = ">= 0.12"
}

Steps to Reproduce Issue
export TF_LOG=debug

During deploy in debug logs ip address are properly readed from .tf file and assinged to host mac and name
2020-01-26T14:13:15.961+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:15 [INFO] Adding IP/MAC/host=10.8.220.12/52:54:00:46:42:ed/show-web02 to tf_show_base
2020-01-26T14:13:15.961+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:15 Updating host with XML:
2020-01-26T14:13:15.961+0100 [DEBUG] plugin.terraform-provider-libvirt:   <host mac="52:54:00:46:42:ed" name="show-web02" ip="10.8.220.12"></host>
2020-01-26T14:13:15.969+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:15 [DEBUG] Setting disk driver to 'qcow2' to match disk volume format
2020-01-26T14:13:15.969+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:15 [DEBUG] scsiDisk: true
2020-01-26T14:13:15.969+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:15 filesystems: []
2020-01-26T14:13:15.975+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:15 [DEBUG] Setting disk driver to 'qcow2' to match disk volume format
2020-01-26T14:13:15.975+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:15 [DEBUG] scsiDisk: true
2020-01-26T14:13:15.975+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:15 filesystems: []
2020-01-26T14:13:16.263+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:16 Adding host with XML:
2020-01-26T14:13:16.263+0100 [DEBUG] plugin.terraform-provider-libvirt:   <host mac="52:54:00:46:42:ed" name="show-web02" ip="10.8.220.12"></host>
2020-01-26T14:13:16.263+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:16 [INFO] Adding IP/MAC/host=10.8.220.5/52:54:00:26:a6:44/show-web01 to tf_show_base
2020-01-26T14:13:16.263+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:16 Updating host with XML:
2020-01-26T14:13:16.264+0100 [DEBUG] plugin.terraform-provider-libvirt:   <host mac="52:54:00:26:a6:44" name="show-web01" ip="10.8.220.5"></host>
2020-01-26T14:13:16.551+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:16 [INFO] Adding IP/MAC/host=10.8.220.3/52:54:00:36:b0:da/show-as01 to tf_show_base
2020-01-26T14:13:16.551+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:16 Updating host with XML:
2020-01-26T14:13:16.551+0100 [DEBUG] plugin.terraform-provider-libvirt:   <host mac="52:54:00:36:b0:da" name="show-as01" ip="10.8.220.3"></host>
2020-01-26T14:13:16.553+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:16 [INFO] Adding IP/MAC/host=172.20.11.12/52:54:00:16:f1:d6/show-web02 to tf_show_data
2020-01-26T14:13:16.553+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:16 Updating host with XML:
2020-01-26T14:13:16.553+0100 [DEBUG] plugin.terraform-provider-libvirt:   <host mac="52:54:00:16:f1:d6" name="show-web02" ip="172.20.11.12"></host>
2020-01-26T14:13:17.059+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:17 Adding host with XML:
2020-01-26T14:13:17.059+0100 [DEBUG] plugin.terraform-provider-libvirt:   <host mac="52:54:00:26:a6:44" name="show-web01" ip="10.8.220.5"></host>
2020-01-26T14:13:17.130+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:17 Adding host with XML:
2020-01-26T14:13:17.130+0100 [DEBUG] plugin.terraform-provider-libvirt:   <host mac="52:54:00:16:f1:d6" name="show-web02" ip="172.20.11.12"></host>
2020-01-26T14:13:17.624+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:17 Adding host with XML:
2020-01-26T14:13:17.624+0100 [DEBUG] plugin.terraform-provider-libvirt:   <host mac="52:54:00:36:b0:da" name="show-as01" ip="10.8.220.3"></host>
2020-01-26T14:13:18.301+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:18 [INFO] Adding IP/MAC/host=10.8.220.6/52:54:00:ce:29:b0/show-web01 to tf_show_base
2020-01-26T14:13:18.301+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:18 Updating host with XML:
2020-01-26T14:13:18.301+0100 [DEBUG] plugin.terraform-provider-libvirt:   <host mac="52:54:00:ce:29:b0" name="show-web01" ip="10.8.220.6"></host>

Part of log (debug output terraform deploy) from libvirt API
2020-01-26T14:13:19.354+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:19 [DEBUG] no interfaces could be obtained with qemu-agent: falling back to the libvirt API
2020-01-26T14:13:19.354+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:19 [DEBUG] Interfaces info obtained with libvirt API:
2020-01-26T14:13:19.354+0100 [DEBUG] plugin.terraform-provider-libvirt: ([]libvirt.DomainInterface) {
2020-01-26T14:13:19.354+0100 [DEBUG] plugin.terraform-provider-libvirt: }
2020-01-26T14:13:19.354+0100 [DEBUG] plugin.terraform-provider-libvirt:
2020-01-26T14:13:19.354+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:19 [DEBUG] read: addresses for '52:54:00:26:A6:44': []
2020-01-26T14:13:19.355+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:19 [DEBUG] read: addresses for '52:54:00:CE:29:B0': []
2020-01-26T14:13:19.355+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:19 [DEBUG] read: hostname for '52:54:00:CE:29:B0': 'show-web01'
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt: 2020/01/26 14:13:19 [DEBUG] read: ifaces for 'show-web01':
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt: ([]map[string]interface {}) (len=2 cap=2) {
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:         (map[string]interface {}) (len=10) {
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=6) "bridge": (string) "",
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=7) "macvtap": (string) "",
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=11) "passthrough": (string) "",
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=3) "mac": (string) (len=17) "52:54:00:26:A6:44",
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=8) "hostname": (string) "",
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=14) "wait_for_lease": (bool) false,
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=9) "addresses": ([]string) <nil>,
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=10) "network_id": (string) (len=36) "18d426ab-927f-4be1-9dbc-bf9d98d26843",
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=12) "network_name": (string) (len=12) "tf_show_base",
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=4) "vepa": (string) ""
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:         },
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:         (map[string]interface {}) (len=10) {
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=11) "passthrough": (string) "",
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=8) "hostname": (string) (len=10) "show-web01",
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=14) "wait_for_lease": (bool) false,
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=9) "addresses": ([]string) <nil>,
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=10) "network_id": (string) (len=36) "18d426ab-927f-4be1-9dbc-bf9d98d26843",
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=12) "network_name": (string) (len=12) "tf_show_base",
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=6) "bridge": (string) "",
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=4) "vepa": (string) "",
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=7) "macvtap": (string) "",
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:                 (string) (len=3) "mac": (string) (len=17) "52:54:00:CE:29:B0"
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt:         }
2020-01-26T14:13:19.356+0100 [DEBUG] plugin.terraform-provider-libvirt: }
2020/01/26 14:13:19 [WARN] Provider "libvirt" produced an unexpected new value for libvirt_domain.domain_show-web01, but we are tolerating it because it is using the legacy plugin SDK.
    The following problems may be the cause of any confusing errors from downstream operations:
      - .autostart: was null, but now cty.False
      - .kernel: was null, but now cty.StringVal("")
      - .firmware: was null, but now cty.StringVal("")
      - .initrd: was null, but now cty.StringVal("")
      - .console[0].source_path: was null, but now cty.StringVal("")
      - .network_interface[0].addresses: element 0 has vanished
      - .network_interface[0].passthrough: was null, but now cty.StringVal("")
      - .network_interface[0].wait_for_lease: was null, but now cty.False
      - .network_interface[0].bridge: was null, but now cty.StringVal("")
      - .network_interface[0].hostname: was cty.StringVal("show-web01"), but now cty.StringVal("")
      - .network_interface[0].macvtap: was null, but now cty.StringVal("")
      - .network_interface[0].vepa: was null, but now cty.StringVal("")
      - .network_interface[1].vepa: was null, but now cty.StringVal("")
      - .network_interface[1].bridge: was null, but now cty.StringVal("")
      - .network_interface[1].macvtap: was null, but now cty.StringVal("")
      - .network_interface[1].passthrough: was null, but now cty.StringVal("")
      - .network_interface[1].wait_for_lease: was null, but now cty.False
      - .network_interface[1].addresses: element 0 has vanished
      - .disk[0].wwn: was null, but now cty.StringVal("")
      - .disk[0].block_device: was null, but now cty.StringVal("")
      - .disk[0].file: was null, but now cty.StringVal("")
      - .disk[0].url: was null, but now cty.StringVal("")

Addreses interfaces:
[root@show-web01 ~]# ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
    link/ether 52:54:00:66:63:28 brd ff:ff:ff:ff:ff:ff
    inet 10.8.220.195/24 brd 10.8.220.255 scope global noprefixroute dynamic eth0
       valid_lft 3507sec preferred_lft 3507sec
    inet6 fe80::5054:ff:fe66:6328/64 scope link
       valid_lft forever preferred_lft forever
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
    link/ether 52:54:00:ce:c3:5b brd ff:ff:ff:ff:ff:ff

[root@show-web02 ~]# ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
    link/ether 52:54:00:0a:68:c5 brd ff:ff:ff:ff:ff:ff
    inet 10.8.220.12/24 brd 10.8.220.255 scope global noprefixroute dynamic eth0
       valid_lft 3501sec preferred_lft 3501sec
    inet6 fe80::5054:ff:fe0a:68c5/64 scope link
       valid_lft forever preferred_lft forever
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
    link/ether 52:54:00:3a:35:00 brd ff:ff:ff:ff:ff:ff

[root@show-as01 ~]# ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
    link/ether 52:54:00:82:9a:92 brd ff:ff:ff:ff:ff:ff
    inet 10.8.220.3/24 brd 10.8.220.255 scope global noprefixroute dynamic eth0
       valid_lft 3491sec preferred_lft 3491sec
    inet6 fe80::5054:ff:fe82:9a92/64 scope link
       valid_lft forever preferred_lft forever

Additional information:
SELINUX Permissive
FIREWALL ON

Any update on the above issue?
cloud-init service which in default configuration up only one network interface.

I think I got something working following @mateuszbanasiewicz advice. I used this network_config.cfg file containing a netplan config:
version: 2
ethernets:
  ens3:
    dhcp4: true
  ens4:
    dhcp4: true

and I reference this file in the libvirt_cloudinit_disk resource:
data "template_file" "network_config" {
  template = file("${path.module}/network_config.cfg")
}

resource "libvirt_cloudinit_disk" "cloudinit" {
  name           = "cloudinit.iso"
  user_data      = data.template_file.user_data.rendered
  network_config = data.template_file.network_config.rendered
  pool           = libvirt_pool.vm.name
}
data "template_file" "network_config" {
  template = file("${path.module}/network_config.cfg")
}

Resulting in 2 IP addresses, specific for my case being 10.0.10.2 and 10.0.10.18:
developer@vm:~$ ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host noprefixroute
       valid_lft forever preferred_lft forever
2: ens3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
    link/ether 52:54:00:b2:36:73 brd ff:ff:ff:ff:ff:ff
    altname enp0s3
    inet 10.0.10.2/28 metric 100 brd 10.0.10.15 scope global dynamic ens3
       valid_lft 3348sec preferred_lft 3348sec
    inet6 fe80::5054:ff:feb2:3673/64 scope link
       valid_lft forever preferred_lft forever
3: ens4: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
    link/ether 52:54:00:6e:3a:27 brd ff:ff:ff:ff:ff:ff
    altname enp0s4
    inet 10.0.10.18/28 metric 100 brd 10.0.10.31 scope global dynamic ens4
       valid_lft 3348sec preferred_lft 3348sec
    inet6 fe80::5054:ff:fe6e:3a27/64 scope link
       valid_lft forever preferred_lft forever

repo: dmacvicar/terraform-provider-libvirt


text:
[BUG] 5G Wi-Fi band switch does not work well

Describe the bug
Hi, thank you very much for this new version. I have updated to version 2.5.0 but I see that the 5G Wi-Fi band switch does not work well, it is always ON even if the network is turned off.  (switch.miwifi_XX_XX_XX_XX_XX_XX_wifi_5g)
Thank you.

HASS version: 2022.4.0
Home Assistant Core 2022.4.6
Home Assistant Operating System 7.6
Component version 2.5.0
Router model AX3600
Router firmware version 1.1.19 CN

Please provide diagnostic information. Instruction received via GUI: https://github.com/dmamontov/hass-miwifi#diagnostics

File:
config_entry-miwifi-bfa0065abdd52daecf38b0a100f10c6c.json - EDITED MACS.txt

@fcoval I will need time to study the logs

@fcoval https://github.com/dmamontov/hass-miwifi/releases/tag/v2.5.2
Check out this release.
If it doesn't help, then you need information from api with wifi enabled.
http://192.168.31.1/cgi-bin/luci/;stok=**REDACTED**/api/xqnetwork/wifi_detail_all
http://192.168.31.1/cgi-bin/luci/;stok=**REDACTED**/api/xqnetwork/wifi_diag_detail_all

Hi Dimitri,
The switch works in terms of sending the order to the router to turn the Wi-Fi network ON and OFF, but after a few seconds/minutes, you see, for example, that it has acted by turning off the Wi-Fi network in the router, but, in Home Assistant you see that the switch continues to report which network is always ON state. It does not work correctly, and it does not only happen in the 5G Wi-Fi network, also in the 2.4G network, it happens to both switches.
I pass the information with both networks enabled ( for 2.4G and 5G):
http://192.168.31.1/cgi-bin/luci/;stok=**REDACTED**/api/xqnetwork/wifi_detail_all
{"bsd":0,"info":[{"ifname":"wl1","channelInfo":{"bandwidth":"0","bandList":["20","40"],"channel":11},"encryption":"psk2","bandwidth":"0","kickthreshold":"0","status":"1","mode":"Master","ssid":"RedSinInternet","weakthreshold":"0","device":"wifi1.network1","ax":"1","hidden":"0","password":"REDACTED","channel":"11","txpwr":"max","weakenable":"0","txbf":"3","signal":-97},{"ifname":"wl0","channelInfo":{"bandwidth":"0","bandList":["20","40","80","160"],"channel":48},"encryption":"mixed-psk","bandwidth":"0","kickthreshold":"0","status":"1","mode":"Master","ssid":"RedSinInternet5","weakthreshold":"0","device":"wifi0.network1","ax":"1","hidden":"0","password":"REDACTED","channel":"48","txpwr":"max","weakenable":"0","txbf":"3","signal":-98}],"code":0}
http://192.168.31.1/cgi-bin/luci/;stok=**REDACTED**/api/xqnetwork/wifi_diag_detail_all
{"bsd":0,"info":[{"iftype":1,"ifname":"wl1","channelInfo":{"bandwidth":"0","bandList":["20","40"],"channel":11},"encryption":"psk2","device":"wifi1.network1","ax":"1","hidden":"0","txbf":"3","password":"REDACTED","bandwidth":"0","ssid":"RedSinInternet","channel":"11","status":"1","mode":"Master","txpwr":"max","signal":-97},{"iftype":2,"ifname":"wl0","channelInfo":{"bandwidth":"0","bandList":["20","40","80","160"],"channel":48},"encryption":"mixed-psk","device":"wifi0.network1","ax":"1","hidden":"0","txbf":"3","password":"REDACTED","bandwidth":"0","ssid":"RedSinInternet5","channel":"48","status":"1","mode":"Master","txpwr":"max","signal":-98},{"password":"REDACTED","ifname":"wl14","ssid":" 小米共享WiFi_A149","encryption":"psk2","status":0,"iftype":3,"enabled":"1"}],"code":0}

I have turned off the 5G wifi network again and as you can see, the status of the switch in HomeAssistant is ON.

As the switches do work on the router, a simple sensor to Home Assistant that the Wi-Fi networks are activated or deactivated would solve the problem (as the dual band sensor) and change these two switchs:
entity: switch.miwifi_xx_wifi_2_4g
entity: switch.miwifi_xx_wifi_5g
for buttons:
entity: button.miwifi_xx_wifi_2_4g
entity: button.miwifi_xx_wifi_5g

@fcoval You can see from your logs that the api returns that they are enabled. Those. component works correctly. Based on the number of devices is a bad idea. There is another option to check:

Go to page: http://192.168.31.1/cgi-bin/luci/;stok=REDACTED/web/setting/wifi
Disable any of the networks
Open the chrome debug panel: F12 (Mac: Cmd+Opt+I)
In the debug panel go to network
In the same place, enable the Fetch/XHR filter
Reload the page

All requests will appear in the debug panel. Get them and send me please.
It's definitely not the component. I checked on the same firmware version and everything works as it should. My instruction is the last resort in solving the problem.

http://192.168.5.20/cgi-bin/luci/;stok=**REDACTED**/api/xqnetwork/get_son_backhaul_mode
{"code":0,"mode":"0"}
http://192.168.5.20/cgi-bin/luci/;stok=**REDACTED**/api/misystem/messages
{"messages":[],"count":0,"code":0}
http://192.168.5.20/cgi-bin/luci/;stok=**REDACTED**/api/xqnetwork/get_miscan_switch
{"enabled":0,"code":0}
http://192.168.5.20/cgi-bin/luci/;stok=**REDACTED**/api/xqnetwork/wifi_detail_all
{"bsd":0,"info":[{"ifname":"wl1","channelInfo":{"bandwidth":"0","bandList":["20","40"],"channel":11},"encryption":"psk2","bandwidth":"0","kickthreshold":"0","status":"1","mode":"Master","ssid":"RedSinInternet","weakthreshold":"0","device":"wifi1.network1","ax":"1","hidden":"0","password":*REDACTED,"channel":"11","txpwr":"max","weakenable":"0","txbf":"3","signal":-97},{"ifname":"wl0","channelInfo":{"bandwidth":"0","bandList":["20","40","80","160"],"channel":"48"},"encryption":"mixed-psk","bandwidth":"0","kickthreshold":"0","status":"0","mode":"Master","ssid":*REDACTED,"weakthreshold":"0","device":"wifi0.network1","ax":"1","hidden":"0","password":"000000000000000","channel":"48","txpwr":"max","weakenable":"0","txbf":"3","signal":0}],"code":0}
http://192.168.5.20/cgi-bin/luci/;stok=**REDACTED**/api/xqnetwork/get_miotrelay_switch
{"enabled":1,"code":0}
http://192.168.5.20/cgi-bin/luci/;stok=**REDACTED*/api/xqsystem/country_code
{"current":"CN","list":[{"name":"中国大陆","code":"CN"},{"name":"香港地区","code":"HK"},{"name":"台湾地区","code":"TW"},{"name":"韩国","code":"KR"},{"name":"欧洲","code":"EU"}],"code":0}

http://192.168.5.20/cgi-bin/luci/;stok=**REDACTED**/api/xqnetwork/wifi_diag_detail_all
And you can also call the following method with the same actions. The API returns correctly.

http://192.168.5.20/cgi-bin/luci/;stok=**REDACTED**/api/xqnetwork/wifi_diag_detail_all
{"bsd":0,"info":[{"iftype":1,"ifname":"wl1","channelInfo":{"bandwidth":"0","bandList":["20","40"],"channel":11},"encryption":"psk2","device":"wifi1.network1","ax":"1","hidden":"0","txbf":"3","password":"REDACTED","bandwidth":"0","ssid":"RedSinInternet","channel":"11","status":"1","mode":"Master","txpwr":"max","signal":-97},{"iftype":2,"ifname":"wl0","channelInfo":{"bandwidth":"0","bandList":["20","40","80","160"],"channel":"48"},"encryption":"mixed-psk","device":"wifi0.network1","ax":"1","hidden":"0","txbf":"3","password":"REDACTED","bandwidth":"0","ssid":"RedSinInternet5","channel":"48","status":"1","mode":"Master","txpwr":"max","signal":0},{"password":"REDACTED","ifname":"wl14","ssid":" 小米共享WiFi_AREDACTED","encryption":"psk2","status":0,"iftype":3,"enabled":"1"}],"code":0}

I'll test one theory and come back. If it is not confirmed, then what is the matter is very difficult to understand.

If the component work well and I have a particular case, do not worry, I build a little solution in Home Assistant to me with 2 sensors about the number of devices, do not worry.
Many thanks Dimitry for your time and component.

@fcoval Well, the last attempt) Replace these 2 files and hass restart, if the problem goes away, I will add it to the release
files.zip

@fcoval Well, the last attempt) Replace these 2 files and hass restart, if the problem goes away, I will add it to the release files.zip

PERFECT !!!!
With these two files, the switchs are working very well.
Many thanks one more time.

Fine. Then I prepare the release

@fcoval https://github.com/dmamontov/hass-miwifi/releases/tag/v2.5.3
Can be updated

authors: dmamontov fcoval

repo: dmamontov/hass-miwifi


text:
Split recurring tasks when modifying the first instance

It's probably a good idea to split a recurring tasks when overriding the first instance. After the split there would be a single task for the override and a recurring task starting at the next instance (if there is any). This way we don't have to deal with all the old instances of completed tasks. Also some clients seem to support this model only (i.e. Apple clients).
The drawback is, we loose the information about the recurrence, i.e. the current instance would appear as a single task, not a recurring one. One solution to this could be to add a special relation which identifies this task as a part of a recurrence set.
TODO: decide which of these tasks is the result of the old task being modified and which one is the newly created one.

For starters, let's only split off completed instances and see how this works out with Apple and other clients.

repo: dmfs/opentasks


text:
Error: module surface_acpi not found

When trying to upgrade kernel from 5.1.15-1 to 5.3.10-1 I noticed that this error popped up during Pacman install of the kernel tar.xz
This happened with both compiling the kernel and your pre-compiled binaries on a surface pro 6.
I downgraded back to 5.1.15-1 to make sure I was still stable and had backups of that kernel's binaries in the event of the 5.3.10 kernel being unable to boot.
I have not yet tried booting into this kernel with the error to see what will happen, but I will do this later this evening and report back what happens.
Edit: For reference, self compiling and pre-compiled kernels of this version worked flawlessly on a fresh install on a surface go.

the surface_acpi module was renamed to surface_sam; you'll need to update the mkinitcpio to include the correct modules now (see https://github.com/qzed/linux-surface/commit/d065c13cca40150db4bc8e1592edf28faec0c173)

@PandorasFox thank you, I'll take a look at that repo this evening when I get home and report back on how it goes.

Merging all issues related to the surface_acpi/surface_sam split to issue #73. Will fix after my finals (ETA one week).

authors: PandorasFox dmhacker v12venator

repo: dmhacker/arch-linux-surface


text:
compiler error when including OpenCV

While this problem was raised by another user in https://github.com/dmlc/mxnet/issues/744 it was never resolved. I have tried the suggested fix and it did not resolve my problem. I can confirm that I have OpenCV installed. When I run "pkg-config --libs opencv" I get:
/usr/lib/x86_64-linux-gnu/libopencv_calib3d.so -lopencv_calib3d /usr/lib/x86_64-linux-gnu/libopencv_contrib.so -lopencv_contrib /usr/lib/x86_64-linux-gnu/libopencv_core.so -lopencv_core /usr/lib/x86_64-linux-gnu/libopencv_features2d.so -lopencv_features2d /usr/lib/x86_64-linux-gnu/libopencv_flann.so -lopencv_flann /usr/lib/x86_64-linux-gnu/libopencv_gpu.so -lopencv_gpu /usr/lib/x86_64-linux-gnu/libopencv_highgui.so -lopencv_highgui /usr/lib/x86_64-linux-gnu/libopencv_imgproc.so -lopencv_imgproc /usr/lib/x86_64-linux-gnu/libopencv_legacy.so -lopencv_legacy /usr/lib/x86_64-linux-gnu/libopencv_ml.so -lopencv_ml /usr/lib/x86_64-linux-gnu/libopencv_objdetect.so -lopencv_objdetect /usr/lib/x86_64-linux-gnu/libopencv_ocl.so -lopencv_ocl /usr/lib/x86_64-linux-gnu/libopencv_photo.so -lopencv_photo /usr/lib/x86_64-linux-gnu/libopencv_stitching.so -lopencv_stitching /usr/lib/x86_64-linux-gnu/libopencv_superres.so -lopencv_superres /usr/lib/x86_64-linux-gnu/libopencv_ts.so -lopencv_ts /usr/lib/x86_64-linux-gnu/libopencv_video.so -lopencv_video /usr/lib/x86_64-linux-gnu/libopencv_videostab.so -lopencv_videostab
When I run apt-cache show libopencv-dev I get:
Package: libopencv-dev
Priority: optional
Section: universe/libdevel
Installed-Size: 653
Maintainer: Kubuntu Developers kubuntu-devel@lists.ubuntu.com
Original-Maintainer: Debian Science Team debian-science-maintainers@lists.alioth.debian.org
Architecture: amd64
Source: opencv
Version: 2.4.9+dfsg-1ubuntu6
Depends: libc6 (>= 2.14), libgcc1 (>= 1:4.1.1), libopencv-calib3d2.4v5, libopencv-core2.4v5, libopencv-highgui2.4v5, libopencv-imgproc2.4v5, libopencv-ml2.4v5, libopencv-objdetect2.4v5, libstdc++6 (>= 5.2), libopencv-core-dev (= 2.4.9+dfsg-1ubuntu6), libopencv-ml-dev (= 2.4.9+dfsg-1ubuntu6), libopencv-imgproc-dev (= 2.4.9+dfsg-1ubuntu6), libopencv-video-dev (= 2.4.9+dfsg-1ubuntu6), libopencv-objdetect-dev (= 2.4.9+dfsg-1ubuntu6), libopencv-highgui-dev (= 2.4.9+dfsg-1ubuntu6), libopencv-calib3d-dev (= 2.4.9+dfsg-1ubuntu6), libopencv-flann-dev (= 2.4.9+dfsg-1ubuntu6), libopencv-features2d-dev (= 2.4.9+dfsg-1ubuntu6), libopencv-legacy-dev (= 2.4.9+dfsg-1ubuntu6), libopencv-contrib-dev (= 2.4.9+dfsg-1ubuntu6), libopencv-ts-dev (= 2.4.9+dfsg-1ubuntu6), libopencv-photo-dev (= 2.4.9+dfsg-1ubuntu6), libopencv-videostab-dev (= 2.4.9+dfsg-1ubuntu6), libopencv-stitching-dev (= 2.4.9+dfsg-1ubuntu6), libopencv-gpu-dev (= 2.4.9+dfsg-1ubuntu6), libopencv-superres-dev (= 2.4.9+dfsg-1ubuntu6), libopencv-ocl-dev (= 2.4.9+dfsg-1ubuntu6), libopencv2.4-java (= 2.4.9+dfsg-1ubuntu6), libopencv2.4-jni (= 2.4.9+dfsg-1ubuntu6), libcv-dev (= 2.4.9+dfsg-1ubuntu6), libhighgui-dev (= 2.4.9+dfsg-1ubuntu6), libcvaux-dev (= 2.4.9+dfsg-1ubuntu6), pkg-config
Recommends: opencv-data
Breaks: libopencv-core-dev (<= 2.3.1-8)
Filename: pool/universe/o/opencv/libopencv-dev_2.4.9+dfsg-1ubuntu6_amd64.deb
Size: 167428
MD5sum: ecaf4191cf03536bff3e19cc1ddc424c
SHA1: d719e328151d771af7eaef054ee7edbbf803681d
SHA256: 0c7ec4a327a5c124ddcb6d5247a3e0a7421679a422aa005353830d59444d818e
Description-en: development files for opencv
This is a metapackage providing development package necessary for
development of OpenCV (Open Computer Vision).
.
The Open Computer Vision Library is a collection of algorithms and sample
code for various computer vision problems. The library is compatible with
IPL (Intel's Image Processing Library) and, if available, can use IPP
(Intel's Integrated Performance Primitives) for better performance.
.
OpenCV provides low level portable data types and operators, and a set
of high level functionalities for video acquisition, image processing and
analysis, structural analysis, motion analysis and object tracking, object
recognition, camera calibration and 3D reconstruction.
Description-md5: f9dc67381f1013c39fe59842c79cbddf
Homepage: http://opencv.org/
Bugs: https://bugs.launchpad.net/ubuntu/+filebug
Origin: Ubuntu
I can successfully compile and run mxnet with USE_OPENCV = 0. When I compile with USE_OPENCV = 1, and run make clean all, I get the following error:
/tmp/ccYg0ncG.o: In function main': im2rec.cc:(.text.startup+0x2789): undefined reference to cv::imencode(std::string const&, cv::_InputArray const&, std::vector<unsigned char, std::allocator >&, std::vector<int, std::allocator > const&)'
collect2: error: ld returned 1 exit status
Makefile:167: recipe for target 'bin/im2rec' failed
make: *** [bin/im2rec] Error 1

do you configure the opencv lib path in your environment(maybe ~/.bashrc in linux)? like this:
export PKG_CONFIG_PATH=$YOUR_PATH/opencv/lib/pkgconfig
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$OUR_PATH/opencv/lib

I don't have any directories called pkgconfig
I added /home/colin/mxnet/opencv-3.1.0/build/lib to my .bashrc but that didn't fix the problem
My /etc/ld.so.conf.d/opencv.conf contains /usr/local/lib

try:

source ~/.bashrc before make
where is your opencv.pc path when you install opencv? the PKG_CONFIG_PATH is point to that directory.

Thanks. I was able to find the path after searching for opencv.pc. After setting those values in my .bashrc I'm still getting the same error message undefined reference to cv::imencode.
Here is what I have done in response to your advice:
opencv.pc is located at:
/usr/lib/x86_64-linux-gnu/pkgconfig/opencv.pc
echo $PKG_CONFIG_PATH returns:
/usr/lib/x86_64-linux-gnu/pkgconfig
echo $LD_LIBRARY_PATH returns:
/usr/local/cuda-7.5/lib64:/usr/lib/x86_64-linux-gnu

this problem should be cased by the opencv installation, your can refer to https://github.com/BVLC/caffe/issues/2288

Where do I add opencv_imgcodecs into the project? Which Makefile? Is the syntax LIBRARIES += opencv_imgcodecs?

you can first try to write one test.cpp(use opencv function in it) to test whether you can  build and run it sucessfully.

Sorry but I'm too much of a newby to be able to do that simply. I shall just run mxnet without OpenCV.

authors: colinpriest tornadomeet

repo: dmlc/mxnet


text:
Fine tuning Cifar-100 model freezing all layers except the last one.

I have trained a cifar-100 model using https://github.com/dmlc/mxnet/blob/master/example/notebooks/cifar-100.ipynb .
I need to finetune the model, freezing all the layers except the last one. How can we use symbol.blockGrad to freeze the layers? Is there any other method ?

You don't need to use blockGrad. Don't bind the gradient of the last layer or specify grad_req='null' in simple_bind will do.

BTW, strictly speaking, using blockGrad cannot freeze the weight since weight decay may also change the weight.

https://github.com/dmlc/mxnet/blob/master/python/mxnet/optimizer.py

The updater currently is unaware of layer-wise configuration.
def get_updater(optimizer):
    """Return a clossure of the updater needed for kvstore
    Parameters
    ----------
    optimizer: Optimizer
         The optimizer
    Returns
    -------
    updater: function
         The clossure of the updater
    """
    states = dict()
    def updater(index, grad, weight):
        """updater for kvstore"""
        if index not in states:
            states[index] = optimizer.create_state(index, weight)
        optimizer.update(index, weight, grad, states[index])
    return updater

This is one of the most common use cases. Have not anyone done this before with MXNet?

Would you please restart the effort of https://github.com/dmlc/mxnet/issues/830 to make common tasks very easy to finish?

The hacky way to block gradients is https://github.com/dmlc/mxnet/issues/1538#issuecomment-196691988.

authors: CodeforBetter futurely piiswrong winstywang


text:
Infer shape error in rhs argument

Hi guys,
I'm composing a resnet model on the basis of "symbol_resnet.py" code. I added some pooling layers between the resnet blocks and now I got the following error:  InferShape Error in _plus4's rhs argument. When I change pad option in pooling layers or change number of filters in the conv layer, the number in the error message changes to another one (e.g. _plus8). With a certain number of the filters and pad option the error disappears. This is very strange, I don't understand why I can not choose those number of filters and padding which I want. It shouldn't be a problem. Could you please help me with this issue?

because when you add two tensors they need to have the same shape.
You need certain pad size to ensure that.

Yes, thank you, finally all the problems were due to that, I've already figured that out

authors: Andrjusha piiswrong